From 5edc1b0c98aed20cbd3b3bc429db9c5d17939945 Mon Sep 17 00:00:00 2001 From: DBmaoha <56738369+DBmaoha@users.noreply.github.com> Date: Sat, 8 Oct 2022 18:22:29 +0800 Subject: Added ReaperFall Marks and Reapers' Outlines (#468) * Added ReaperFall Marks and Reapers' Outlines Added red mark for reaperfall points and outline after landing * Fixed RoundEndCleanUp Crash * Better Outline Function --- .../scripts/vscripts/gamemodes/_ai_gamemodes.gnut | 41 ++++++++++++++++++++++ 1 file changed, 41 insertions(+) (limited to 'Northstar.CustomServers/mod/scripts') diff --git a/Northstar.CustomServers/mod/scripts/vscripts/gamemodes/_ai_gamemodes.gnut b/Northstar.CustomServers/mod/scripts/vscripts/gamemodes/_ai_gamemodes.gnut index d6d578bb7..0fad768c5 100644 --- a/Northstar.CustomServers/mod/scripts/vscripts/gamemodes/_ai_gamemodes.gnut +++ b/Northstar.CustomServers/mod/scripts/vscripts/gamemodes/_ai_gamemodes.gnut @@ -111,7 +111,16 @@ void function AiGameModes_SpawnDropPod( vector pos, vector rot, int team, string void function AiGameModes_SpawnReaper( vector pos, vector rot, int team, string aiSettings = "", void functionref( entity reaper ) reaperHandler = null ) { + thread Reaper_Spawnpoint( pos, team, 11.2 ) + + wait 10 + // spawn reapers right before it warpfalls, or round_end clean up will crash the game entity reaper = CreateSuperSpectre( team, pos, rot ) + // reaper highlight + Highlight_SetFriendlyHighlight( reaper, "sp_enemy_pilot" ) + reaper.Highlight_SetParam( 1, 0, < 3,3,3 > ) + Highlight_SetEnemyHighlight( reaper, "enemy_titan" ) + SetSpawnOption_Titanfall( reaper ) SetSpawnOption_Warpfall( reaper ) @@ -125,6 +134,38 @@ void function AiGameModes_SpawnReaper( vector pos, vector rot, int team, string thread reaperHandler( reaper ) } +// copied from cl_replacement_titan_hud.gnut +void function Reaper_Spawnpoint( vector origin, int team, float impactTime, bool hasFriendlyWarning = false ) +{ + array targetEffects = [] + vector surfaceNormal = < 0, 0, 1 > + + int index = GetParticleSystemIndex( $"P_ar_titan_droppoint" ) + + if( hasFriendlyWarning ) + { + entity effectFriendly = StartParticleEffectInWorld_ReturnEntity( index, origin, surfaceNormal ) + SetTeam( effectFriendly, team ) + EffectSetControlPointVector( effectFriendly, 1, < 128,188,255 > ) + effectFriendly.kv.VisibilityFlags = ENTITY_VISIBLE_TO_FRIENDLY + targetEffects.append( effectFriendly ) + } + + entity effectEnemy = StartParticleEffectInWorld_ReturnEntity( index, origin, surfaceNormal ) + SetTeam( effectEnemy, team ) + EffectSetControlPointVector( effectEnemy, 1, < 255,99,0 > ) + effectEnemy.kv.VisibilityFlags = ENTITY_VISIBLE_TO_ENEMY + targetEffects.append( effectEnemy ) + + wait impactTime + + foreach( entity targetEffect in targetEffects ) + { + if ( IsValid( targetEffect ) ) + EffectStop( targetEffect ) + } +} + // including aisettings stuff specifically for at bounty titans void function AiGameModes_SpawnTitan( vector pos, vector rot, int team, string setFile, string aiSettings = "", void functionref( entity titan ) titanHandler = null ) { -- cgit v1.2.3