.
This commit is contained in:
		
							parent
							
								
									17f68aa860
								
							
						
					
					
						commit
						8717798bd7
					
				| @ -4,7 +4,7 @@ local selectedItem = 1 | |||||||
| local inMainMenu = true | local inMainMenu = true | ||||||
| local inLightsMenu = false | local inLightsMenu = false | ||||||
| local color = "off" | local color = "off" | ||||||
| 
 | os.pullEvent = os.pullEventRaw | ||||||
| 
 | 
 | ||||||
| --[[Menu Methods]]-- | --[[Menu Methods]]-- | ||||||
| function Choice1() | function Choice1() | ||||||
| @ -52,6 +52,8 @@ end | |||||||
| 
 | 
 | ||||||
| function Edit() | function Edit() | ||||||
|   inMainMenu = false |   inMainMenu = false | ||||||
|  |   shell.run("edit "..shell.getRunningProgram()) | ||||||
|  |   os.reboot() | ||||||
| end | end | ||||||
| 
 | 
 | ||||||
| function Reboot() | function Reboot() | ||||||
| @ -131,7 +133,19 @@ function lightSystem( op, type ) | |||||||
|   elseif color == "red" and op == "on" and type == "white" then |   elseif color == "red" and op == "on" and type == "white" then | ||||||
|     redstone.setBundledOutput("top", colors.white + colors.red) |     redstone.setBundledOutput("top", colors.white + colors.red) | ||||||
|     color = "both" |     color = "both" | ||||||
| --[[Off functions]]-- |   elseif color == "white" and op == "on" and type == "white" then | ||||||
|  |     redstone.setBundledOutput("top", colors.white) | ||||||
|  |     color = "white" | ||||||
|  |   elseif color == "red" and op == "on" and type == "red" then | ||||||
|  |     redstone.setBundledOutput("top", colors.red) | ||||||
|  |     color = "red" | ||||||
|  |   elseif color == "both" and op == "on" and type == "white" then | ||||||
|  |     redstone.setBundledOutput("top", colors.white + colors.red) | ||||||
|  |     color = "both" | ||||||
|  |   elseif color == "both" and op == "on" and type == "red" then | ||||||
|  |     redstone.setBundledOutput("top", colors.white + colors.red) | ||||||
|  |     color = "both" | ||||||
|  | 
 | ||||||
|   elseif color == "both" and op == "off" and type == "white" then |   elseif color == "both" and op == "off" and type == "white" then | ||||||
|     redstone.setBundledOutput("top", colors.red) |     redstone.setBundledOutput("top", colors.red) | ||||||
|     color = "red" |     color = "red" | ||||||
| @ -144,7 +158,19 @@ function lightSystem( op, type ) | |||||||
|   elseif color == "red" and op == "off" and type == "red" then |   elseif color == "red" and op == "off" and type == "red" then | ||||||
|     redstone.setBundledOutput("top", 0) |     redstone.setBundledOutput("top", 0) | ||||||
|     color = "off" |     color = "off" | ||||||
|   else error("Light system error " .. op .. " " .. type .. " " .. color) |   elseif color == "off" and op == "off" and type == "white" then | ||||||
|  |     redstone.setBundledOutput("top", 0) | ||||||
|  |     color = "off" | ||||||
|  |   elseif color == "off" and op == "off" and type == "red" then | ||||||
|  |     redstone.setBundledOutput("top", 0) | ||||||
|  |     color = "off" | ||||||
|  |   elseif color == "white" and op == "off" and type == "red" then | ||||||
|  |     redstone.setBundledOutput("top", colors.white) | ||||||
|  |     color = "white" | ||||||
|  |   elseif color == "red" and op == "off" and type == "white" then | ||||||
|  |     redstone.setBundledOutput("top", colors.red) | ||||||
|  |     color = "red" | ||||||
|  |   else error("Light system error you tried to: Turn " .. op .. " color " .. type .. " when the state of color in memory is: " .. color) | ||||||
|   end |   end | ||||||
|   inLightsMenu = false |   inLightsMenu = false | ||||||
|   selectedItem = 1 |   selectedItem = 1 | ||||||
|  | |||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user