Hello Again.
I have a little problem with this code, so. can someone helpme?.
What I was trying?
I wash trying to check, if the clothes names, that are included in the array. are included in the Character Name.
Example..
If the character name of the actor is:
001-Meph_Shadow.png
The window prints: the actual name, it's say... Shadow but I can't get the name of each index of the array. exist a code for that? like to_i, to_s....
Or in a ruby form.
Thats all.
Thanks.
I have a little problem with this code, so. can someone helpme?.
Code:
clothes = ['Shadow','Combate', 'Guardia', 'Marino', 'Prisionero', 'Campesino']
for i in 0..clothes.size
if @actor.character_name.include?('_' + i)
self.contents.draw_icon_text(80, 10, 150, 32, clothes[i])
end
What I was trying?
I wash trying to check, if the clothes names, that are included in the array. are included in the Character Name.
Example..
If the character name of the actor is:
001-Meph_Shadow.png
The window prints: the actual name, it's say... Shadow but I can't get the name of each index of the array. exist a code for that? like to_i, to_s....
Or in a ruby form.
Code:
if @actor.character_name.include?('shadow')
self.contents.draw_icon_text(80, 10, 150, 32, 'Shadow')
elsif @actor.character_name.include?('Campesino')
self.contents.draw_icon_text(80, 10, 150, 32, 'Campesino')
elsif
etc...
etc...
Thats all.
Thanks.