Skip to content

Custom Northstar Callbacks

Callbacks added by Northstar

Callbacks within squirrel trigger functions when certain events occur.

They will also often pass arguments to those functions based on the callbacks used.

List of callbacks

Please refer to Respawn Callbacks for the list of callbacks defined in respawn code.

_codecallbacks_common.gnut:

void AddClientCommandNotifyCallback( string commandString, void functionref( entity player, array args ) callbackFunc )

_custom_codecallbacks.gnut:

void CServerGameDLL_OnReceivedSayTextMessageCallback()

void AddCallback_OnReceivedSayTextMessage( ClServer_MessageStruct functionref (ClServer_MessageStruct) callbackFunc )

_items.nut:

void AddCallback_OnRegisterCustomItems( void functionref() callback )

_loadouts_mp.gnut:

bool ClientCommandCallback_RequestPilotLoadout( entity player, array args )

bool ClientCommandCallback_RequestTitanLoadout( entity player, array args )

bool ClientCommandCallback_SetPersistentLoadoutValue( entity player, array args )

bool ClientCommandCallback_SwapSecondaryAndWeapon3PersistentLoadoutData( entity player, array args )

bool ClientCommandCallback_SetBurnCardPersistenceSlot( entity player, array args )

bool ClientCommandCallback_SetCallsignIcon( entity player, array args )

bool ClientCommandCallback_SetCallsignCard( entity player, array args )

bool ClientCommandCallback_SetFactionChoicePersistenceSlot( entity player, array args )

bool ClientCommandCallback_LoadoutMenuClosed( entity player, array args )

bool ClientCommandCallback_InGameMPMenuClosed( entity player, array args )

_menu_callbacks.gnut:

void MenuCallbacks_Init()

bool ClientCommandCallback_LeaveMatch( entity player, array args )

bool ClientCommandCallback_GenUp( entity player, array args )

sh_remote_functions_mp_custom.gnut:

void AddCallback_OnRegisteringCustomNetworkVars( void functionref() callback )

evac\_evac.gnut:

void Evac( int evacTeam, float initialWait, float arrivalTime, float waitTime, bool functionref( entity, entity ) canBoardCallback, bool functionref( entity ) shouldLeaveEarlyCallback, void functionref( entity ) completionCallback, entity customEvacNode = null )

gamemodes_gamemode_fra.nut:

void GamemodeFRA_AddAdditionalInitCallback()

gamemodes\sh_gamemodes_custom.gnut:

void AddCallback_OnCustomGamemodesInit( void functionref() callback )

lobby\_lobby.gnut:

bool ClientCommandCallback_StartPrivateMatchSearch( entity player, array args )

lobby\_private_lobby.gnut:

bool ClientCommandCallback_PrivateMatchLaunch( entity player, array args )

bool ClientCommandCallback_PrivateMatchSetMode( entity player, array args )

bool ClientCommandCallback_SetCustomMap( entity player, array args )

bool ClientCommandCallback_PrivateMatchSwitchTeams( entity player, array args )

bool ClientCommandCallback_PrivateMatchToggleSpectate( entity player, array args )

bool ClientCommandCallback_PrivateMatchSetPlaylistVarOverride( entity player, array args )

bool ClientCommandCallback_ResetMatchSettingsToDefault( entity player, array args )

melee\sh_melee.gnut:

void AddCallback_IsValidMeleeExecutionTarget( bool functionref( entity attacker, entity target ) callbackFunc )

This callback gets triggered after the melee button is pressed to check if the action to execute the target is still valid. If one of the added callbacks return false the target won't be executed and will just be meleed.

Note

The execution prompt still pops up.

mp\_ai_mp.gnut:

bool SPMP_Callback_ForceAIMissPlayer( entity npc, entity player )

mp\_base_gametype_mp.gnut:

bool ClientCommandCallback_spec_next( entity player, array args )

bool ClientCommandCallback_spec_prev( entity player, array args )

bool ClientCommandCallback_spec_mode( entity player, array args )

mp\_gamestate_mp.nut:

void AddCallback_OnRoundEndCleanup( void functionref() callback )

void SetTimeoutWinnerDecisionFunc( int functionref() callback )

ui\ui_mouse_capture.nut:

void AddMouseMovementCaptureHandler( var capturePanelOrMenu, void functionref( int deltaX, int deltaY ) func )