This is a read-only snapshot of the ComputerCraft forums, taken in April 2020.
kingcoon's profile picture

CC GUI help.

Started by kingcoon, 26 December 2012 - 10:46 PM
kingcoon #1
Posted 26 December 2012 - 11:46 PM
Help please, i have read through a tutorial for a menu type GUI for CC.
I wanted to add some of my own options and functions to it so I took it as a base and added onto it. here it is (most of it is not my work) : http://pastebin.com/7P1zs7YQ
whenever i run it it shows the "main" menu screen with the options programs, info and quit on it, after a few seconds the screen goes black and the only way to do anything is to press "ESC" and reboot.
it has no error message so I have no idea what is wrong.

Anyone who thinks they could help please read over it, find anything wrong and let me know.


thanks,
kingcoon
ChunLing #2
Posted 27 December 2012 - 12:07 AM
If you had a version of this that worked, post a link to that as well.
kingcoon #3
Posted 27 December 2012 - 12:10 AM
it is cool isn't it i will edit as soon as it woks.

here is the link to the original : http://pastebin.com/UiMJPdGT

and the forum post : http://www.computerc...ontrolled-menu/


The original works but it doesn't really do anything
remiX #4
Posted 27 December 2012 - 01:19 AM
I found the problem was being that if you click something that's there, and it changes the state to what you have clicked, like doors. But if that state has no option in the big if statement for each state, it bugs out.

Here's a fixed version, works pretty nicely: pastebin

Edit: Fixed the indentation and put it on pastebin
kingcoon #5
Posted 27 December 2012 - 12:11 PM
your the best, I would have never picked that up