Posts: 77
Threads: 12
Joined: Sep 2009
hello,
i dont mean to post on old subject but well... the link is broken... could you please fix that ? o.o
thanks !
Fighting for peace is like screwing for virginity.
Posts: 11,271
Threads: 651
Joined: May 2009
Glad you did actually. I have the script somewhere at home. Unfortunately, I am at work so I cannot get to re-upload for another 6 hours.
Link fixed. The url ended with .zipj. There is no J in .zip.
Posts: 2
Threads: 0
Joined: Apr 2013
I apologize for the necropost, but I have a small question about this script that I'd feel silly making a new topic for, and I can't seem to PM anybody.
Basically, I was wondering if there was a way to edit this code, so that after a state nulls/absorbs/doubles damage from a given element, the state goes away immediately.
Yes, I know I could just make it so the state only lasts a single turn, but just ending the state quickly is not what I'm trying to do. I want a given state to last indefinitely, but get removed immediately if it activates this scripts functions a single time.
Is this possible?
Posts: 422
Threads: 23
Joined: Aug 2011
Sure is! Here is an example of how to do it;
Code:
# Halve damage if element is protected
if $data_states[i].guard_element_set.include?(element_id)
result /= 2
remove_state(i)
end
Just add remove_state(i) inside the if statements. This will remove the state whenever its effect activates.
Posts: 2
Threads: 0
Joined: Apr 2013
(04-24-2013, 08:16 PM)MechanicalPen Wrote: Sure is! Here is an example of how to do it;
Code:
# Halve damage if element is protected if $data_states[i].guard_element_set.include?(element_id) result /= 2 remove_state(i) end
Just add remove_state(i) inside the if statements. This will remove the state whenever its effect activates.
Excellent! Thank you, that works like a charm!