Checking Value/Condition Constantly

  • #1, z eric-w-Sunday, 16. June, 15:35 hodinky 3 months ago
    Hello there. 
    I want to show the player´s amount of money constantly. Lets say you start with 20Gold and it is shown in the corner "20Gold". Whenever the player buys something, 1 Item for 1Gold for example, after the purchase I want to see "19Gold" in the corner without hovering over an object area. It should change instant.
    Is that possible? 
    And if possible, without Lua?
    Thanks in advance ^^

    Bažant

    16 Posts


  • #2, z esmeraldaMonday, 17. June, 09:28 hodinky 3 months ago
    This is how I would do it:
    create an interface with a transparent background, at least as big as the text you want to display, place it in the corner of the screen.
    On this interface create a button. (no image needed)
    For this button you can now display an object text (action part, found under "miscellaneous").
    In this text you can display the integer of your gold value.
    Exapmple:   "Gold: <v=name_of_value>"

    This object text stays the same, even when you update the value. To update the text you need to execute the action part (display object text) again each time you change the gold value.


    Zabiják klíčů

    525 Posts

  • #3, z eric-w-Monday, 17. June, 16:46 hodinky 3 months ago
    This is how I would do it:
    create an interface with a transparent background, at least as big as the text you want to display, place it in the corner of the screen.
    On this interface create a button. (no image needed)
    For this button you can now display an object text (action part, found under "miscellaneous").
    In this text you can display the integer of your gold value.
    Exapmple:   "Gold: <v=name_of_value>"

    This object text stays the same, even when you update the value. To update the text you need to execute the action part (display object text) again each time you change the gold value.


    </v=name_of_value></div>
    Okay, thank you very much. Gonna try it ^^

Bažant

16 Posts

Napsat příspěvek