- Joined
- Feb 17, 2010
- Messages
- 6
I postet it under another Topic, but then i saw that it belongs here...
this is my script that causes the crash. a screenshot of the crash is attached below. the intention of this script is to check if an ability was cast of the kind "Flee". in my map combats are fought on battlefields and when you flee from battle half of ur units should die and the rest can be seen from script. the error tells something about "could not read memory"
any ideas?

this is my script that causes the crash. a screenshot of the crash is attached below. the intention of this script is to check if an ability was cast of the kind "Flee". in my map combats are fought on battlefields and when you flee from battle half of ur units should die and the rest can be seen from script. the error tells something about "could not read memory"
-
flee
-
Ereignisse
-
Einheit - A unit Beginnt, eine Fähigkeit zu wirken
-
-
Bedingungen
-
(Ability being cast) Gleich Flee!
-
-
Aktionen
-
For each (Integer A) from 1 to 3, do (Actions)
-
Schleifen - Aktionen
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
'IF'-Bedingungen
-
Or - Any (Conditions) are true
-
Bedingungen
-
(Owner of (Triggering unit)) Gleich (Player(battlefield_attacker[(Integer A)]))
-
(Owner of (Triggering unit)) Gleich (Player(battlefield_victim[(Integer A)]))
-
-
-
-
'THEN'-Aktionen
-
Spezialeffekt - Destroy player_heroes_effects[battlefield_attacker[(Integer A)]]
-
Spezialeffekt - Destroy player_heroes_effects[battlefield_victim[(Integer A)]]
-
Einheit - Change ownership of player_heroes[battlefield_attacker[(Integer A)]] to (Player(battlefield_attacker[(Integer A)])) and Farbe wechseln
-
Einheit - Change ownership of player_heroes[battlefield_victim[(Integer A)]] to (Player(battlefield_victim[(Integer A)])) and Farbe wechseln
-
Einheit - Make player_heroes[battlefield_attacker[(Integer A)]] Verwundbar
-
Einheit - Make player_heroes[battlefield_victim[(Integer A)]] Verwundbar
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
'IF'-Bedingungen
-
(Owner of (Triggering unit)) Gleich (Player(battlefield_attacker[(Integer A)]))
-
-
'THEN'-Aktionen
-
Set battlefield_winner[(Integer A)] = battlefield_victim[(Integer A)]
-
Spiel - Display to (All players) the text: (((player_txtcolor[battlefield_attacker[(Integer A)]] + (Name of (Player(battlefield_attacker[(Integer A)])))) + |r ) + fled from combat)
-
Einheitengruppe - Pick every unit in (Units in battlefield_regions[(Integer A)] owned by (Player(battlefield_winner[(Integer A)]))) and do (Actions)
-
Schleifen - Aktionen
-
Einheit - Move (Picked unit) instantly to (Center of player_regions[battlefield_winner[(Integer A)]])
-
Einheit - Order (Picked unit) to Position halten
-
-
-
Set x = (Number of units in (Units in battlefield_regions[(Integer A)] owned by (Owner of (Triggering unit))))
-
Einheitengruppe - Pick every unit in (Random (x / 2) units from (Units in battlefield_regions[(Integer A)] owned by (Owner of (Triggering unit)))) and do (Einheit - Kill (Picked unit))
-
Einheitengruppe - Pick every unit in (Units in battlefield_regions[(Integer A)] owned by (Owner of (Triggering unit))) and do (Actions)
-
Schleifen - Aktionen
-
Einheit - Move (Picked unit) instantly to (Center of player_regions[(Player number of (Owner of (Triggering unit)))])
-
Einheit - Order (Picked unit) to Position halten
-
-
-
Einheit - Move player_heroes[(Player number of (Owner of (Triggering unit)))] instantly to (Position of (Random unit from (Units owned by (Owner of (Triggering unit)) of type Castle)))
-
-
'ELSE'-Aktionen
-
Set battlefield_winner[(Integer A)] = battlefield_attacker[(Integer A)]
-
Spiel - Display to (All players) the text: (((player_txtcolor[battlefield_victim[(Integer A)]] + (Name of (Player(battlefield_victim[(Integer A)])))) + |r ) + fled from combat)
-
Einheitengruppe - Pick every unit in (Units in battlefield_regions[(Integer A)] owned by (Player(battlefield_winner[(Integer A)]))) and do (Actions)
-
Schleifen - Aktionen
-
Einheit - Move (Picked unit) instantly to (Center of player_regions[battlefield_winner[(Integer A)]])
-
Einheit - Order (Picked unit) to Position halten
-
-
-
Set x = (Number of units in (Units in battlefield_regions[(Integer A)] owned by (Owner of (Triggering unit))))
-
Einheitengruppe - Pick every unit in (Random (x / 2) units from (Units in battlefield_regions[(Integer A)] owned by (Owner of (Triggering unit)))) and do (Einheit - Kill (Picked unit))
-
Einheitengruppe - Pick every unit in (Units in battlefield_regions[(Integer A)] owned by (Owner of (Triggering unit))) and do (Actions)
-
Schleifen - Aktionen
-
Einheit - Move (Picked unit) instantly to (Center of player_regions[(Player number of (Owner of (Triggering unit)))])
-
Einheit - Order (Picked unit) to Position halten
-
-
-
Einheit - Move player_heroes[(Player number of (Owner of (Triggering unit)))] instantly to (Position of (Random unit from (Units owned by (Owner of (Triggering unit)) of type Castle)))
-
-
-
Kamera - Pan camera for (Player(battlefield_attacker[(Integer A)])) to (Position of player_heroes[(Player number of (Player(battlefield_attacker[(Integer A)])))]) over 0.00 seconds
-
Kamera - Pan camera for (Player(battlefield_victim[(Integer A)])) to (Position of player_heroes[(Player number of (Player(battlefield_victim[(Integer A)])))]) over 0.00 seconds
-
Set battlefield_use[(Integer A)] = False
-
Set battlefield_attacker[(Integer A)] = 0
-
Set battlefield_victim[(Integer A)] = 0
-
Set battlefield_winner[(Integer A)] = 0
-
-
'ELSE'-Aktionen
-
-
-
-
-
