Lua:UpdateObjectiveIcon

From Fortress Forever Wiki
Jump to navigationJump to search


UpdateObjectiveIcon

Set the objective icon for a single player.

Usage

UpdateObjectiveIcon(player, entity)

Input

player(CFFPlayer) The player who will see the objective. entity(CBaseEntity) The entity that will be the objective. Could be a flag, player, or trigger. Use nil to remove the objective.

Output

Returns: nothing

Example

local player = CastToPlayer( player_entity )
--set the player's objective to a cap point
UpdateObjectiveIcon( player, GetEntityByName( team.."_cap" ) )
--clear it after a cap
UpdateObjectiveIcon( player, nil )