1
\$\begingroup\$

I'm currently using gamemaker studio 2 following a youtube guide on making my first game. I am very new to coding and need some help.

Im getting this error message attached to my code and I'm not sure why.

enter image description here

\$\endgroup\$
  • 1
    \$\begingroup\$ Can we assume this persists after saving? \$\endgroup\$ – Weckar E. Apr 19 '17 at 6:59
  • 1
    \$\begingroup\$ Use double quote " instead single ': dash_key = keyboard_check_pressed(ord("C")); \$\endgroup\$ – Dmi7ry Apr 21 '17 at 4:34
1
\$\begingroup\$

It should be

dash_key = keyboard_check_pressed(ord("C"));

Note the double quotes ( " ) instead of single quotes ( ' ). If done correctly the "C" should be yellow in the editor to signify that a string is present.

\$\endgroup\$
  • \$\begingroup\$ This doesn't explain why the engine thinks there are 0 arguments instead of 1. Furthermore, ord is a function that takes in a character, not a string. \$\endgroup\$ – The Great Duck Dec 28 '18 at 7:26

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.