gel.demo.pong: Set light position.

This commit is contained in:
Rod Kay
2023-10-21 12:35:43 +11:00
parent 4fa47e7396
commit 94f6fb3a3c

View File

@@ -9,6 +9,7 @@ with
Physics,
openGL.Palette,
openGL.Light,
openGL.Model.text,
float_Math.Random,
@@ -54,8 +55,8 @@ is
Bounce => 1.0,
Friction => 0.0,
Radius => 0.5,
Color => White,
Texture => openGL.to_Asset ("assets/opengl/texture/Face1.bmp"));
Color => White);
-- Texture => openGL.to_Asset ("assets/opengl/texture/Face1.bmp"));
--- Players
--
type Player is
@@ -185,6 +186,17 @@ begin
the_Applet.World.Gravity_is ([0.0, 0.0, 0.0]);
the_Applet.World.add (the_Ball);
-- Set the lights position.
--
declare
Light : openGL.Light.item := the_Applet.Renderer.new_Light;
begin
Light.Site_is ([0.0, 1000.0, 0.0]);
the_Applet.Renderer.set (Light);
end;
--- Add the players.
--
declare