Advertisement
Guest User

Untitled

a guest
Mar 27th, 2017
74
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.92 KB | None | 0 0
  1. shadowCaster = {"f36ca6", "7e6721", "950033", "e40b43", "dc8b4a", "ec767f", "4c656d", "f048d4"}
  2.  
  3. --Set Prams for Mission Selector Button
  4. butDayNight = {}
  5.     butDayNight.click_function = 'dayNight'
  6.     butDayNight.label = 'Night'
  7.     butDayNight.function_owner = self
  8.     butDayNight.rotation = { 0, 180, 0 }
  9.     butDayNight.position = { 0, 1.2, 0 }
  10.     butDayNight.font_size = 400
  11.     butDayNight.width = 4200
  12.     butDayNight.height = 1650
  13.     butDayNight.index = 0
  14.  
  15. function onload()
  16.     self.createButton(butDayNight)
  17. end -- END onload()
  18.  
  19. function dayNight()
  20.     local ScaleSet = {0.001,0.001,0.001}
  21.  
  22.     if butDayNight.index == 0 then
  23.         for i = 1, #shadowCaster do
  24.             local obj = getObjectFromGUID(shadowCaster[i])
  25.             obj.setScale(ScaleSet)
  26.         end
  27.         butDayNight = {}
  28.             butDayNight.index = 1
  29.             butDayNight.label = 'Day'
  30.  
  31.     end
  32. end -- END dayNight()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement