Hi is there a way to remove weapon, accessory armour from Inventory by using the numer taken from variable?
Im trying something like this but its not working ...
$game_party.gain_item($data_weapons[$game_variable<74>], -1)
$game_party::gain_item($data_weapons[$game_variables[1]], 1)
# or
$game_party::lose_item($data_weapons[$game_variables[1]], 1)
slot = 0item = $data_weapons[$game_variable[1]]$game_actors[1]::change_equip(slot, item)the slot determines which equipment slot to try put the equipment it - this of course needs to match the weapon/armor from the variable, so ou could do something like this instead...
item = $data_weapons[$game_variable[1]]slot = item::etype_id$game_actors[1]::change_equip(slot, item)That would automatically check the equipment type and put it in the correct slot. 🙂
Thanks! Yeah but Im getting the weapon ID of the character that was equiped to variable by this command
$game_actors[1].equips[0].id
so Im getting the ID of weapon and I just want to equip by the number it's not possible by any command ? when I got this ID stored in variable ? ?
(making custom EQ)
Ahhh, so you have a custom equipment system in place that is altering the id of the equipment item? So for example, you could have 2 weapon id 1 (database id), but their internal id's are (for example) 61 and 62??
If you are getting the id of the weapon already equipped, why do you need to equip it?
why not just, not unequip the weapon until they have confirmed that they want to drop it, then, unequip it and remove the item from inventory, otherwise do nothing. 🙂
For that script call you could do this..
a = $game_actors[1] id = a::equips[0]::id a::change_equip_by_id(0, id) 🙂
a = $game_actors[1]
id = a::equips[#game_varibale[74]]::id
a::change_equip_by_id(0, id)
where put here variable number XD?
What value does variable 74 hold? Didnt you say it was holding the value gained from '$game_actors[1].equips[0].id' ?
If it is, then its not required because you can get that same value from the second line in the snippet i posted above:
a = $game_actors[1] id = a::equips[0]::id # < same as $game_actors[1].equips[0].id a::change_equip_by_id(0, id)Which means there is no need for any variable. 🙂
Ok, I guess if you have your heart set on using the variable you could do this:
$game_actors[id]::change_equip_by_id(0, $game_variables[74])How is that? 😛