How do I display the damage done by each combatant in the HUD or something?
  • Is total battle damage shown, I found battle statistics in the battle system, but don't know how to use them in the HUD
  • Battle statistics are mainly used in battle AI and not available for display in HUDs.
    The ORK HUD Status Text Content component displaying Status Value information has some text codes to show the last changes or combined last changes done to a status value, but that'd be the damage done to a combatant, not done by a combatant.

    One way would be to use Change Schematics on your health status value. They have the attacker available as Machine Object of the schematic and the change value as local int and float variable change - so you could use that to change an object variable on the attacker and get the total damage that way.
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • This works, but how do I display the variables?
  • I used the character's attributes and calculated this attribute value through the formula, but there is a problem that this attribute value is not updated in real time during the battle, is there a better way?
  • churan said: This works, but how do I display the variables?
    As text, either as an HUD Text Content or ORK HUD Text Content components (e.g. added via the scene hierarchy context menu as usual). You can use variable text codes to display the values of variables, and the component has an option to define which variable origin to use (e.g. Object origin using the User of the HUD).
    The buttons above the text area will have all available text codes to select and add when you click on the More button.
    churan said: I used the character's attributes and calculated this attribute value through the formula, but there is a problem that this attribute value is not updated in real time during the battle, is there a better way?
    Can you give me some details on what you calculate and for what? E.g. is this a status value that's calculated by a formula and setting it's value (e.g. via the Combined Value options of the status value), or is this storing some result in a formula?
    Also, when is this done?
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • I wanted to add some functionality to combat in my turn-based game,

    I now have a problem, I give my game battle in front of two rows, how do I get which row is the front row, and which row is the back row?
  • ORK doesn't really have a front/back row system - so how did you set that up?
    E.g. is this based on the battle group positions (like first 2 combatants are front row)?
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • I solved the problem of front row and back row, I used the battle position, equal to a certain coordinate on the X-axis, got a variable on the combatant in that position, and set it to front row and the rest to back row
  • An alternative to variables would be using status effects to mark a combatant as front or back row. Makes it also a bit easier for conditional checks, e.g. just checking status condition for one of those effects being applied.
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • I wanted to have a passive skill, like every time the player loses 10% of their health, the player gains a status.

    How to define health per loss and then gain this status
  • You could use status effects using Auto Apply Settings. They can check for status conditions, e.g. the ability being known and HP being below 90%. You'd need to set up one of those for each 10% barrier, i.e. 90, 80, 70, etc.
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • Is there a convenient way, I would like to set it up so that every time the player loses 1% health, they get a status effect
  • Probably best to handle that using a Change Schematic in the status value's settings. It's used whenever a status change happens and has the change value and other information available (see the help text of the settings). They can also be limited to e.g. only negative changes and use other conditions (e.g. only use when an ability is known).

    You'd just need to check if the change value (available as a local variable) is greater than 1% of max health, which can be done with the Check Value node - it can directly use the combatant's status value and also use a multiply math function to check for 1% (i.e. multiply by 0.01).
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
Sign In or Register to comment.