aboutsummaryrefslogtreecommitdiffstats
path: root/Scripts
diff options
context:
space:
mode:
authorAndy Belle-Isle <drumsetmonkey@gmail.com>2019-10-07 17:39:52 -0400
committerAndy Belle-Isle <drumsetmonkey@gmail.com>2019-10-07 17:39:52 -0400
commit1b63e00b6b08133f5ee37ed90043eee0f67942fd (patch)
tree686443bdea7368eeaa98c1ea8347a491200ff8d7 /Scripts
parent9cef5e64ddd1ef20369b25cc19b1980084ebaefe (diff)
Added script conversion code, can now convert table to vec2, vec3 and vec4
Diffstat (limited to 'Scripts')
-rw-r--r--Scripts/init.lua28
1 files changed, 17 insertions, 11 deletions
diff --git a/Scripts/init.lua b/Scripts/init.lua
index 1693d0c..34e464b 100644
--- a/Scripts/init.lua
+++ b/Scripts/init.lua
@@ -28,20 +28,31 @@ player = {
end
},
Position = {
- x = 15,
- y = 75
+ 15.0, 10.0
},
Velocity = {
x = 0.0,
y = 0.0
},
+ Hitbox = {
+ bounds = {
+ {x = -0.5, y = -0.8},
+ {x = 0.5, y = -0.8},
+ {x = -0.5, y = 0.8},
+ {x = 0.5, y = 0.8},
+ }
+ },
Physics = 0,
Name = "bord",
- hellotrue = true,
- hellofalse = false,
Render = {
texture = "Assets/player.png",
- visible = true
+ visible = true,
+ bounds = {
+ {x = -0.5, y = -0.8},
+ {x = 0.5, y = -0.8},
+ {x = -0.5, y = 0.8},
+ {x = 0.5, y = 0.8},
+ }
},
Light = {
r = 1.0,
@@ -50,11 +61,6 @@ player = {
strength = 1.0
},
Idle = function(self)
- --if (self.visibleTick >= 20) then
- -- self.Render.visible = not self.Render.visible
- -- self.visibleTick = 0
- --end
- --self.visibleTick = self.visibleTick + 1
end,
visibleTick = 0
}
@@ -86,7 +92,7 @@ ball = {
dofile("Scripts/world.lua")
playerSpawn = game.spawn(player);
---game.spawn(ball);
+game.spawn(ball);
-------------------
-- SERIALIZING --