Xaine

Warper
Member
Joined
Oct 15, 2014
Messages
1
Reaction score
0
First Language
English
Primarily Uses
Okay, I'm pretty stumped right now and I just can't seem to get this working as I want. I'd like to say "hey I can just make a script for this" but unfortunately I don't really know the first thing about scripting. SOOOOO long story short I'm trying to make this work in the game as it is now.


I am currently working on DEF.
I created a state called "DEF UP" which is an invisible state (player doesn't see it) that does nothing on it's own. After the state is applied, I'm trying to make it so it adds to a variable. When this variable overflows, it should increase DEF value by 1 for that actor. In theory this should be pretty simple, but States cannot call common events nor control variables by default. Upon trying to create events on enemies themselves (troops) I've found that a "turn" in the game is only over after all characters on one side have attacked. Thus, this is making it so the variable is only increased AFTER all enemies have attacked, thus instead of going up by say, 6, it goes up by 1 even if you were hit by 6 enemies.

I've tried using common events, but unfortunately, they don't run automatically in battle. You can call a common event, but due to limitations in the troop settings, this doesn't really work as it only applies at the end of the turn, all the time or once per battle.

I also tried tying the state to the 'guard' skill (which is actually kinda cool because the character does a guard animation when hit) but unfortunately it still didn't remove the state after each enemy attacks - so it went up by 1 again.

Update:
I got it to work. For anyone who has trouble figuring this out here is the solution:
1. Create a State(s)
2. Add a state(s) to the desired skill(s)
3. Add a common event call to the desired skill(s)
4. Create a common event with a switch, with no trigger.
5. In the enemy troop, make the conditions for the event page tied to the switch turned on by the common event. Make the span "moment."
6. In the troop event page, create your event then at the bottom of the event have the switch turn off.


In my case
Conditions: #0000 Switch; Span: Moment
IF: Actor is affected by State
<> Change Parameter: Actor, Defense + 1
<> Change State: Actor, - State
: End
Control Switches : #0000 Switch = OFF

So each time an enemy uses a skill, it applies a state and calls the common event to turn on the switch, so the troop event will run and turn itself back off at any moment during a battle, instead of the limited conditions available.

This would have been something extremely simple to do if states could control switches, variables and parameters.
 
Last edited:

Latest Threads

Latest Profile Posts

edit: third time's the charm? some graphic text I whipped up that I like for the mid-game intertitle, now with all of the actual letters in the stupid damn words I was trying to spell :uswt2:
kcsmall.png
It is december, my dudes

badge_xmas.png
I love it when a plan comes together, and especially when Ruby decides to work with me when I decide to code. :kaopride:
Got sick and had to take a few days off work in order to get tested and make sure it wasn't the big one. Felt a lot better today and thought to myself, "Hey now, I can't get tested until tomorrow anyway, I can get so much character art done today!"
....I watched Youtube and browsed this site for hours instead.
>.>
But at least I'm doing the art now! Yaaaaay.......

Forum statistics

Threads
117,094
Messages
1,104,529
Members
153,100
Latest member
a1394649795
Top