NeverMind12
Member
So I followed a tutorial on how to make a parallax system in my game (GML), and it was going well until I tried to run my game and it wouldn't.
Here's the error:
Object: parallaxControl Event: Step at line 9 : got '[?' expected ')'
Here's the code:
var _cx = camera_get_view_x(view_camera[0]);
var _xspd = 3 * (keyboard_check(ord("D")) - keyboard_check(ord("A")));
_cx += _xspd
camera_set_view_pos(view_camera[0], _cx, 0);
var _b = ds_map_find_first(ForestOvershadow);
repeat(ds_map_size(ForestOvershadow))
{
layer_x(_b, ForestOvershadow[? _b] * _cx);
_b = ds_map_find_next(ForestOvershadow, _b);
}
Ripped straight from this tutorial https://www.yoyogames.com/blog/543/coffee-break-tutorials-parallax-scrolling but with minor changes such as A and D to move instead of arrow keys, and the name of the sprite being different. Gamemaker doesn't even display an error icon whatsoever, yet my game won't run. Any help available?
Here's the error:
Object: parallaxControl Event: Step at line 9 : got '[?' expected ')'
Here's the code:
var _cx = camera_get_view_x(view_camera[0]);
var _xspd = 3 * (keyboard_check(ord("D")) - keyboard_check(ord("A")));
_cx += _xspd
camera_set_view_pos(view_camera[0], _cx, 0);
var _b = ds_map_find_first(ForestOvershadow);
repeat(ds_map_size(ForestOvershadow))
{
layer_x(_b, ForestOvershadow[? _b] * _cx);
_b = ds_map_find_next(ForestOvershadow, _b);
}
Ripped straight from this tutorial https://www.yoyogames.com/blog/543/coffee-break-tutorials-parallax-scrolling but with minor changes such as A and D to move instead of arrow keys, and the name of the sprite being different. Gamemaker doesn't even display an error icon whatsoever, yet my game won't run. Any help available?