Alright, so I want to make a simple inventory system. There are 6 slots in hero inventory. I planned to make slot 1,2 for various items like amulets rings etc, slot 3 for right hand items, slot 4 for helmet, slot 5 for left hand items and slot 6 for armor.
First trigger I made is something like this:
So what I am tryin' to do now is to find an event "Hero moves an item in the inventory" or somehow manage to prevent the player from moving item between slots. Any ideas?
First trigger I made is something like this:
-
PickUP Armor
-
Wydarzenia
- Unit - A unit Aquires an item
-
Conditions
-
Or - Any (Conditions) are true
-
Conditions
- (Item-type of (Item being manipulated)) Equals Dummy Armor Item
- (Item-type of (Item being manipulated)) Equals Dummy Armor Item 2
-
Conditions
-
Or - Any (Conditions) are true
-
Actions
- Set Temp_Position = (Position of (Item being manipulated))
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
Or - Any (Conditions) are true
-
Conditions
- (Item-type of (Item carried by (Hero manipulating item) in slot 4)) Equals Dummy Armor Item
- (Item-type of (Item carried by (Hero manipulating item) in slot 4)) Equals Dummy Armor Item 2
-
Conditions
-
Or - Any (Conditions) are true
-
Then - Actions
- Hero - Drop (Item being manipulated) from (Hero manipulating item)
- Item - Move (Last dropped item) to Temp_Position
- Game - Display to (Player group((Owner of (Hero manipulating item)))) for 1.50 seconds the text: Hero already has an armor.
-
Else - Actions
- Unit - Order (Hero manipulating item) to move (Item being manipulated) to inventory slot 4
-
If - Conditions
-
Wydarzenia
So what I am tryin' to do now is to find an event "Hero moves an item in the inventory" or somehow manage to prevent the player from moving item between slots. Any ideas?