Centra's Forum Posts

  • bump.

  • Hello everyone,

    I am working with this finite state machine behavior/addon and I'd like my npcs to run from a stack using regex because eventually i would like to have more complicated behaviors however I seem to be missing something fundamental about how Construct 3 runs where it's not finding the associated stack of the npc from runtime.

    cp3 with bundled addon - https://drive.google.com/file/d/1bKhVN0xho75j8SJLFxqDnkgvBaDH9gVT/view?usp=sharing

    addons FSM- https://www.construct.net/en/make-games/addons/441/finite-state-machine

    My goal is to use a Goal Oriented Action Planner approach where the state machine has only 3 states idle, move, and action. I'm hoping that eventually I'll be able to use the stack to read more specific actions later.

    Suggestions, comments, help all welcome.

    Tagged:

  • Set up a layout as an object repository, and then have them work on individual event sheets and include/remove them from the main event sheet as needed to avoid conflict, or use groups and activate/deactivate as needed.

  • Thank you!

    I can't seem to drill down into the arrays for preconditions for example. Is it necessary to use for loops to get there?

    The manual says for arrays to use the index but it's an array of key value pairs so I got confused.

    I also saw in the manual that you can set Paths but it's not clear to me how that works though I think it's relevant in this case

  • Hello. I'm having trouble getting at the inner areas such as preconditions and effects, could someone enlighten me?

  • this spawns a sprite on a specific tile type, maybe it's useful for you

  • Hey, I worked on one in Construct 2

    I gave each agent a stack and used regex to extract info and call functions and handle the actions via the state machine but struggled with actually creating the 'planner' part. Though it should be easier now that scripting is part of C3. If you'd like we can compare notes.

  • I've added to your example to make it reflect my project a little better, maybe it will shed some light on where I went wrong.

    It doesn't quite mirror correctly or set the idle animation every time

    dropbox.com/s/9d9qiwndruaeb8f/moveto_fams.c3p

    (though I'd still like to know what went wrong here ^ )

    Edit:

    Looks like the new update added hierarchies which does what I wanted with the picking

    This version solves the issue though for anyone curious.

    dropbox.com/s/cn4gs9a01g0te2n/moveto_hierachy.c3p

    or

    dropbox.com/s/8v1cnb8sij8hpye/movetohierachies_fam2.c3p

  • Expected Result: (multiple followers) The follower's animations should play idle when stopped (not moving) and play 'run' while moving. They should also mirror animations to face the appropriate direction.

    Result: First follower to arrive plays idle animation, however the second follower to arrive is stuck playing run animation. Construct has not detected them as stopped (tested with an instance variable.

    Additional info. Working with Moveto and Rexmoveto (plus easystar) but I'm specifically asking about the default Moveto behavior for now.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Hey!

    I've tried to PM you Gigatron but I think the forums changed and they removed PMs. If you see this at any point in the future, I want you to know that I'm super impressed by all of the effects that I've seen by you I'd like to ask if you could post a zip somewhere with them

  • rexrainbow

    I'm not sure if I haven't understood the way the behavior works or if a bug, but if an object has 2 FSM behaviors, and when "State Transfer Logic" is triggered, it gets triggered for both the FSM behaviors.

    For example, a sprite has FSM1 and FSM2 behavior.

    On FSM Tranfer logic > Add 1 to Variable.

    On FSM2 Transfer logic > Add 1 to Variable.

    On Start of Layout > FSM2 Request.

    This results in Variable = 2.

    Or just add 1 to Variable on FSM Transfer logic, and it triggers on FSM2 request.

    I don't understand if this is how it is supposed to happen or a bug.

    BUMP,

    also running into issues with the On State transfer logic, to the point where I feel like it's more of a bug then my own fault. When is a For Each appropriate?

  • Is it possible to use this plugin along with the associated (instgroup and graph movement) to create a 'non physical' graph? By this I mean the graph I would like to create and navigate is abstract, and not made with sprites consisting of vertices and edges on the layout itself.

    For example:

    I have two situations where I would like to create graphs and find the shortest path,

    The first is to find a path using elevators which move between floors, so each elevator car essentially covers several vertices,(i've accomplished this through other means but now i'd prefer to build a graph of elevator cars, which each contain their own range of floors, and find the shortest path using that data instead of sprite vertices

    The second case is further abstracted from sprites on the layout, I would like to use this plugin to find a path from a list of actions with different costs in a Goal Oriented Action Planner system, to generate a 'plan' of actions which are accessed via an NPC's stack. https://gamedevelopment.tutsplus.com/tutorials/goal-oriented-action-planning-for-a-smarter-ai--cms-20793

    So my question is, can I build a graph using these plugins without having to actually make the path on a layout using vertices and edges, and if so, how?

  • Thank you so much!

  • I'd like to accomplish the same effect but I don't think the wait action is the best way, how can I do this more effectively?

    https://www.dropbox.com/s/01rmzw3unt09ku6/mousescroll.capx?dl=0

  • I'm looking for a better solution for a menu which scrolls by using the mouse wheel. Below is a capx which uses wait, but I don't think that's best practice.

    Capxhttp://www.filedropper.com/mousescroll