I don't see why the error came up but I looked over the code more.
Code:
bullet.direction = move_towards_point(objHoofdPersoon.x, objHoofdPersoon.y,5);
this line that you had makes no sense.
direction is a variable that expects an angle (what angle to move at)
move_towards_point is a function that does 2 things:
1) sets your direction.
2) sets your speed.
it does
NOT return a direction
I tested the code with no errors.
create event is still as i said.
alarm event should be:
Code:
alarm[10] = 5 * room_speed;
var bullet = instance_create(x, y, objKogel);
bullet.direction = point_direction(bullet.x, bullet.y, mouse_x, mouse_y);
bullet.image_angle = bullet.direction;
bullet.speed = 15;
this will make the bullets go towards the mouse and be created at the current x and y but it should work.
Do not have any other code in this object or the bullet object.
Make sure this works then reintroduce making your plane move.
If you get the same error copy the exact error (what you showed me wasn't the full error) and the code how you copied it