Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- clicker = {}
- outputlimit = 15
- function onLoad()
- tokens =getObjectFromGUID("b4ef95")
- bigbag = getObjectFromGUID("606a2d")
- --each page contains 12 prizes
- --Small prizes
- link = getObjectFromGUID("745d53")
- C4 = getObjectFromGUID("716267")
- Pikachu = getObjectFromGUID("7f90f7")
- Staryu = getObjectFromGUID("7b3a06")
- Charmander = getObjectFromGUID("ad88ed")
- Ivysaur = getObjectFromGUID("b434c2")
- Bulbasaur = getObjectFromGUID("311b41")
- Squirtle = getObjectFromGUID("284186")
- Magikarp = getObjectFromGUID("5b6628")
- Abra = getObjectFromGUID("bf24cf")
- Geodude = getObjectFromGUID("9ff6f7")
- Kabuto = getObjectFromGUID("f5ab41")
- Mankey = getObjectFromGUID("158287")
- Porygon = getObjectFromGUID("31f43c")
- Ponyta = getObjectFromGUID("e23f1a")
- Zubat = getObjectFromGUID("1ca24b")
- Machop = getObjectFromGUID("58961a")
- Diglett = getObjectFromGUID("f2af83")
- Meowth = getObjectFromGUID("2c4678")
- Ekans = getObjectFromGUID("31a661")
- Spearow = getObjectFromGUID("1171db")
- Oddish = getObjectFromGUID("b2c969")
- Poliwag = getObjectFromGUID("cb239f")
- Poliwhirl = getObjectFromGUID("5d6c7a")
- Psyduck = getObjectFromGUID("c10cdd")
- Sandshrew = getObjectFromGUID("c40192")
- Clefairy = getObjectFromGUID("c094df")
- Caterpie = getObjectFromGUID("a1e8a4")
- NidoranMale = getObjectFromGUID("bfc840")
- NidoranFemale = getObjectFromGUID("8bd73b")
- Weedle = getObjectFromGUID("954fbd")
- Pidgey = getObjectFromGUID("6aa865")
- Vulpix = getObjectFromGUID("76064f")
- Jigglypuff = getObjectFromGUID("1d634f")
- Ratata = getObjectFromGUID("d43998")
- Eevee = getObjectFromGUID("b2afa7")
- Omanyte = getObjectFromGUID("eac203")
- Ditto = getObjectFromGUID("6d387f")
- Cubone = getObjectFromGUID("6f9ed3")
- Horsea = getObjectFromGUID("f33e54")
- Magnemite = getObjectFromGUID("9e8a69")
- Haunter = getObjectFromGUID("46ca45")
- Duodrio = getObjectFromGUID("bc121e")
- --Medium Prizes
- Mew = getObjectFromGUID("31c260")
- Dragonite = getObjectFromGUID("1a060f")
- Dragonair = getObjectFromGUID("661303")
- Magneton = getObjectFromGUID("e21ba4")
- Lapras = getObjectFromGUID("a1b5ae")
- Vaporeon = getObjectFromGUID("f013ea")
- Jolteon = getObjectFromGUID("7624dd")
- Flareon = getObjectFromGUID("e60e5b")
- Charmeleon = getObjectFromGUID("de2c3f")
- Snorlax = getObjectFromGUID("843223")
- Dugtrio = getObjectFromGUID("439f8c")
- Wartortle = getObjectFromGUID("ff6d71")
- Masterball = getObjectFromGUID("c5e529")
- Safariball = getObjectFromGUID("0ad7d2")
- Pokeball = getObjectFromGUID("775517")
- Levelball = getObjectFromGUID("afb634")
- Cloneball = getObjectFromGUID("cf6384")
- Ultraball = getObjectFromGUID("a75bc1")
- Premierball = getObjectFromGUID("611fe4")
- Loveball = getObjectFromGUID("4b49ca")
- Greatball = getObjectFromGUID("5764a9")
- Cherishball = getObjectFromGUID("d4df90")
- Lureball = getObjectFromGUID("d971d2")
- Ambrosia = getObjectFromGUID("f271d5")
- Slurm = getObjectFromGUID("9d9ceb")
- Duff = getObjectFromGUID("961e97")
- Pokegearblue = getObjectFromGUID("6ba0f4")
- Pokegearpink = getObjectFromGUID("80d7b1")
- Gameboy = getObjectFromGUID("8ae0f3")
- Cooler = getObjectFromGUID("53e201")
- Pokecenter = getObjectFromGUID("47a10f")
- Skyrim = getObjectFromGUID("f2475f")
- Probedroid = getObjectFromGUID("2fab48")
- Uselessdevice = getObjectFromGUID("61c8bf")
- Rupeebag = getObjectFromGUID("b56e6f")
- Brain = getObjectFromGUID("97954c")
- BlackSkele = getObjectFromGUID("39a152")
- Diamond = getObjectFromGUID("224667")
- Skelebow = getObjectFromGUID("c1c342")
- Blackskelebow = getObjectFromGUID("7c08fc")
- DwarvenHe = getObjectFromGUID("57b33a")
- Bonecrown = getObjectFromGUID("7933f0")
- BlackSkull = getObjectFromGUID("c8a31e")
- Kynareth = getObjectFromGUID("fbbb6d")
- Stendarr = getObjectFromGUID("eb0f7d")
- Talos = getObjectFromGUID("c010ae")
- Dibella = getObjectFromGUID("3d1ec6")
- Akatosh = getObjectFromGUID("fb047c")
- Zenithar = getObjectFromGUID("430c5b")
- Mara = getObjectFromGUID("cb8ef3")
- Julianos = getObjectFromGUID("3e5639")
- Arkay = getObjectFromGUID("8b6f48")
- --Large Prizes
- Moltres = getObjectFromGUID("9b13f4")
- Zapdos = getObjectFromGUID("4805e7")
- Articuno = getObjectFromGUID("488c70")
- Mewtwo = getObjectFromGUID("51720d")
- Lady = getObjectFromGUID("0da675")
- Companioncube = getObjectFromGUID("65e3b2")
- Skeletonking = getObjectFromGUID("a4cdd6")
- Thunderball = getObjectFromGUID("0c8b11")
- Leprechaun = getObjectFromGUID("1fa0d0")
- Bluecake = getObjectFromGUID("fd10ee")
- Redcake = getObjectFromGUID("c18844")
- Masterhand = getObjectFromGUID("50faf7")
- Moose = getObjectFromGUID("767746")
- Bantharider = getObjectFromGUID("af78c5")
- Cthulhu = getObjectFromGUID("6554c1")
- Goldentank = getObjectFromGUID("6fb190")
- ATST = getObjectFromGUID("909cfd")
- Flyingfairy = getObjectFromGUID("ea0a9a")
- Daedrichel = getObjectFromGUID("c012fe")
- Ebonyhel = getObjectFromGUID("658f4d")
- Dragonhel = getObjectFromGUID("69b1bc")
- Tuskenraid = getObjectFromGUID("a351f7")
- Obi = getObjectFromGUID("d5e44d")
- Chew = getObjectFromGUID("6abe1e")
- Jawa = getObjectFromGUID("958a99")
- Leia = getObjectFromGUID("313947")
- Rebel = getObjectFromGUID("7fdf17")
- Stormtrooper = getObjectFromGUID("e32d81")
- Han = getObjectFromGUID("f96cbe")
- Luke = getObjectFromGUID("af6b4f")
- Greedo = getObjectFromGUID("181944")
- Royalchamp = getObjectFromGUID("f90c71")
- C3PO = getObjectFromGUID("9e840f")
- Impguard = getObjectFromGUID("70e6ad")
- R2d2 = getObjectFromGUID("3015c2")
- Boba= getObjectFromGUID("ef1c4e")
- Vader = getObjectFromGUID("e4764e")
- Palp = getObjectFromGUID("0e0693")
- requiresToken = true
- initiate()
- end
- function initiate()
- self.clearButtons()
- self.clearInputs()
- self.createButton({click_function = 'ffgStart', function_owner = self, label = 'Small Prizes', position = {2,0.45,2}, width = 1600, height = 380, font_size = 200, scale = {1,1,1}})
- self.createButton({click_function = 'mediumprizes1', function_owner = self, label = 'Medium Prizes', position = {2,0.45,3}, width = 1600, height = 380, font_size = 200, scale = {1,1,1}})
- self.createButton({click_function = 'largeprizes1', function_owner = self, label = 'Large Prizes', position = {2,0.45,4}, width = 1600, height = 380, font_size = 200, scale = {1,1,1}})
- self.createButton({click_function = 'buytokens', function_owner = self, label = 'Buy tokens', position = {2,0.45,5}, width = 1600, height = 380, font_size = 200, scale = {1,1,1}})
- end
- function buytokens()
- self.clearButtons()
- self.clearInputs()
- self.createButton({click_function = 'convertButton1000', function_owner = self, label = 'Buy', position = {0,0.45,2}, width = 1600, height = 380, font_size = 200, scale = {1,1,1}})
- self.createButton({click_function = 'FFGinitiate', function_owner = self, label = 'Back', position = {-2,0.25,6}, width = 1600, height = 380, font_size = 200, scale = {1,1,1}})
- self.createButton({click_function = 'nil', function_owner = self, label = '[b] [FF0000]PUT CHIPS HERE[/b][-]', position = {4,0.25,0}, width = 1600, height = 380, font_size = 200, scale = {1,1,1}})
- end
- function convertButton1000(object, player)
- clicker = player
- spawnZoneswe('1000')
- end
- --[[ Spawn a scripting zone on the input platform. The actual conversion is performed in the callback function calculateAndConvert --]]
- function spawnZoneswe(value)
- --[[spawn scripting zone on in surface--]]
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- params = {}
- params.type = 'ScriptingTrigger'
- params.callback = 'calculateAndConvert'
- params.callback_owner = self
- params.params = {value}
- params.scale = {4, 9, 6.5}
- params.position = {p.x - math.cos(math.rad(r.y)) * (2.5 * s.x), p.y + 4.5, p.z + math.sin(math.rad(r.y)) * (5.5 * s.x)}
- params.rotation = self.getRotation()
- zone = spawnObject(params)
- end
- --[[ Counts the chips in the zone, spawns new chips, destroys old chips --]]
- function calculateAndConvert(zone, pvalue)
- local chips = {}
- local chipvalues = {1000, 500, 100, 50, 10}
- local yoffset = 0.0825
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local objects = zone.getObjects()
- for i, v in ipairs (objects) do
- if v.tag == 'Chip' and (v.getValue() or tonumber(v.getName()) > 0) then
- chips[#chips+1] = v
- end
- end
- local value = getChipValues(chips)
- if value > (tonumber(pvalue[1]) * outputlimit) then
- broadcastToColor(tostring('Error: Conversion exceeds output limit of '..outputlimit..' chips. Please reduce input amount.'), clicker, {1, 0, 0})
- clicker = {}
- return 0
- end
- --[[ Abort and print message if the conversion will spawn more chips than the output limit--]]
- if value < (1000) then
- broadcastToColor(tostring("Insert at least $1000"),clicker, {1,0.25,0.25})
- clicker = {}
- return 0
- end
- for i, v in ipairs (chipvalues) do
- while v == tonumber(pvalue[1]) and v <= value do
- local params = {}
- params.smooth = false
- params.position = {p.x + math.cos(math.rad(r.y)) * (2 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y)) * (2 * s.x)}
- tokens.takeObject(params)
- value = value - v
- yoffset = yoffset + 0.165
- end
- end
- for i, v in ipairs (chipvalues) do
- while v < tonumber(pvalue[1]) and v <= value do
- local params = {}
- params.type = 'Chip_'..v
- params.position = {p.x + math.cos(math.rad(r.y)) * (2 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y)) * (2 * s.x)}
- spawnObject(params)
- value = (value ) - v
- yoffset = yoffset + 0.165
- end
- end
- --[[ destroy zone --]]
- zone.destruct()
- --[[ destroy inserted money --]]
- for i, v in ipairs (chips) do
- v.destruct()
- end
- clicker = {}
- end
- function getChipValues(chips)
- local value = 0
- for j, w in ipairs (chips) do
- if w.getQuantity() < 0 then
- if w.getValue() then
- value = value + w.getValue()
- else
- value = value + tonumber(w.getName())
- end
- else
- if w.getValue() then
- value = value + (w.getValue() * w.getQuantity())
- else
- value = value + (tonumber(w.getName()) * w.getQuantity())
- end
- end
- end
- return value
- end
- function ffgStart()
- self.clearButtons()
- self.clearInputs()
- self.createButton({click_function = 'FFGinitiate', function_owner = self, label = 'Back', position = {-2,0.25,6}, width = 1600, height = 380, font_size = 200, scale = {1,1,1}})
- self.createButton({click_function = 'nextside', function_owner = self, label = 'Next', position = {6,0.25,6}, width = 1600, height = 380, font_size = 200, scale = {1,1,1}})
- self.createButton({label="Link", click_function="Linkfunc", function_owner=self, position={-2,0.25,2}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="C4", click_function="c4func", function_owner=self, position={-2,0.25,3}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Pikachu", click_function="pikachufunc", function_owner=self, position={-2,0.25,4}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Staryu", click_function="staryufunc", function_owner=self, position={-2,0.25,5}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Charmander", click_function="Charmanderfunc", function_owner=self, position={2,0.25,2}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Ivysaur", click_function="Ivysaurfunc", function_owner=self, position={2,0.25,3}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Bulbasaur", click_function="Bulbasaurfunc", function_owner=self, position={2,0.25,4}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Squirtle", click_function="Squirtlefunc", function_owner=self, position={2,0.25,5}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Magikarp", click_function="Magikarpfunc", function_owner=self, position={6,0.25,2}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Abra", click_function="Abrafunc", function_owner=self, position={6,0.25,3}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Geodude", click_function="Geodudefunc", function_owner=self, position={6,0.25,4}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Kabuto", click_function="Kabutofunc", function_owner=self, position={6,0.25,5}, width = 1600, height = 380, font_size = 200})
- end
- function FFGinitiate()
- if lista ~= nil then
- lista = nil
- end
- if partList ~= nil then
- partList = nil
- end
- initiate()
- end
- function Linkfunc(container, color)
- col = color
- if insertToken() then
- startLuaCoroutine(self, "play")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play ()
- bigbag.getObjects()
- bigbag.takeObject({
- guid="745d53",
- callback_function = function(obj)
- take_callback(obj)
- end,
- })
- return 1
- end
- function take_callback(obj)
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- params.smooth = false
- yoffset = yoffset + 0.165
- clone = obj.clone(params)
- bigbag.putObject(obj)
- clone.setName("link")
- end
- function c4func(container, color)
- col = color
- if insertToken2() then
- startLuaCoroutine(self, "play2")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken2()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play2 ()
- local params = {}
- params.position = self.getPosition()
- params.rotation = self.getRotation()
- params.rotation.x = params.rotation.x - 90
- params.rotation.z = params.rotation.z - 180
- params.position.z = params.position.z - 4
- params.position.y = params.position.y + 3
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- C4.takeObject(params)
- return 1
- end
- function pikachufunc(container, color)
- col = color
- if insertToken3() then
- startLuaCoroutine(self, "play3")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken3()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play3 ()
- local params = {}
- params.position = self.getPosition()
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- params.smooth = false
- yoffset = yoffset + 0.165
- params.smooth = false
- Pikachu.takeObject(params)
- return 1
- end
- function staryufunc(container, color)
- col = color
- if insertToken4() then
- startLuaCoroutine(self, "play4")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken4()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play4 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Staryu.takeObject(params)
- return 1
- end
- function Charmanderfunc(container, color)
- col = color
- if insertToken5() then
- startLuaCoroutine(self, "play5")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken5()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play5 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Charmander.takeObject(params)
- return 1
- end
- function Ivysaurfunc(container, color)
- col = color
- if insertToken6() then
- startLuaCoroutine(self, "play6")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken6()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play6 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Ivysaur.takeObject(params)
- return 1
- end
- function Bulbasaurfunc(container, color)
- col = color
- if insertToken7() then
- startLuaCoroutine(self, "play7")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken7()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play7 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Bulbasaur.takeObject(params)
- return 1
- end
- function Squirtlefunc(container, color)
- col = color
- if insertToken8() then
- startLuaCoroutine(self, "play8")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken8()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play8 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Squirtle.takeObject(params)
- return 1
- end
- function Magikarpfunc(container, color)
- col = color
- if insertToken9() then
- startLuaCoroutine(self, "play9")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken9()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play9 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Magikarp.takeObject(params)
- return 1
- end
- function Abrafunc(container, color)
- col = color
- if insertToken10() then
- startLuaCoroutine(self, "play10")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken10()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play10 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Abra.takeObject(params)
- return 1
- end
- function Geodudefunc(container, color)
- col = color
- if insertToken11() then
- startLuaCoroutine(self, "play11")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken11()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play11 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Geodude.takeObject(params)
- return 1
- end
- function Kabutofunc(container, color)
- col = color
- if insertToken12() then
- startLuaCoroutine(self, "play12")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken12()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play12 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Kabuto.takeObject(params)
- return 1
- end
- function nextside()
- self.clearButtons()
- self.clearInputs()
- self.createButton({click_function = 'FFGinitiate2', function_owner = self, label = 'Back', position = {-2,0.25,6}, width = 1600, height = 380, font_size = 200, scale = {1,1,1}})
- self.createButton({click_function = 'nextside2', function_owner = self, label = 'Next', position = {6,0.25,6}, width = 1600, height = 380, font_size = 200, scale = {1,1,1}})
- self.createButton({label="Mankey", click_function="Mankeyfunc", function_owner=self, position={-2,0.25,2}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Porygon", click_function="Porygonfunc", function_owner=self, position={-2,0.25,3}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Ponyta", click_function="Ponytafunc", function_owner=self, position={-2,0.25,4}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Zubat", click_function="Zubatfunc", function_owner=self, position={-2,0.25,5}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Machop", click_function="Machopfunc", function_owner=self, position={2,0.25,2}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Diglett", click_function="Diglettfunc", function_owner=self, position={2,0.25,3}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Meowth", click_function="Meowthfunc", function_owner=self, position={2,0.25,4}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Ekans", click_function="Ekansfunc", function_owner=self, position={2,0.25,5}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Spearow", click_function="Spearowfunc", function_owner=self, position={6,0.25,2}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Oddish", click_function="Oddishfunc", function_owner=self, position={6,0.25,3}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Poliwag", click_function="Poliwagfunc", function_owner=self, position={6,0.25,4}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Poliwhirl", click_function="Poliwhirlfunc", function_owner=self, position={6,0.25,5}, width = 1600, height = 380, font_size = 200})
- end
- function FFGinitiate2()
- if lista ~= nil then
- lista = nil
- end
- if partList ~= nil then
- partList = nil
- end
- ffgStart()
- end
- function Mankeyfunc(container, color)
- col = color
- if insertToken13() then
- startLuaCoroutine(self, "play13")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken13()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play13 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Mankey.takeObject(params)
- return 1
- end
- function Porygonfunc(container, color)
- col = color
- if insertToken14() then
- startLuaCoroutine(self, "play14")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken14()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play14 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Porygon.takeObject(params)
- return 1
- end
- function Ponytafunc(container, color)
- col = color
- if insertToken15() then
- startLuaCoroutine(self, "play15")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken15()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play15 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Ponyta.takeObject(params)
- return 1
- end
- function Zubatfunc(container, color)
- col = color
- if insertToken16() then
- startLuaCoroutine(self, "play16")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken16()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play16 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Zubat.takeObject(params)
- return 1
- end
- function Machopfunc(container, color)
- col = color
- if insertToken17() then
- startLuaCoroutine(self, "play17")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken17()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play17 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Machop.takeObject(params)
- return 1
- end
- function Diglettfunc(container, color)
- col = color
- if insertToken18() then
- startLuaCoroutine(self, "play18")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken18()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play18 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Diglett.takeObject(params)
- return 1
- end
- function Meowthfunc(container, color)
- col = color
- if insertToken19() then
- startLuaCoroutine(self, "play19")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken19()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play19 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Meowth.takeObject(params)
- return 1
- end
- function Ekansfunc(container, color)
- col = color
- if insertToken20() then
- startLuaCoroutine(self, "play20")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken20()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play20 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Ekans.takeObject(params)
- return 1
- end
- function Spearowfunc(container, color)
- col = color
- if insertToken21() then
- startLuaCoroutine(self, "play21")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken21()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play21 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Spearow.takeObject(params)
- return 1
- end
- function Oddishfunc(container, color)
- col = color
- if insertToken22() then
- startLuaCoroutine(self, "play22")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken22()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play22 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Oddish.takeObject(params)
- return 1
- end
- function Poliwagfunc(container, color)
- col = color
- if insertToken23() then
- startLuaCoroutine(self, "play23")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken23()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play23 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Poliwag.takeObject(params)
- return 1
- end
- function Poliwhirlfunc(container, color)
- col = color
- if insertToken24() then
- startLuaCoroutine(self, "play24")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken24()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play24 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Poliwhirl.takeObject(params)
- return 1
- end
- function nextside2()
- self.clearButtons()
- self.clearInputs()
- self.createButton({click_function = 'FFGinitiate3', function_owner = self, label = 'Back', position = {-2,0.25,6}, width = 1600, height = 380, font_size = 200, scale = {1,1,1}})
- self.createButton({click_function = 'nextside3', function_owner = self, label = 'Next', position = {6,0.25,6}, width = 1600, height = 380, font_size = 200, scale = {1,1,1}})
- self.createButton({label="Psyduck", click_function="Psyduckfunc", function_owner=self, position={-2,0.25,2}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Sandshrew", click_function="Sandshrewfunc", function_owner=self, position={-2,0.25,3}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Clefairy", click_function="Clefairyfunc", function_owner=self, position={-2,0.25,4}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Caterpie", click_function="Caterpiefunc", function_owner=self, position={-2,0.25,5}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="NidoranMale", click_function="NidoranMalefunc", function_owner=self, position={2,0.25,2}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="NidoranFemale", click_function="NidoranFemalefunc", function_owner=self, position={2,0.25,3}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Weedle", click_function="Weedlefunc", function_owner=self, position={2,0.25,4}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Pidgey", click_function="Pidgeyfunc", function_owner=self, position={2,0.25,5}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Vulpix", click_function="Vulpixfunc", function_owner=self, position={6,0.25,2}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Jigglypuff", click_function="Jigglypufffunc", function_owner=self, position={6,0.25,3}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Ratata", click_function="Ratatafunc", function_owner=self, position={6,0.25,4}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Eevee", click_function="Eeveefunc", function_owner=self, position={6,0.25,5}, width = 1600, height = 380, font_size = 200})
- end
- function FFGinitiate3()
- if lista ~= nil then
- lista = nil
- end
- if partList ~= nil then
- partList = nil
- end
- nextside()
- end
- function Psyduckfunc(container, color)
- col = color
- if insertToken25() then
- startLuaCoroutine(self, "play25")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken25()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play25 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Psyduck.takeObject(params)
- return 1
- end
- function Sandshrewfunc(container, color)
- col = color
- if insertToken26() then
- startLuaCoroutine(self, "play26")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken26()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play26 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Sandshrew.takeObject(params)
- return 1
- end
- function Clefairyfunc(container, color)
- col = color
- if insertToken27() then
- startLuaCoroutine(self, "play27")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken27()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play27 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Clefairy.takeObject(params)
- return 1
- end
- function Caterpiefunc(container, color)
- col = color
- if insertToken28() then
- startLuaCoroutine(self, "play28")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken28()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play28 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Caterpie.takeObject(params)
- return 1
- end
- function NidoranMalefunc(container, color)
- col = color
- if insertToken29() then
- startLuaCoroutine(self, "play29")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken29()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play29 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- NidoranMale.takeObject(params)
- return 1
- end
- function NidoranFemalefunc(container, color)
- col = color
- if insertToken30() then
- startLuaCoroutine(self, "play30")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken30()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play30 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- NidoranFemale.takeObject(params)
- return 1
- end
- function Weedlefunc(container, color)
- col = color
- if insertToken31() then
- startLuaCoroutine(self, "play31")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken31()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play31 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Weedle.takeObject(params)
- return 1
- end
- function Pidgeyfunc(container, color)
- col = color
- if insertToken32() then
- startLuaCoroutine(self, "play32")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken32()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play32 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Pidgey.takeObject(params)
- return 1
- end
- function Vulpixfunc(container, color)
- col = color
- if insertToken33() then
- startLuaCoroutine(self, "play33")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken33()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play33 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Vulpix.takeObject(params)
- return 1
- end
- function Jigglypufffunc(container, color)
- col = color
- if insertToken34() then
- startLuaCoroutine(self, "play34")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken34()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play34 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Jigglypuff.takeObject(params)
- return 1
- end
- function Ratatafunc(container, color)
- col = color
- if insertToken35() then
- startLuaCoroutine(self, "play35")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken35()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play35 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Ratata.takeObject(params)
- return 1
- end
- function Eeveefunc(container, color)
- col = color
- if insertToken36() then
- startLuaCoroutine(self, "play36")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken36()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play36 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Eevee.takeObject(params)
- return 1
- end
- function nextside3()
- self.clearButtons()
- self.clearInputs()
- self.createButton({click_function = 'FFGinitiate4', function_owner = self, label = 'Back', position = {-2,0.25,6}, width = 1600, height = 380, font_size = 200, scale = {1,1,1}})
- self.createButton({label="Omanyte", click_function="Omanytefunc", function_owner=self, position={-2,0.25,2}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Ditto", click_function="Dittofunc", function_owner=self, position={-2,0.25,3}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Cubone", click_function="Cubonefunc", function_owner=self, position={-2,0.25,4}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Horsea", click_function="Horseafunc", function_owner=self, position={-2,0.25,5}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Magnemite", click_function="Magnemitefunc", function_owner=self, position={2,0.25,2}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Haunter", click_function="Haunterfunc", function_owner=self, position={2,0.25,3}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Duodrio", click_function="Duodriofunc", function_owner=self, position={2,0.25,4}, width = 1600, height = 380, font_size = 200})
- end
- function FFGinitiate4()
- if lista ~= nil then
- lista = nil
- end
- if partList ~= nil then
- partList = nil
- end
- nextside2()
- end
- function Omanytefunc(container, color)
- col = color
- if insertToken37() then
- startLuaCoroutine(self, "play37")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken37()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play37 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Omanyte.takeObject(params)
- return 1
- end
- function Dittofunc(container, color)
- col = color
- if insertToken38() then
- startLuaCoroutine(self, "play38")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken38()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play38 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Ditto.takeObject(params)
- return 1
- end
- function Cubonefunc(container, color)
- col = color
- if insertToken39() then
- startLuaCoroutine(self, "play39")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken39()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play39 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Cubone.takeObject(params)
- return 1
- end
- function Horseafunc(container, color)
- col = color
- if insertToken40() then
- startLuaCoroutine(self, "play40")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken40()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play40 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Horsea.takeObject(params)
- return 1
- end
- function Magnemitefunc(container, color)
- col = color
- if insertToken41() then
- startLuaCoroutine(self, "play41")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken41()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play41 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Magnemite.takeObject(params)
- return 1
- end
- function Haunterfunc(container, color)
- col = color
- if insertToken42() then
- startLuaCoroutine(self, "play42")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken42()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play42 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Haunter.takeObject(params)
- return 1
- end
- function Duodriofunc(container, color)
- col = color
- if insertToken43() then
- startLuaCoroutine(self, "play43")
- else
- broadcastToColor(tostring("Please insert 1x Small Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertToken43()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Small Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function play43 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Duodrio.takeObject(params)
- return 1
- end
- function mediumprizes1()
- self.clearButtons()
- self.clearInputs()
- self.createButton({click_function = 'FFGinitiate', function_owner = self, label = 'Back', position = {-2,0.25,6}, width = 1600, height = 380, font_size = 200, scale = {1,1,1}})
- self.createButton({click_function = 'nextsideM1', function_owner = self, label = 'Next', position = {6,0.25,6}, width = 1600, height = 380, font_size = 200, scale = {1,1,1}})
- self.createButton({label="Mew", click_function="Mewfunc", function_owner=self, position={-2,0.25,2}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Dragonite", click_function="Dragonitefunc", function_owner=self, position={-2,0.25,3}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Dragonair", click_function="Dragonairfunc", function_owner=self, position={-2,0.25,4}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Magneton", click_function="Magnetonfunc", function_owner=self, position={-2,0.25,5}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Lapras", click_function="Laprasfunc", function_owner=self, position={2,0.25,2}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Vaporeon", click_function="Vaporeonfunc", function_owner=self, position={2,0.25,3}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Jolteon", click_function="Jolteonfunc", function_owner=self, position={2,0.25,4}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Flareon", click_function="Flareonfunc", function_owner=self, position={2,0.25,5}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Charmeleon", click_function="Charmeleonfunc", function_owner=self, position={6,0.25,2}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Snorlax", click_function="Snorlaxfunc", function_owner=self, position={6,0.25,3}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Dugtrio", click_function="Dugtriofunc", function_owner=self, position={6,0.25,4}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Wartortle", click_function="Wartortlefunc", function_owner=self, position={6,0.25,5}, width = 1600, height = 380, font_size = 200})
- end
- function FFGinitiate()
- if lista ~= nil then
- lista = nil
- end
- if partList ~= nil then
- partList = nil
- end
- initiate()
- end
- function Mewfunc(container, color)
- col = color
- if insertTokenM1() then
- startLuaCoroutine(self, "playM1")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM1()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM1 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Mew.takeObject(params)
- return 1
- end
- function Dragonitefunc(container, color)
- col = color
- if insertTokenM2() then
- startLuaCoroutine(self, "playM2")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM2()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM2 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Dragonite.takeObject(params)
- return 1
- end
- function Dragonairfunc(container, color)
- col = color
- if insertTokenM3() then
- startLuaCoroutine(self, "playM3")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM3()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM3 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Dragonair.takeObject(params)
- return 1
- end
- function Magnetonfunc(container, color)
- col = color
- if insertTokenM4() then
- startLuaCoroutine(self, "playM4")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM4()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM4 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Magneton.takeObject(params)
- return 1
- end
- function Laprasfunc(container, color)
- col = color
- if insertTokenM5() then
- startLuaCoroutine(self, "playM5")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM5()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM5 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Lapras.takeObject(params)
- return 1
- end
- function Vaporeonfunc(container, color)
- col = color
- if insertTokenM6() then
- startLuaCoroutine(self, "playM6")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM6()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM6 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Vaporeon.takeObject(params)
- return 1
- end
- function Jolteonfunc(container, color)
- col = color
- if insertTokenM7() then
- startLuaCoroutine(self, "playM7")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM7()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM7 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Jolteon.takeObject(params)
- return 1
- end
- function Flareonfunc(container, color)
- col = color
- if insertTokenM8() then
- startLuaCoroutine(self, "playM8")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM8()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM8 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Flareon.takeObject(params)
- return 1
- end
- function Charmeleonfunc(container, color)
- col = color
- if insertTokenM9() then
- startLuaCoroutine(self, "playM9")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM9()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM9 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Charmeleon.takeObject(params)
- return 1
- end
- function Snorlaxfunc(container, color)
- col = color
- if insertTokenM10() then
- startLuaCoroutine(self, "playM10")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM10()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM10 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Snorlax.takeObject(params)
- return 1
- end
- function Dugtriofunc(container, color)
- col = color
- if insertTokenM11() then
- startLuaCoroutine(self, "playM11")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM11()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM11 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Dugtrio.takeObject(params)
- return 1
- end
- function Wartortlefunc(container, color)
- col = color
- if insertTokenM12() then
- startLuaCoroutine(self, "playM12")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM12()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM12 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Wartortle.takeObject(params)
- return 1
- end
- function nextsideM1()
- self.clearButtons()
- self.clearInputs()
- self.createButton({click_function = 'backM1', function_owner = self, label = 'Back', position = {-2,0.25,6}, width = 1600, height = 380, font_size = 200, scale = {1,1,1}})
- self.createButton({click_function = 'nextsideM2', function_owner = self, label = 'Next', position = {6,0.25,6}, width = 1600, height = 380, font_size = 200, scale = {1,1,1}})
- self.createButton({label="Masterball", click_function="Masterballfunc", function_owner=self, position={-2,0.25,2}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Safariball", click_function="Safariballfunc", function_owner=self, position={-2,0.25,3}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Pokeball", click_function="Pokeballfunc", function_owner=self, position={-2,0.25,4}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Levelball", click_function="Levelballfunc", function_owner=self, position={-2,0.25,5}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Cloneball", click_function="Cloneballfunc", function_owner=self, position={2,0.25,2}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Ultraball", click_function="Ultraballfunc", function_owner=self, position={2,0.25,3}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Premierball", click_function="Premierballfunc", function_owner=self, position={2,0.25,4}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Loveball", click_function="Loveballfunc", function_owner=self, position={2,0.25,5}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Greatball", click_function="Greatballfunc", function_owner=self, position={6,0.25,2}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Cherishball", click_function="Cherishballfunc", function_owner=self, position={6,0.25,3}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Lureball", click_function="Lureballfunc", function_owner=self, position={6,0.25,4}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="[FFFF00]Ambrosia", click_function="Ambrosiafunc", function_owner=self, position={6,0.25,5}, width = 1600, height = 380, font_size = 200})
- end
- function backM1()
- if lista ~= nil then
- lista = nil
- end
- if partList ~= nil then
- partList = nil
- end
- mediumprizes1()
- end
- function Masterballfunc(container, color)
- col = color
- if insertTokenM13() then
- startLuaCoroutine(self, "playM13")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM13()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM13 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Masterball.takeObject(params)
- return 1
- end
- function Safariballfunc(container, color)
- col = color
- if insertTokenM14() then
- startLuaCoroutine(self, "playM14")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM14()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM14 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Safariball.takeObject(params)
- return 1
- end
- function Pokeballfunc(container, color)
- col = color
- if insertTokenM15() then
- startLuaCoroutine(self, "playM15")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM15()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM15 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Pokeball.takeObject(params)
- return 1
- end
- function Levelballfunc(container, color)
- col = color
- if insertTokenM16() then
- startLuaCoroutine(self, "playM16")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM16()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM16 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Levelball.takeObject(params)
- return 1
- end
- function Cloneballfunc(container, color)
- col = color
- if insertTokenM17() then
- startLuaCoroutine(self, "playM17")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM17()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM17 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Cloneball.takeObject(params)
- return 1
- end
- function Ultraballfunc(container, color)
- col = color
- if insertTokenM18() then
- startLuaCoroutine(self, "playM18")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM18()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM18 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Ultraball.takeObject(params)
- return 1
- end
- function Premierballfunc(container, color)
- col = color
- if insertTokenM19() then
- startLuaCoroutine(self, "playM19")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM19()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM19 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Premierball.takeObject(params)
- return 1
- end
- function Loveballfunc(container, color)
- col = color
- if insertTokenM20() then
- startLuaCoroutine(self, "playM20")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM20()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM20 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Loveball.takeObject(params)
- return 1
- end
- function Greatballfunc(container, color)
- col = color
- if insertTokenM21() then
- startLuaCoroutine(self, "playM21")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM21()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM21 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Greatball.takeObject(params)
- return 1
- end
- function Cherishballfunc(container, color)
- col = color
- if insertTokenM22() then
- startLuaCoroutine(self, "playM22")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM22()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM22 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Cherishball.takeObject(params)
- return 1
- end
- function Lureballfunc(container, color)
- col = color
- if insertTokenM23() then
- startLuaCoroutine(self, "playM23")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM23()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM23 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Lureball.takeObject(params)
- return 1
- end
- function Ambrosiafunc(container, color)
- col = color
- if insertTokenM24() then
- startLuaCoroutine(self, "playM24")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM24()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM24 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Ambrosia.takeObject(params)
- return 1
- end
- function nextsideM2()
- self.clearButtons()
- self.clearInputs()
- self.createButton({click_function = 'backM2', function_owner = self, label = 'Back', position = {-2,0.25,6}, width = 1600, height = 380, font_size = 200, scale = {1,1,1}})
- self.createButton({click_function = 'nextsideM3', function_owner = self, label = 'Next', position = {6,0.25,6}, width = 1600, height = 380, font_size = 200, scale = {1,1,1}})
- self.createButton({label="Slurm", click_function="Slurmfunc", function_owner=self, position={-2,0.25,2}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Duff", click_function="Dufffunc", function_owner=self, position={-2,0.25,3}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Pokegear blue", click_function="Pokegearbluefunc", function_owner=self, position={-2,0.25,4}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Pokegear pink", click_function="Pokegearpinkfunc", function_owner=self, position={-2,0.25,5}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Gameboy", click_function="Gameboyfunc", function_owner=self, position={2,0.25,2}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Cooler", click_function="Coolerfunc", function_owner=self, position={2,0.25,3}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Pokecenter", click_function="Pokecenterfunc", function_owner=self, position={2,0.25,4}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Skyrim Logo Bag", click_function="Skyrimfunc", function_owner=self, position={2,0.25,5}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Probedroid", click_function="Probedroidfunc", function_owner=self, position={6,0.25,2}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Useless Device", click_function="Uselessdevicefunc", function_owner=self, position={6,0.25,3}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="[1CE055]Rupeebag[-]", click_function="Rupeebagfunc", function_owner=self, position={6,0.25,4}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Brain", click_function="Brainfunc", function_owner=self, position={6,0.25,5}, width = 1600, height = 380, font_size = 200})
- end
- function backM2()
- if lista ~= nil then
- lista = nil
- end
- if partList ~= nil then
- partList = nil
- end
- nextsideM1()
- end
- function Slurmfunc(container, color)
- col = color
- if insertTokenM25() then
- startLuaCoroutine(self, "playM25")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM25()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM25 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Slurm.takeObject(params)
- return 1
- end
- function Dufffunc(container, color)
- col = color
- if insertTokenM26() then
- startLuaCoroutine(self, "playM26")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM26()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM26 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Duff.takeObject(params)
- return 1
- end
- function Pokegearbluefunc(container, color)
- col = color
- if insertTokenM27() then
- startLuaCoroutine(self, "playM27")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM27()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM27 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Pokegearblue.takeObject(params)
- return 1
- end
- function Pokegearpinkfunc(container, color)
- col = color
- if insertTokenM28() then
- startLuaCoroutine(self, "playM28")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM28()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM28 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Pokegearpink.takeObject(params)
- return 1
- end
- function Gameboyfunc(container, color)
- col = color
- if insertTokenM29() then
- startLuaCoroutine(self, "playM29")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM29()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM29 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Gameboy.takeObject(params)
- return 1
- end
- function Coolerfunc(container, color)
- col = color
- if insertTokenM30() then
- startLuaCoroutine(self, "playM30")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM30()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM30 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Cooler.takeObject(params)
- return 1
- end
- function Pokecenterfunc(container, color)
- col = color
- if insertTokenM31() then
- startLuaCoroutine(self, "playM31")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM31()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM31 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Pokecenter.takeObject(params)
- return 1
- end
- function Skyrimfunc(container, color)
- col = color
- if insertTokenM32() then
- startLuaCoroutine(self, "playM32")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM32()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM32 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Skyrim.takeObject(params)
- return 1
- end
- function Probedroidfunc(container, color)
- col = color
- if insertTokenM33() then
- startLuaCoroutine(self, "playM33")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM33()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM33 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Probedroid.takeObject(params)
- return 1
- end
- function Uselessdevicefunc(container, color)
- col = color
- if insertTokenM34() then
- startLuaCoroutine(self, "playM34")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM34()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM34 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Uselessdevice.takeObject(params)
- return 1
- end
- function Rupeebagfunc(container, color)
- col = color
- if insertTokenM35() then
- startLuaCoroutine(self, "playM35")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM35()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM35 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Rupeebag.takeObject(params)
- return 1
- end
- function Brainfunc(container, color)
- col = color
- if insertTokenM36() then
- startLuaCoroutine(self, "playM36")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM36()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM36 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Brain.takeObject(params)
- return 1
- end
- function nextsideM3()
- self.clearButtons()
- self.clearInputs()
- self.createButton({click_function = 'backM3', function_owner = self, label = 'Back', position = {-2,0.25,6}, width = 1600, height = 380, font_size = 200, scale = {1,1,1}})
- self.createButton({click_function = 'nextsideM4', function_owner = self, label = 'Next', position = {6,0.25,6}, width = 1600, height = 380, font_size = 200, scale = {1,1,1}})
- self.createButton({label="Black Skeleton", click_function="BlackSkelefunc", function_owner=self, position={-2,0.25,2}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Diamond", click_function="Diamondfunc", function_owner=self, position={-2,0.25,3}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Skelenton/Bow", click_function="Skelebowfunc", function_owner=self, position={-2,0.25,4}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Black Skeleton/Bow", click_function="Blackskelebowfunc", function_owner=self, position={-2,0.25,5}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Dwarven Helmet", click_function="DwarvenHefunc", function_owner=self, position={2,0.25,2}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Bonecrown", click_function="Bonecrownfunc", function_owner=self, position={2,0.25,3}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Black Skull", click_function="BlackSkullfunc", function_owner=self, position={2,0.25,4}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Kynareth", click_function="Kynarethfunc", function_owner=self, position={2,0.25,5}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Stendarr", click_function="Stendarrfunc", function_owner=self, position={6,0.25,2}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Talos", click_function="Talosfunc", function_owner=self, position={6,0.25,3}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Dibella", click_function="Dibellafunc", function_owner=self, position={6,0.25,4}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Akatosh", click_function="Akatoshfunc", function_owner=self, position={6,0.25,5}, width = 1600, height = 380, font_size = 200})
- end
- function backM3()
- if lista ~= nil then
- lista = nil
- end
- if partList ~= nil then
- partList = nil
- end
- nextsideM2()
- end
- function BlackSkelefunc(container, color)
- col = color
- if insertTokenM37() then
- startLuaCoroutine(self, "playM37")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM37()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM37 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- BlackSkele.takeObject(params)
- return 1
- end
- function Diamondfunc(container, color)
- col = color
- if insertTokenM38() then
- startLuaCoroutine(self, "playM38")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM38()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM38 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Diamond.takeObject(params)
- return 1
- end
- function Skelebowfunc(container, color)
- col = color
- if insertTokenM39() then
- startLuaCoroutine(self, "playM39")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM39()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM39 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Skelebow.takeObject(params)
- return 1
- end
- function Blackskelebowfunc(container, color)
- col = color
- if insertTokenM40() then
- startLuaCoroutine(self, "playM40")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM40()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM40 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Blackskelebow.takeObject(params)
- return 1
- end
- function DwarvenHefunc(container, color)
- col = color
- if insertTokenM41() then
- startLuaCoroutine(self, "playM41")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM41()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM41 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- DwarvenHe.takeObject(params)
- return 1
- end
- function Bonecrownfunc(container, color)
- col = color
- if insertTokenM42() then
- startLuaCoroutine(self, "playM42")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM42()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM42 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Bonecrown.takeObject(params)
- return 1
- end
- function BlackSkullfunc(container, color)
- col = color
- if insertTokenM43() then
- startLuaCoroutine(self, "playM43")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM43()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM43 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- BlackSkull.takeObject(params)
- return 1
- end
- function Kynarethfunc(container, color)
- col = color
- if insertTokenM44() then
- startLuaCoroutine(self, "playM44")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM44()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM44 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Kynareth.takeObject(params)
- return 1
- end
- function Stendarrfunc(container, color)
- col = color
- if insertTokenM45() then
- startLuaCoroutine(self, "playM45")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM45()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM45 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Stendarr.takeObject(params)
- return 1
- end
- function Talosfunc(container, color)
- col = color
- if insertTokenM46() then
- startLuaCoroutine(self, "playM46")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM46()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM46 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Talos.takeObject(params)
- return 1
- end
- function Dibellafunc(container, color)
- col = color
- if insertTokenM47() then
- startLuaCoroutine(self, "playM47")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM47()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM47 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Dibella.takeObject(params)
- return 1
- end
- function Akatoshfunc(container, color)
- col = color
- if insertTokenM48() then
- startLuaCoroutine(self, "playM48")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM48()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM48 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Akatosh.takeObject(params)
- return 1
- end
- function nextsideM4()
- self.clearButtons()
- self.clearInputs()
- self.createButton({click_function = 'backM4', function_owner = self, label = 'Back', position = {-2,0.25,6}, width = 1600, height = 380, font_size = 200, scale = {1,1,1}})
- --self.createButton({click_function = 'nextsideM5', function_owner = self, label = 'Next', position = {6,0.25,6}, width = 1600, height = 380, font_size = 200, scale = {1,1,1}})
- self.createButton({label="Zenithar", click_function="Zenitharfunc", function_owner=self, position={-2,0.25,2}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Mara", click_function="Marafunc", function_owner=self, position={-2,0.25,3}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Julianos", click_function="Julianosfunc", function_owner=self, position={-2,0.25,4}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Arkay", click_function="Arkayfunc", function_owner=self, position={-2,0.25,5}, width = 1600, height = 380, font_size = 200})
- --self.createButton({label="A", click_function="Cloneballfunc", function_owner=self, position={2,0.25,2}, width = 1600, height = 380, font_size = 200})
- --self.createButton({label="A", click_function="Ultraballfunc", function_owner=self, position={2,0.25,3}, width = 1600, height = 380, font_size = 200})
- --self.createButton({label="?", click_function="Premierballfunc", function_owner=self, position={2,0.25,4}, width = 1600, height = 380, font_size = 200})
- --self.createButton({label="?", click_function="Loveballfunc", function_owner=self, position={2,0.25,5}, width = 1600, height = 380, font_size = 200})
- --self.createButton({label="?", click_function="Greatballfunc", function_owner=self, position={6,0.25,2}, width = 1600, height = 380, font_size = 200})
- --self.createButton({label="?", click_function="Cherishballfunc", function_owner=self, position={6,0.25,3}, width = 1600, height = 380, font_size = 200})
- --self.createButton({label="?", click_function="Lureballfunc", function_owner=self, position={6,0.25,4}, width = 1600, height = 380, font_size = 200})
- --self.createButton({label="?", click_function="Ambrosiafunc", function_owner=self, position={6,0.25,5}, width = 1600, height = 380, font_size = 200})
- end
- function backM4()
- if lista ~= nil then
- lista = nil
- end
- if partList ~= nil then
- partList = nil
- end
- nextsideM3()
- end
- function Zenitharfunc(container, color)
- col = color
- if insertTokenM49() then
- startLuaCoroutine(self, "playM49")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM49()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM49 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Zenithar.takeObject(params)
- return 1
- end
- function Marafunc(container, color)
- col = color
- if insertTokenM50() then
- startLuaCoroutine(self, "playM50")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM50()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM50 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Mara.takeObject(params)
- return 1
- end
- function Julianosfunc(container, color)
- col = color
- if insertTokenM51() then
- startLuaCoroutine(self, "playM51")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM51()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM51 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Julianos.takeObject(params)
- return 1
- end
- function Arkayfunc(container, color)
- col = color
- if insertTokenM52() then
- startLuaCoroutine(self, "playM52")
- else
- broadcastToColor(tostring("Please insert 1x Medium Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenM52()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Medium Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playM52 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Arkay.takeObject(params)
- return 1
- end
- function largeprizes1()
- self.clearButtons()
- self.clearInputs()
- self.createButton({click_function = 'FFGinitiate', function_owner = self, label = 'Back', position = {-2,0.25,6}, width = 1600, height = 380, font_size = 200, scale = {1,1,1}})
- self.createButton({click_function = 'nextsideL1', function_owner = self, label = 'Next', position = {6,0.25,6}, width = 1600, height = 380, font_size = 200, scale = {1,1,1}})
- self.createButton({label="Moltres", click_function="Moltresfunc", function_owner=self, position={-2,0.25,2}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Zapdos", click_function="Zapdosfunc", function_owner=self, position={-2,0.25,3}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Articuno", click_function="Articunofunc", function_owner=self, position={-2,0.25,4}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Mewtwo", click_function="Mewtwofunc", function_owner=self, position={-2,0.25,5}, width = 1600, height = 380, font_size = 200})
- self.createButton({label="Lady", click_function="Ladyfunc", function_owner=self, position={2,0.25,2}, width = 1600, height = 380, font_size = 200})
- end
- function FFGinitiate()
- if lista ~= nil then
- lista = nil
- end
- if partList ~= nil then
- partList = nil
- end
- initiate()
- end
- function Moltresfunc(container, color)
- col = color
- if insertTokenL1() then
- startLuaCoroutine(self, "playL1")
- else
- broadcastToColor(tostring("Please insert 1x Large Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenL1()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Large Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playL1 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Moltres.takeObject(params)
- return 1
- end
- function Zapdosfunc(container, color)
- col = color
- if insertTokenL2() then
- startLuaCoroutine(self, "playL2")
- else
- broadcastToColor(tostring("Please insert 1x Large Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenL2()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Large Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playL2 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Zapdos.takeObject(params)
- return 1
- end
- function Articunofunc(container, color)
- col = color
- if insertTokenL3() then
- startLuaCoroutine(self, "playL3")
- else
- broadcastToColor(tostring("Please insert 1x Large Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenL3()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Large Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playL3 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Articuno.takeObject(params)
- return 1
- end
- function Mewtwofunc(container, color)
- col = color
- if insertTokenL4() then
- startLuaCoroutine(self, "playL4")
- else
- broadcastToColor(tostring("Please insert 1x Large Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenL4()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Large Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playL4 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Mewtwo.takeObject(params)
- return 1
- end
- function Ladyfunc(container, color)
- col = color
- if insertTokenL5() then
- startLuaCoroutine(self, "playL5")
- else
- broadcastToColor(tostring("Please insert 1x Large Prize Token."),color, {1,0.25,0.25})
- end
- end
- function insertTokenL5()
- for i, obj in pairs(self.getObjects()) do
- if obj.name == "Large Prize Token" then
- local params = {}
- params.guid = obj.guid
- params.smooth = true
- params.position = self.getPosition()
- params.position.y = params.position.y + 4
- takenObject = self.takeObject(params)
- takenObject.destruct()
- return true
- end
- end
- return false
- end
- function playL5 ()
- local params = {}
- local p = self.getPosition()
- local r = self.getRotation()
- local s = self.getScale()
- local yoffset = 0.0825
- params.position = {p.x + math.cos(math.rad(r.y+90)) * (3 * s.x), p.y + yoffset, p.z - math.sin(math.rad(r.y+90)) * (3 * s.x)}
- yoffset = yoffset + 0.165
- params.smooth = false
- Lady.takeObject(params)
- return 1
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement