aboutsummaryrefslogtreecommitdiff
path: root/Northstar.CustomServers/mod/scripts/vscripts/mp/levels
diff options
context:
space:
mode:
authorBobTheBob <32057864+BobTheBob9@users.noreply.github.com>2021-12-19 17:32:09 +0000
committerBobTheBob <32057864+BobTheBob9@users.noreply.github.com>2021-12-19 17:32:09 +0000
commitf8685213baf4eef93dae6cc98c8e4a8318565bd3 (patch)
treec5bfb10ee066e5f7fb031376ddb8b435577b2991 /Northstar.CustomServers/mod/scripts/vscripts/mp/levels
parent7cac56cb9bcaabed9562a7b46718f5c5de3400b8 (diff)
downloadNorthstarMods-f8685213baf4eef93dae6cc98c8e4a8318565bd3.tar.gz
NorthstarMods-f8685213baf4eef93dae6cc98c8e4a8318565bd3.zip
fixes and dropship refactor
Diffstat (limited to 'Northstar.CustomServers/mod/scripts/vscripts/mp/levels')
-rw-r--r--Northstar.CustomServers/mod/scripts/vscripts/mp/levels/mp_lf_deck.nut25
1 files changed, 24 insertions, 1 deletions
diff --git a/Northstar.CustomServers/mod/scripts/vscripts/mp/levels/mp_lf_deck.nut b/Northstar.CustomServers/mod/scripts/vscripts/mp/levels/mp_lf_deck.nut
index dca30fe9..592422ee 100644
--- a/Northstar.CustomServers/mod/scripts/vscripts/mp/levels/mp_lf_deck.nut
+++ b/Northstar.CustomServers/mod/scripts/vscripts/mp/levels/mp_lf_deck.nut
@@ -2,6 +2,29 @@ global function CodeCallback_MapInit
void function CodeCallback_MapInit()
{
- FlagClear( "Disable_Marvins" )
SetupLiveFireMaps()
+
+ // worker drone model
+ PrecacheModel( $"models/robots/aerial_unmanned_worker/aerial_unmanned_worker.mdl" )
+
+ // note: this map has no marvin spawns, have to spawn them using idle nodes
+ AddSpawnCallback_ScriptName( "worker_drone_spawn", DeckSpawnWorkerDrone )
+ AddSpawnCallback_ScriptName( "marvin_idle_node", DeckSpawnMarvinForIdleNode )
+}
+
+void function DeckSpawnWorkerDrone( entity spawnpoint )
+{
+
+ entity drone = CreateWorkerDrone( TEAM_UNASSIGNED, spawnpoint.GetOrigin(), spawnpoint.GetAngles() )
+ DispatchSpawn( drone )
+}
+
+void function DeckSpawnMarvinForIdleNode( entity node )
+{
+ entity marvin = CreateMarvin( TEAM_UNASSIGNED, node.GetOrigin(), node.GetAngles() )
+ DispatchSpawn( marvin )
+
+ // doing this because no ai rn
+ if ( GetAINScriptVersion() == -1 )
+ thread PlayAnim( marvin, node.kv.leveled_animation )
} \ No newline at end of file