From 20458aa7e5a712b22b6a5a63187d75e1bc4b43f2 Mon Sep 17 00:00:00 2001 From: Barichello Date: Thu, 20 Jan 2022 10:45:58 -0300 Subject: Add debug titan spawn function --- .../vscripts/titan/_replacement_titans_drop.gnut | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) (limited to 'Northstar.CustomServers/mod') diff --git a/Northstar.CustomServers/mod/scripts/vscripts/titan/_replacement_titans_drop.gnut b/Northstar.CustomServers/mod/scripts/vscripts/titan/_replacement_titans_drop.gnut index 5970f7eab..743fc8eaf 100644 --- a/Northstar.CustomServers/mod/scripts/vscripts/titan/_replacement_titans_drop.gnut +++ b/Northstar.CustomServers/mod/scripts/vscripts/titan/_replacement_titans_drop.gnut @@ -1,7 +1,8 @@ global function ReplacementTitansDrop_Init global function GetTitanReplacementPoint global function HullTraceDropPoint -global function DebugTitanSpawn +global function DebugSpawnTitan +global function DebugTitanfall global function TitanFindDropNodes global function TitanHulldropSpawnpoint @@ -41,12 +42,21 @@ void function AddDroppoint( entity ent ) AddToScriptManagedEntArray( file.replacementSpawnpointsID, ent ) } -void function DebugTitanSpawn() +void function DebugSpawnTitan() { - thread DebugTitanSpawnThread() + entity player = GetPlayerArray()[0] + vector spawnpointOrigin = player.GetOrigin() + vector spawnpointAngles = VectorToAngles( FlattenVector( GetPlayerArray()[0].GetViewVector() ) * -1 ) + entity titan = CreateAutoTitanForPlayer_FromTitanLoadout( player, GetTitanLoadoutForPlayer( player ), spawnpointOrigin, spawnpointAngles ) + DispatchSpawn( titan ) +} + +void function DebugTitanfall() +{ + thread DebugTitanfallThread() } -void function DebugTitanSpawnThread() +void function DebugTitanfallThread() { entity player = GetPlayerArray()[0] -- cgit v1.2.3