I have in my game a weapons store and a player inventory like this:
Weapons Store:
Weapon image (sprite)
" "
" "
" "
and etc.
Player Inventory:
Empty cell (sprite)
" "
" "
" "
and etc.
Purchase Button (sprite)
When the player chooses one of the weapons in the weapons store, then another sprite object
appears on top of the weapon's raw for showing the chosen object (an empty rectangle sprite object).
When the player clicks the "Purchase" button, I would like the chosen weapon sprite object to appear
in the parallel player inventory's empty cell.
Is there any way to refer to the weapon's sprite object through the location of the focus on the chosen weapon to purchase ?
The only way I see right now is by using the following event (long and cumbersome):
Event: WeaponFocus (sprite image name) y = 200 Action: WeaponName (sprite) Set position to Cell1 (sprite image name)
Event: WeaponFocus (sprite image name) y = 230 Action: WeaponName (sprite) Set position to Cell2 (sprite image name)
Event: WeaponFocus (sprite image name) y = 260 Action: WeaponName (sprite) Set position to Cell3 (sprite image name)
" "
" "
" "
and etc.
So if I have for example 40 raws of weapons in the store would I have to add 40 event lines instead of referring to
the weapon sprite image name automatically by a single type of event ?