edited August 17 in General Discussion
Hi, I successfully followed the tutorial to get grid based combat setup. The move command is working thanks to Gil, and now this new frustration has popped up.

I got the attack command to use "AP". I've been trying to get the move command to use AP as well. And in addition, limit the move range of the combatant by the amount of AP he has. How would I go about achieving this?

I've been trying to implement it in events, however it's extremely hard to get status values to work properly in the events editor.

Regards.

Post edited by DanielKW on
  • The AP cost for using the move command are defined in the settings of the battle system you're using (e.g. Battle System > Turn Based Battles in the Action Settings).

    You can also define AP costs for grid cells like move costs. They're set up in the grid cell types alongside the regular move costs.
    If you're enjoying my products, free updates and support, please consider supporting me on patreon.com!
  • edited August 17
    Thanks @gamingislove I'll have a look at it.
    Post edited by DanielKW on
  • @gamingislove I can see the Grid Move Cost, I see there is only options for Value, Game Variables, Player Prefs etc.

    How do I get it to use Status Values as a value?
  • Hm, wait, are you talking about using the actions per turn feature (i.e. action costs), or AP as a status value that should be reduced?
    If you're enjoying my products, free updates and support, please consider supporting me on patreon.com!
  • @gamingislove, yes im using ap as a status value that fuels the actions/movement in my game.
  • edited August 17
    You can use status values in formulas used to calculate the move range or actions per turn of the combatant (calculated at the start of a combatant's turn), but you can't reduce the status value as move costs.

    At least not out of the box - you could reduce the status value in the battle event used for the grid move command, but this e.g. doesn't limit the move range when selecting a cell to move to.
    Post edited by gamingislove on
    If you're enjoying my products, free updates and support, please consider supporting me on patreon.com!
  • Thanks for the reply Gil, i noticed quite a few instances where status values could be used, but cant. At least directly, for example in battle events i cant effect status values. Its mainly global variables as proxies. I hope im explaining this right.
  • You can use status values in battle events.
    E.g.: the Check Status node can check the value of a status value (and a lot of other things), the Change Status Value node can change a status value, and you can use status values in formulas, which can be used by nearly all float value settings.

    What's your use case?
    If you're enjoying my products, free updates and support, please consider supporting me on patreon.com!
  • edited August 18
    Hi Gil, I live in a different timezone to the forum so I post at inopportune times.

    Anyway what I was trying to do is get the "cells" from check grid path length node and set the cell length to the amount of AP the player has, however there is no "compare status value to variable" node.

    I tried turning the status value into a variable, but it seems to not to do anything when I try it.

    EDIT: Hey Gil here is a screenshot of what I'm trying to do.

    image

    regards.
    Post edited by DanielKW on
  • Yeah ... what you're doing makes no sense :)
    E.g. the global variable cell (regardless of which type it is) doesn't influence the number of cells on the grid path.

    What you'd want to do is check and reduce the AP in the movement loop (i.e. where the event goes through each grid cell in the path and moves to it). E.g. after getting the next cell of the path, check the AP - if enough AP is left, reduce it (e.g. by 1) and continue with movement, otherwise break out of the movement loop and continue to the end of the event (i.e. do whatever happens after moving to the last cell).
    If you're enjoying my products, free updates and support, please consider supporting me on patreon.com!
  • Hey @gamingislove,

    I was basically following your actions per turn tutorial, and was hoping to have the move command have a use cost like abilities. I've been trying this way for days and can't seem to figure it. Is it possible to put a use cost for move?

    I understand a little programming but unfortunately I'm finding it hard following what you suggest.

    regards.
  • If you're following the actions per turn tutorial, you should already be using the actions per turn instead of a status value. This would allow you to set up the action cost of the grid move in the actions per turn settings of the battle system you're using.
    If you're enjoying my products, free updates and support, please consider supporting me on patreon.com!
  • @gamingislove so how can I represent the actions per turn as a value on the screen?
  • Like the other stats, i.e. with a Combatant HUD using an Actions Per Turn HUD element.
    If you're enjoying my products, free updates and support, please consider supporting me on patreon.com!
Sign In or Register to comment.