From 2662ac356ce14dacfbc91689fd37244facff4989 Mon Sep 17 00:00:00 2001
From: Andy Belle-Isle <drumsetmonkey@gmail.com>
Date: Fri, 30 Aug 2019 00:14:27 -0400
Subject: Added Name and Render components to Lua

---
 Scripts/init.lua | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

(limited to 'Scripts/init.lua')

diff --git a/Scripts/init.lua b/Scripts/init.lua
index 82c2486..3ec4618 100644
--- a/Scripts/init.lua
+++ b/Scripts/init.lua
@@ -15,6 +15,7 @@ bird = {
         x = 1.2,
         y = 3.4
     },
+    Name = "bord",
     init = function(self)
         print(self.Position.x .. "," .. self.Position.y)
     end
@@ -25,14 +26,29 @@ dog = {
         x = 6.5,
         y = 1.3
     },
+    Render = {
+        texture = "assets/tex.png",
+        visible = true
+    },
     init = function(self)
         print(self.Position.x .. "," .. self.Position.y)
     end
 }
 
+animal = {
+    Render = {
+        texture = "assets/anim.png",
+        visible = false
+    }
+}
+
 birdSpawn = game.spawn(bird);
 birdSpawn:init()
+print(birdSpawn.Name.value)
 
 dogSpawn = game.spawn(dog);
 dogSpawn:init()
 dogSpawn.Position.x = 37.5
+
+animalSpawn = game.spawn(animal);
+animalSpawn.Render.texture = "assets/newText.png"
-- 
cgit v1.2.3