- Joined
- Apr 17, 2009
- Messages
- 3,572
Hey Guys,
I'm working on the Cutting ability for my survival map.
You can use your "Knife" item directly on the "Branch" item to sharpen it to a "Sharpened Stick".
This is the trigger:
It almost works, but setting the charges remaining is bugged somehow. If I use the knife on a branch item with more then one charge remaining, it just creates a single item, without this number for the charge.
Maybe it's because of my item stacking trigger:
Can anyone help me?
Greets chilla_killa
I'm working on the Cutting ability for my survival map.
You can use your "Knife" item directly on the "Branch" item to sharpen it to a "Sharpened Stick".
This is the trigger:
-
Cutting
-
Ereignisse
- Einheit - A unit Beginnt, eine Fähigkeit zu wirken
-
Bedingungen
- (Item-type of (Target item of ability being cast)) Gleich Branch
-
Aktionen
- Gegenstand - Remove (Target item of ability being cast)
- Held - Create Sharpened Stick and give it to (Triggering unit)
- Gegenstand - Set charges remaining in (Last created item) to (Charges remaining in (Target item of ability being cast))
- Spiel - Display to (All players) the text: |c00FFDE88You have ...
-
Ereignisse
It almost works, but setting the charges remaining is bugged somehow. If I use the knife on a branch item with more then one charge remaining, it just creates a single item, without this number for the charge.
Maybe it's because of my item stacking trigger:
-
Item Stacking
-
Ereignisse
- Einheit - A unit Erwirbt einen Gegenstand
-
Bedingungen
- (Item-class of (Item being manipulated)) Gleich Aufgeladen
-
Aktionen
-
For each (Integer A) from 1 to 6, do (Actions)
-
Schleifen - Aktionen
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
'IF'-Bedingungen
- (Item-type of (Item carried by (Triggering unit) in slot (Integer A))) Gleich (Item-type of (Item being manipulated))
- (Item carried by (Triggering unit) in slot (Integer A)) Ungleich (Item being manipulated)
-
'THEN'-Aktionen
- Gegenstand - Set charges remaining in (Item carried by (Triggering unit) in slot (Integer A)) to ((Charges remaining in (Item carried by (Triggering unit) in slot (Integer A))) + (Charges remaining in (Item being manipulated)))
- Gegenstand - Remove (Item being manipulated)
- 'ELSE'-Aktionen
-
'IF'-Bedingungen
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
Schleifen - Aktionen
-
For each (Integer A) from 1 to 6, do (Actions)
-
Ereignisse
Can anyone help me?
Greets chilla_killa