3 posts
Posted 17 July 2015 - 11:25 AM
Hey first post….
when I try to run my first os ".menu" it comes up with "bios:367: [string ".menu"]:3: unexpected symbol"
I know the basic programing language but do not know how to read the error message please help
Links:
Pastebin)-
http://pastebin.com/6geVVyU9ps) if you see anything else that is wrong please let me know.
Thanks Awesome community :)/>
656 posts
Posted 17 July 2015 - 11:51 AM
On line 4:
function printCentered (y.s)
Fumction arguments are separated by a ',' instead of a '.'.
Here is a guide about reading errors, try looking there yourself next time :)/>.
If you're still a beginner I recommend not starting with an os, even though there are
certain tutorials about making oses.
3 posts
Posted 18 July 2015 - 12:20 AM
Hi thanks for the reply i've put in the commar and rebooted my system but.. it still comes up with the same message "bios:367: [string ".menu"]:3: unexpected symbol" again.
i have change the "." symbol to a "," symbol.
8543 posts
Posted 18 July 2015 - 12:48 AM
You've got the same problem on line 3 of the pastebin, as well as lines 18 and 47.
3 posts
Posted 18 July 2015 - 01:31 AM
term.clear
local function drawFrontend()
printCentered(math.floor(h/2) - 3, "")
printCentered(math.floor(h/2) - 2, "Start Menu"
printCentered(math.floor(h/2) - 1, ""
printCentered(math.floor(h/2) + 0, ((nOption == 1) and "[ Command ]") or "Command"
printCentered(math.floor(h/2) + 1, ((nOption == 2)and "[ Programs ]") or "Programs"
printCentered(math.floor(h/2) + 2, ((nOption == 3) and "[ Shutdown ]") or "Shutdown"
printCentered(math.floor(h/2) + 3, ((nOption == 4)and "[ Uninstall]") or "Uninstall"
end
sorry about the 1,10 it should be 31,41
8543 posts
Posted 18 July 2015 - 02:07 AM
Threads merged. Please stick to one topic for all questions about a given piece of code.
656 posts
Posted 18 July 2015 - 07:24 AM
You forgot the '()' on term.clear and the ')' on some of those centerPrints.
Edited on 18 July 2015 - 05:24 AM