[RMVX] Triggering death outside battle via RADS!

Discussion in 'RGSSx Script Support' started by Marm, Nov 9, 2016.

    Tags:
  1. Marm

    Marm Villager Member

    Messages:
    6
    Likes Received:
    2
    First Language:
    English
    Hi, sorry if this is the wrong place to ask!


    I wanted to have a new type of "HP" called "Rads". (Think Fallout, if you've played the series). Basically, if the character interacts (outside battle) with something like irradiated water, they get +5HP and +7 Rads. 


    Once Rads hits 100/100, I want the character to die, inside or outside of battle. I'm not sure how to do that. Could someone give me a hand? =)


    I've been using MP as my 'Rads' and have set initial MP/Rads to 0.


    Also, if MP/Rads hits 70 outside battle, how can I have a textbox pop up warning the player?


    Thank you so much!
     
    #1
  2. johanes

    johanes Hobo Veteran

    Messages:
    97
    Likes Received:
    9
    First Language:
    Filipino
    Primarily Uses:
    N/A
    scene command -#3 -scene control -gameover
     
    #2
  3. Shaz

    Shaz Veteran Veteran

    Messages:
    37,800
    Likes Received:
    11,507
    Location:
    Australia
    First Language:
    English
    Primarily Uses:
    RMMV
    Since the character has to interact with something in order to adjust this figure, you know exactly at what points it needs to check how high the value is.  So when you increase the rads, just do a conditional branch for each character to see if they have 100 and kill them, and if they don't have 100 but have > 70, show the warning.  You'll have to make it a bit more complicated than that, if you only want one warning for the whole team (not one for each person who has crossed 70), as well as to stop the warning showing every time (if they hit 70, show the warning, if they interact with something else and hit 75, do you want to warn them again? If not, you'll need to track what they WERE or use a formula in the Conditional Branch to see if they were under and are now over)
     
    #3
  4. deilin

    deilin Ranger/Elementalist Veteran

    Messages:
    1,189
    Likes Received:
    173
    First Language:
    English
    @ShazIn that case, you can have switches for various points. $game_switches[20] is 70%, 21 for 80, and so on. once 70 is hit, it turns on that switch and  that warning, but bypasses that warning until rads < 70, which turns off that switch. As far as in battle, you will have to battle event the warning in every troop, since the game_interpreter wont kick in until the battle ends. If good with scripting, you can trigger some cases, like stat changes, in the on_turn_end command in the scripts.
     
    #4
  5. Marm

    Marm Villager Member

    Messages:
    6
    Likes Received:
    2
    First Language:
    English
    Everyone, thank you for your replies! I've figured out what I want to do, and I've also implemented an Item that gets rid of Rads. [Radaway]


    I have another question though - I'd like the player's ATK to drop -15 once they hit the ~70Rads threshold.


    How can I restore ATK after they consume the Radaway? 


    Or rather, how can I trigger ATK to be restored once they get <70 Rads?
     
    Last edited by a moderator: Nov 10, 2016
    #5

Share This Page