S
Ask yourself if you really need to use the physics engine on your game.I do not know what to do, I'm studying video lessons and forums on a game maker, and tried everything. My player does not turn where the mouse is looking !! Do not pay attention to sprites, this is not the main projectView attachment 14608View attachment 14609
You've already made something turn towards something. Now it's up to you to read the manual entry of point_direction and figure out why your code does what it does. Then, you will be able to adapt it to the new scenario without any further spoon-feeding input from the community and will actually have learned how to do something on your own!How to make the enemy look in the direction of my player?
phy_rotation = -point_direction(x, y, obj_player.x, obj_player.y);First things first, since I'm seeing screenshots of code: How to Q&A
You've already made something turn towards something. Now it's up to you to read the manual entry of point_direction and figure out why your code does what it does. Then, you will be able to adapt it to the new scenario without any further spoon-feeding input from the community and will actually have learned how to do something on your own!
Ya, I started the game I'm working on now with working in phy, but since then realized I don't need things shifting around, and that for a first game, maybe be better to hit up that phy later.phy_rotation = -point_direction(x, y, obj_player.x, obj_player.y);
It doesn't really, though. It seems easier because all you have to do is place a comment in the collision event to get a collision, but when you think about it, the traditional collision system is simpler. Firstly, the physics collisions can cause problems for the inexperienced because a physics collision event fires multiple times per step, depending on the physics update speed, and then only if a force is being exerted on the fixtures. Secondly, the way the physics system works 'under the hood' is far more complex than it seems. It checks to see if the fixtures are overlapping, and if they are, and the instances are supposed to collide, then it moves the fixtures out of collision.Then again collision is the biggest headache, and phy system fixes a lot of that.
@TsukaYuriko literally just said not to further spoonfeedphy_rotation = -point_direction(x, y, obj_player.x, obj_player.y);
image_angle = point_direction(x, y, mouse_x, mouse_y);
image_angle = point_direction(x, y, obj_Player.x, obj_Player.y);
I tried to find the video I got that from, but couldn't find it so.... also no other video that was really useful.@TsukaYuriko literally just said not to further spoonfeed