Can I put the value of the equipment variable in the description??
In the description of the equipment
"Deal xxx damage per second."
I want to put the equip variable "damage" key in xxx.

xxx should changes at every equip level up
However, I can't find the appropriate text code.
  • You can add variable text codes via the More button above the text editor and selecting Data and Game Variables.

    E.g. #varifloatdamage# would display the float variable damage as an integer value.

    To use equipment variables in the description, enable Use In Description in the equipment's Equipment Variables settings.
    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!
  • edited January 2021

    string des = ORK.Game.ActiveGroup.Leader.Abilities.Get (id).GetDescription ();
    TextHelper.ReplaceSpecials (ref des);
    detail_Description.text = des;


    I am trying to display float variable 0.7 using #varfloatdeal#. in ability Description (use in Description Checked)
    However, when outputting with the code above, it is output as a value of 1.
    It seems to be rounding.
    0.2 => 1

    How do I print it to 0.7?
    I used varFloat, not variFloat, but it seems to round off.
    Post edited by KESHYAS on
  • Strange, usually the rounding would only occur at lower decimal places.

    Try using the Float with Format text code, e.g.: #varcfloatdeal#0.0#
    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!
  • #varcfloatdeal#0.0# works thanks!
    it is displayed 0.4> 0.4
    (previous #varfloatdeal# 0.4> 0)
  • Ah, forgot about the number formatting settings (Menus > Text Display Settings) which where introduced in ORK 2.30.0 and default to float variables being displayed without decimal.
    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.