209 posts
Location
Denmark
Posted 24 November 2015 - 11:51 PM
Hello fellow ComputerCrafters
i hope this is an easy fix..
im getting a syntax error in this line
local event, button, MouseX, MouseY = os.pullEvent("mouse_click") (Solved)Is there anything wrong with that line? or should i look elsewhere in my program?
New problem:
http://pastebin.com/5DLmVSzPWindow:88: expected number (solved)
a pair of "" had found its way into a setTextColor()
Edited on 25 November 2015 - 06:37 AM
1080 posts
Location
In the Matrix
Posted 24 November 2015 - 11:52 PM
try the line above it
818 posts
Location
Wherever you want me to be
Posted 25 November 2015 - 06:26 AM
can you post full code and the line number please? that would help us help you. though, try doing
e,b,x,y = os.pullEvent("mouse_click")
209 posts
Location
Denmark
Posted 25 November 2015 - 06:57 AM
Dragon was right on this one.. it was the line above it..
But now i ran into a new problem..
window:88: expected number
http://pastebin.com/5DLmVSzPonly problem is.. my code is only 69 lines long..
(updated top post aswell)
Edited on 25 November 2015 - 06:05 AM
1583 posts
Location
Germany
Posted 25 November 2015 - 07:09 AM
If the window API causes an error, it most likely is a malformed term call.
//Edit: on line 28 you are using a string for .setTextColor, but it wants a number.
Edited on 25 November 2015 - 06:11 AM
209 posts
Location
Denmark
Posted 25 November 2015 - 07:24 AM
arh.. didnt even notice that one :)/>
thanks for that one.. i'll check if that solved the problem (need to boot my game)
818 posts
Location
Wherever you want me to be
Posted 25 November 2015 - 10:51 AM
might want to point out, the colours api is your friend. for example you did setTextColor(green), which needs to be setTextColour(colours.green) (or colors.green)
do "help colours" in the shell for more colours
7083 posts
Location
Tasmania (AU)
Posted 25 November 2015 - 10:57 AM
Line 5 has him covered there.