Skip to content

Commit 77512e3

Browse files
Update GnomingTimeScript.cs
1 parent 186666b commit 77512e3

1 file changed

Lines changed: 12 additions & 0 deletions

File tree

Code/Examples/GnomingTimeScript.cs

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,22 @@ public class GnomingTimeScript : Example
1111
"""
1212
!-- OnEvent Death
1313
14+
# stop if its unknown who died
15+
# theoretically, this should never happen, but check just in case
16+
if {VarExists @evPlayer} is false
17+
stop
18+
end
19+
20+
# stop if death was not caused by a player
1421
if {VarExists @evAttacker} is false
1522
stop
1623
end
1724
25+
# stop if death was a suicide - meaning @evPlayer and @evAttacker are the same player
26+
if {Overlapping @evPlayer @evAttacker} is true
27+
stop
28+
end
29+
1830
@plr = @evAttacker
1931
2032
# lower size by .1 when killing someone

0 commit comments

Comments
 (0)