• Hey Guest! Ever feel like entering a Game Jam, but the time limit is always too much pressure? We get it... You lead a hectic life and dedicating 3 whole days to make a game just doesn't work for you! So, why not enter the GMC SLOW JAM? Take your time! Kick back and make your game over 4 months! Interested? Then just click here!

a.i

  1. D

    Enemy A.I and obstacle dodge

    I've been working on a top down game with a pretty simple A.I, something about the enemy going straight into the player in case it's state let's it do this action, then i've started to code the ranged enemies, wich should run from the player if it's to close to them, but there's a problem, i'm...
  2. C

    GML Final Fantasy Tactics - Enemies AI

    Hi there, Any good tutorial about how to implement this kind of AI on a tactics like game? I did some searches on Google, but couldn't find anything GM related.
  3. D

    I'm not sure if this is possible but could someone help

    So I'm trying to make my enemy open and shut my door object, so basically as the enemy walks through the door open and once is has walked through, the door closes. This is pretty easy to do but I have multi pal doors in my levels so I'm using instance_place to get the id of the door the enemy is...
  4. D

    How do I make an enemy return to a previously set path?

    I'm trying to get my enemy to return to there patrol path after being distracted by the player. The way I have it at the min is when it loses sight to the player it switches to a it's return state by using an object as it's target (I made a object so it could follow a mp_linear_path back to...
  5. D

    Don't really understand why this is happening, could someone help?

    So i'm trying to make an enemy return back to a set path after being distracted by the player. How I have it currently works in some places but not in others (which I don't get) For example if the enemy is distracted to the right side of the path they return fine but if they go off to the left...
  6. D

    (SOLVED)Is there a way to make an enemy hold the player's X and Y value after losing line of sight??

    So is there a way you could make an enemy remember the players last known position so that when the enemy loses it's line of sight it will move to the players last know position. I know how to get the players x and y i'm just not sure how I could make then enemy update the players position.
  7. D

    (SOLVED)How can you make an enemy only see you when its facing you?

    I have a line of sight script set up that works fine but the issue is my enemy's can see me even if I'm behind them, they just instantly turn round and face me. How could I make them only go into there alert state when facing me?
  8. D

    Could anyone help with this? it's driving me crazy

    So I have asked twice on here already but none of the answers has really helped at all. Is there a way to change if an objects solid or not and could someone please give me an example on how to, I have had people say yes you can with ___ but i'm not sure how to actually do it code wise so I need...
  9. D

    How could I change which objects are solid in my game with code?

    So I have a line of sight set up for my game but my enemies can see through my door object, I have all of my solid objects children of a solid parent. The problem with this is if I make the door solid no one can pass through it so is there a way I could switch whether it's solid or not?? I have...
  10. D

    Could someone help with this please??

    So iv made a line of sight for my enemy but the problem is I cant figure out a way to stop my enemy seeing through doors. If i make the door object a parent of my solid object I cant walk through the door but if it's not a solid the enemy can see you through it lol any idea of hot this could be...
  11. D

    (SOLVED)How can I make an object face the right direction when on a path?

    Literally been trying to do this for like 3 weeks now lol I just moved on with other parts of my game haha I really need to do this now though, I have tried everything I could think of, I have tried using xprevious, image_scale, path_speed. I dunno what else to try, could someone please help me out.
  12. D

    Is there a function that checks the current path an object is on?

    My enemy finds where it started and moves back by making a path but when it reaches it's start position, I need it to change it's path back to its patrol state. I was trying to find a way to check the current path it's on so I can end it and move it to the patrol path but can't find a function...
  13. D

    (SOLVED)Could someone help with this please??

    So in my game u can take control of an enemy but once the player leaves the enemy I want the enemy to find it's way back to it's patrol path. I have looked into it online and found out about motion planning and setting up grids it's just i'm not sure how to 100% do it. I thought a good way...
  14. D

    Is there away to do this? or do paths not work like that?

    So i'm trying to set up a patrol for one of my enemies, where it stops when it reaches the end of the path pauses (I'll probs use an alarm for that) and the goes back up the same path again. So basically is there away to stop at a point on the path and go back up it? or like after stopping...
  15. D

    Anyway I can flip a sprite when my object is following a path?

    I wanna use a path for my enemies patrol but I didn't think about how I could flip the sprite lol usually i use if(hspd != 0) image_xscale = sign(hspd) but how can u check the direction when it's moving on a single path?
  16. D

    (Solved) I don't get what's going on with my collision code??

    As far as I can see my code's right (obviously there is an issue tho) it's probably something obvious but I'm like taring my hair out right now XD. The issue is when I try and move the object doesn't it's like it's not reading the x+= hspd part when I have the collision code wrote in. Could...
  17. D

    (SOLVED)Anyone have any idea how the hell this is happening???

    So in the game i'm making the player can take control of an enemy and walk around as the enemy it has took control of but I'm having this really weird bug where my enemy is running it's wander_state as it's running the controlled state, like how the hell is that even possible?? you take control...
  18. D

    What would be the best way to set up a behavior tree in game maker?

    In a game i'm working on i'm making the AI kind of like the AI you see in games like Party Hard or Hitman where the AI will walk around can get scared, will interact with objects etc. I'm just wondering what the best way to go about this would be, would enums be a good way? Or would a FSM...
  19. D

    (SOLVED) How can I make an enemy randomly choose a direction?

    I'm trying to make the enemy choose a random direction each time it runs it's state but when the enemy runs it's idle and goes back to wandering it just carries on in the same direction, ever single time. Wander_state ///wander_state() if(alarm[IDLE] == -1){ alarm[IDLE] =...
  20. D

    How can I make an enemy wonder just on the xaxis?

    I'm trying to make an enemy that wanders randomly in either the right or left directions, how could I go about this? I have been trying with irandom_range but i'm not sure how I can specify a direction? I'm trying to make the enemy wonder then switch states (I have that part done, i'm just not...
Top