Draw_set_color(c_white); Giving error saying unknown function

A

Ancestralsoul

Guest
could anyone help or point out what I'm doing wrong? I have it on the first line of code for my point object. I'm using drag and drop and executed the piece of code.
 

TsukaYuriko

☄️
Forum Staff
Moderator
Draw_set_color is not a GML function. Did you mean draw_set_color? Capitalization is important.
 
A

Ancestralsoul

Guest
Yep it's color. I was trying to make a score. I put these two lines on create for the score object right?

draw_set_color(c_white);
draw_text(40,50,global.points);

Now I'm getting this error.
Isn't there a Set Color action already?

And is it color or colour? lol I think it's still color...

It's saying assignment operator expected.
but now I'm getting malformed assignment statement
 
A

Ancestralsoul

Guest
Post the actual error.

You aren't using a DnD action are you? Just straight gml code?
It's just straight code. 2 lines
object1 Event: Draw at line 5, 23 : Got 'white' (id) expected ',' in DnD™ action Execute Code
object1 Event: Draw at line 5, 24 : number of arguments expected 1 got 0 in DnD™ action Execute Code
object1 Event: Draw at line 5, 16 : unassigned variable c referenced
objectscore at line 5, 7 : unnecessary expression (global . points) used as a statement
points Event: Create at line 5, 7 : unnecessary expression (global . points) used as a statement
points Event: Create at line 5, 7 : unnecessary expression (global . points) used as a statement
object1 Key Pressed: Key Press - Right at line 20, 1 : variable Score only referenced once
 

TsukaYuriko

☄️
Forum Staff
Moderator
Is the code you posted the actual code as it appears in the code editor?

The error messages indicate that you put a space in between c and white instead of an underscore and spaces to the left and right of the dot in all global variables.

@TheouAegis: In GMS2, both are valid.
 
A

Ancestralsoul

Guest
Is the code you posted the actual code as it appears in the code editor?

The error messages indicate that you put a space in between c and white instead of an underscore and spaces to the left and right of the dot in all global variables.

@TheouAegis: In GMS2, both are valid.
Well I just fixed some of the exactness on the 2 lines in particular. It got rid of the errors...However, I'm still getting these two errors.:

"assignment operator expected"
and "Malformed assignment statement."
 

FrostyCat

Redemption Seeker
Well I just fixed some of the exactness on the 2 lines in particular. It got rid of the errors...However, I'm still getting these two errors.:

"assignment operator expected"
and "Malformed assignment statement."
You are getting those errors because you still have syntax errors and careless typos in your code, and you have been told that several times now.

For the last time, post your actual code. Have I told you that you have been told that several times as well?
 
Top