01-17-2013, 06:48 AM
Hi DerVVulfman! ^^ I was trying your script but I got an error... I'm using Atoa's Battle System but the error occurs in one of the basic scripts from XP:
'no implicit conversion from nil to integer' (Game_Enemy 125)
Game_Enemy:
#--------------------------------------------------------------------------
# * Get Element Revision Value
# element_id : Element ID
#--------------------------------------------------------------------------
def element_rate(element_id)
# Get a numerical value corresponding to element effectiveness
table = [0,200,150,100,50,0,-100]
result = table[$data_enemies[@enemy_id].element_ranks[element_id]] <--- 125
# If protected by state, this element is reduced by half
for i in @states
if $data_states[i].guard_element_set.include?(element_id)
result /= 2
end
end
# End Method
return result
end
Did I missed something? Thanks beforehand ^^
'no implicit conversion from nil to integer' (Game_Enemy 125)
Game_Enemy:
#--------------------------------------------------------------------------
# * Get Element Revision Value
# element_id : Element ID
#--------------------------------------------------------------------------
def element_rate(element_id)
# Get a numerical value corresponding to element effectiveness
table = [0,200,150,100,50,0,-100]
result = table[$data_enemies[@enemy_id].element_ranks[element_id]] <--- 125
# If protected by state, this element is reduced by half
for i in @states
if $data_states[i].guard_element_set.include?(element_id)
result /= 2
end
end
# End Method
return result
end
Did I missed something? Thanks beforehand ^^