Skip to content

Instantly share code, notes, and snippets.

@nulleqcodes
Last active October 17, 2024 20:48
Show Gist options
  • Save nulleqcodes/8b4ca9b2024c46a6fb092abdbf9d928e to your computer and use it in GitHub Desktop.
Save nulleqcodes/8b4ca9b2024c46a6fb092abdbf9d928e to your computer and use it in GitHub Desktop.
---mobdefinition_Storm Weaver---
Prefab :: colossus
Range Behavior :: [[Medium Ranged]]
Abilities :: [[Tempest Spiral]] [[Lightning Barrage]] [[Thunder Vortex]]
Bounding Box :: 0 2.73 2.5 3.0
Speed :: 150
Type :: Boss
Loot :: [[Colossus]]
---ability_Tempest Spiral---
Bullet Definition :: [[tempestspiral]]
VFX Cast :: trigger:Attack*
Lock Time :: 1.0
---bulletdef_tempestspiral---
sprite Custom_10
color 3
potency 75
repeat bullets:60 speed:6 angle:0 angleChange:25 delay:1 directionType:relative
wait 60
vanish
wait 15
repeat bullets:60 speed:7 angle:180 angleChange:-25 delay:1 directionType:relative
wait 60
vanish
wait 15
repeat bullets:30 speed:7 angle:90 angleChange:15 delay:1 directionType:relative
wait 60
vanish
repeat bullets:30 speed:7 angle:270 angleChange:-15 delay:1 directionType:relative
wait 60
vanish
---ability_Lightning Barrage---
Bullet Definition :: [[lightningbarrage]]
VFX Cast :: trigger:RangeAttack*
Lock Time :: 1.5
---bulletdef_lightningbarrage---
sprite Custom_7
color 4
potency 50
repeat bullets:5 angleChange:72 angle:0 directionType:relative
fire lightningspread1
wait 10
repeat bullets:5 angleChange:72 angle:36 directionType:relative
fire lightningspread2
wait 10
repeat bullets:10 angleChange:36 angle:0 directionType:relative
fire lightningbolt
---bulletdef_lightningspread1---
sprite Shock
color 4
potency 50
nway speed:12 bullets:7 spread:30 angle:0 directionType:relative
wait 60
vanish
---bulletdef_lightningspread2---
sprite Shock
color 4
potency 50
nway speed:10 bullets:5 spread:20 angle:0 directionType:relative
wait 60
vanish
---bulletdef_lightningbolt---
sprite Lance_14
color 4
potency 100
fire 15 relative 0
wait 30
vanish
---ability_Thunder Vortex---
Bullet Definition :: [[thundervortex]]
VFX Cast :: trigger:Beam
Lock Time :: 1.5
---bulletdef_thundervortex---
sprite Custom_12
color 1
potency 25
radial bullets:36 speed:8
wait 5
radial bullets:36 speed:7 angle:5 directionType:absolute
wait 5
radial bullets:36 speed:6 angle:10 directionType:absolute
repeat bullets:90 speed:4 angle:0 angleChange:14 delay:1 directionType:relative
wait 10
speed 0
wait 20
speed 12
wait 30
vanish
---script_colossus_Monster---
resetVars := func() {
scriptVars["phase"] = 1
scriptVars["timeSinceTempest"] = 0.0
scriptVars["timeSinceLightning"] = 0.0
scriptVars["timeSinceThunder"] = 0.0
}
if !isDead {
if is_undefined(scriptVars["phase"]) {
resetVars()
}
if targetEntityId > 0 && castingAction == 0 {
scriptVars["timeSinceTempest"] += delta
scriptVars["timeSinceLightning"] += delta
scriptVars["timeSinceThunder"] += delta
currentHealth := getPoints(myEntityId, "hp", "current")
maxHealth := getPoints(myEntityId, "hp", "max")
if currentHealth < maxHealth * 0.5 && scriptVars["phase"] == 1 {
scriptVars["phase"] = 2
setSpeed(myEntityId, 200)
}
if scriptVars["phase"] == 1 {
if scriptVars["timeSinceTempest"] > 5.0 {
useAbilityAtTarget(myEntityId, "Tempest Spiral", targetEntityId, 2.0)
scriptVars["timeSinceTempest"] = 0.0
} else if scriptVars["timeSinceLightning"] > 4.0 {
useAbilityAtTarget(myEntityId, "Lightning Barrage", targetEntityId, 1.0)
scriptVars["timeSinceLightning"] = 0.0
}
} else {
if scriptVars["timeSinceTempest"] > 4.0 {
useAbilityAtTarget(myEntityId, "Tempest Spiral", targetEntityId, 2.0)
scriptVars["timeSinceTempest"] = 0.0
} else if scriptVars["timeSinceLightning"] > 3.5 {
useAbilityAtTarget(myEntityId, "Lightning Barrage", targetEntityId, 1.0)
scriptVars["timeSinceLightning"] = 0.0
} else if scriptVars["timeSinceThunder"] > 6.0 {
useAbilityAtPosition(myEntityId, "Thunder Vortex", entityPosition(myEntityId))
scriptVars["timeSinceThunder"] = 0.0
}
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment