Date: 2016/10/12 11:00:57 UTC-07:00
Type: Denizen Script
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
QuickSandScript:
# This script controls the quicksand feature within the Wasteland continent.
type: world
debug: true
events:
on entity stops gliding:
- if <player.location.tc_biome.name> == TemperateWasteQuickSand {
- if <player.has_flag[NoStopGliding]> {
- determine CANCELLED
}
}
on player jumps:
- if <player.location.distance[<player.flag[freeze_location]>].is[MORE].than[1]> {
- teleport <def[1]> <player.flag[freeze_location]>
}
on system time minutely:
- foreach <server.list_online_players> {
- if <%value%.location.tc_biome.name> == TemperateWasteQuickSand {
- run QuickSandGlide def:%value%
}
}
on player stops sneaking:
- if <player.location.tc_biome.name> == TemperateWasteQuickSand {
- if <player.has_flag[NoStopGliding]> {
- flag <player> NoStopGliding:!
- cast <player> jump remove
}
}
QuickSandGlide:
type: task
debug: false
script:
- if <util.random.int[1].to[1]> == 1 {
- narrate "The ground below your feet started sinking away." target:<def[1]>
- flag <def[1]> NoStopGliding
- flag <def[1]> quicksand_location:<def[1].location>
- adjust <def[1]> gliding:true
- cast <def[1]> jump p:400
}