Attack that adds state on user instead of the enemy

Discussion in 'RPG Maker VX Ace' started by dank, Jun 14, 2016.

  1. dank

    dank Villager Member

    Messages:
    7
    Likes Received:
    0
    First Language:
    English
    So i wanted to do a attack that adds a state to the user instead of the target i looked it up and found out the way to do it is with a.add_state(stateid);attack formula


    however when i do it it doesn't work instead the damage becomes null and the user doesn't get the state on them, i'd assume i did something wrong?


    the way i did it is like this:


    a.add_state009; a.atk * 4 - b.def * 2
     
    #1
  2. stupid enough to like FF13

    stupid enough to like FF13 Veteran Veteran

    Messages:
    587
    Likes Received:
    316
    First Language:
    English
    You need the parenthesis around the number of the state, and don't need the zeroes. So you would use, for example:

    Code:
    a.add_state(9); a.atk * 4 - b.def * 2
     
    #2
  3. bgillisp

    bgillisp Global Moderators Global Mod

    Messages:
    12,298
    Likes Received:
    12,512
    Location:
    USA
    First Language:
    English
    Primarily Uses:
    RMVXA
    Where's your ()? It should go:


    a.addstate(9); your damage formula here.
     
    #3
  4. dank

    dank Villager Member

    Messages:
    7
    Likes Received:
    0
    First Language:
    English
    oh whoops, didnt think they meant to actually use the () in that post my bad, can close this now
     
    #4

Share This Page