grrrvahrrr
Member
Hi! I have more of a general question.
In a platformer game I want to create an enemy that aggros and follows the player jumping after him from platform to platform. Where do i start with it? Are there any good guides for GML to code simple AI logic? How do you approach such problems in general?Are there eny tips for beginners who do it in GMS or a must-read of some kind?
So in my mind, what i need is to make my enemy object analyse that it is at the end of a platform then judging by point_direction it needs to decide if it needs to jump or to drop... but how far to jump? Is it another collision detection?
It seems that the easiest way to do it is to make a net of place_meetings and if statements, but i am worried that if i do that and several objects on the screen would be constantly checking for collision it would have a huge impact on performance.
Where do i start with programming simplistic AI?
What if i am overthinking it and maybe i can just fake AI with just making objects move along platforms following player and when they are not touching a platform their sprite changes to a jumping sprite and back to running one when they "land".
I know that there is a path creation functionality that i haven't used. Is is a good way to programm such behaviour? like adding points around objects with path_add_point or something?
Sorry for a rant)
In a platformer game I want to create an enemy that aggros and follows the player jumping after him from platform to platform. Where do i start with it? Are there any good guides for GML to code simple AI logic? How do you approach such problems in general?Are there eny tips for beginners who do it in GMS or a must-read of some kind?
So in my mind, what i need is to make my enemy object analyse that it is at the end of a platform then judging by point_direction it needs to decide if it needs to jump or to drop... but how far to jump? Is it another collision detection?
It seems that the easiest way to do it is to make a net of place_meetings and if statements, but i am worried that if i do that and several objects on the screen would be constantly checking for collision it would have a huge impact on performance.
Where do i start with programming simplistic AI?
What if i am overthinking it and maybe i can just fake AI with just making objects move along platforms following player and when they are not touching a platform their sprite changes to a jumping sprite and back to running one when they "land".
I know that there is a path creation functionality that i haven't used. Is is a good way to programm such behaviour? like adding points around objects with path_add_point or something?
Sorry for a rant)