Skip to content
This repository has been archived by the owner on Feb 21, 2023. It is now read-only.
BananaCake2Day edited this page Mar 3, 2019 · 4 revisions

The Map singleton can be accessed from the Server. Server.Map

Methods

Map.DetonateWarhead()

Instantly detonates the alpha warhead.

Map.StartWarhead()

Starts detonation of the alpha warhead as if a player activated it.

Map.StopWarhead()

Stops detonation of the alpha warhead as if a player deactivated it.

Map.Shake()

Shakes the screen of all clients. This is the same effect when the alpha warhead detonates.

Map.SpawnItem(ItemType type, Vector pos, Vector rotation)

Spawns an item in the world of ItemType type and at the position pos.

Parameters:

Type Name Default Description
ItemType type none The item to spawn.
Vector pos none The position to spawn it at.
Vector rotation null The rotation to spawn it at.

Map.FemurBreaker(bool enable)

Activates the Femur Breaker / 106 Recontainment Procedures. It can also deactivate it, but don't count on it.

Parameters:

Type Name Default Description
bool enable none To enable or disable the femur breaker

Map.AnnounceNtfEntrance(int scpsLeft, int mtfNumber, char mtfLetter)

Makes a NTF announcement, like one you'd hear when MTF spawns.

Parameters:

Type Name Default Description
int scpsLeft none The number of SCPs left in the announcement.
int mtfNumber none The number squadron (03-BRAVO).
char mtfLetter none The letter squadron (03-BRAVO).

Map.AnnounceScpKill(string scpNumber, Player killer) void

Makes a SCP re-contained announcement, like one you'd hear when a SCP is killed.

Parameters:

Type Name Default Description
string scpNumber none The amount of SCPs left in the announcement.
Player killer null The killer of the SCP.

Map.AnnounceCustomMessage(string words)

Makes a CASSIE custom announcement. CASSIE can only pronounce a set list of phrases found here, and when a phrase cannot be pronounced, it is not said in the announcement.

Parameters:

Type Name Default Description
string words none The words to be pronounced by the CASSIE system.

Map.Broadcast(uint duration, string message, bool isMonoSpaced)

Broadcasts a message. This message is printed to the screen for every client. isMonoSpaced decides if the message is monospaced.

Parameters:

Type Name Default Description
uint duration none How long the broadcast will linger on player screens.
string message none The message to display.
bool isMonoSpaced none Whether the broadcast is displayed monospaced.

Map.ClearBroadcasts()

Clears the broadcasts of each client.

Getting

Map.GetItems(ItemType type, bool world_only)

Gets all of the items in the world. If world_only is false, will also search through player inventories to find items. The type parameter can be used to filter the type of item to find. Also, see the static method Item.GetItems()

Parameters

Type Name Default Description
ItemType type none Filters the list by ItemType.
bool world_only none Determines if the method will also search through player inventories to find items.

Returns: List<Item>

Map.GetElevatorTeleportPoints()

Returns each pair of elevator teleport points in the world. Each individual elevator has two points that players teleport between when using elevators.

Returns: Dictionary<Vector, Vector>

Map.GetElevators()

Returns all elevators in the world.

Returns: List<Elevator>

Map.GetGenerators()

Gets all of the generators in the world.

Returns: Generator[]

Map.Get079InteractionRooms(Scp079InteractionType type)

Returns all the rooms that support the Scp079InteractionType type passed in the function.

Parameters:

Type Name Default Description
Scp079InteractionType type none The Scp079InteractionType to filter with.

Returns: Room[]

Map.GetRandomSpawnPoint(Role role)

Returns a Vector of a random spawn point according to the Role passed. EG: A role of Role.CLASSD will return a random D-Class cell. A role of Role.SCP_173 will return 173's chamber.

Parameters:

Type Name Default Description
Role role none The role to get a random spawn point of.

Returns: Vector

Map.GetSpawnPoints(Role role)

Returns a list of positions that represent all possible spawn points for that role.

Parameters:

Type Name Default Description
Role role none The role to get all spawn points of.

Returns: List<Vector>

Map.GetBlastDoorPoints()

Returns the positions of all blast doors in the world.

Returns: List<Vector>

Map.GetDoors()

Returns a list of all doors in the world.

Returns: List<Door>

Map.GetTeslaGates()

Returns a list of all the tesla gates in the world.

Returns: List<TeslaGate>

Map.GetPocketDimensionExits()

Returns a list of all pocket dimension exits in the world.

Returns: List<PocketDimensionExit>

Map.GetIntercomSpeaker()

Gets the current intercom speaker. The value returned is null most of the time, so don't forget null checks before doing anything important!

Returns: Player

Map.GetIntercomContent(IntercomStatus intercomStatus)

Gets the content of the intercom status message.

Parameters:

Type Name Default Description
IntercomStatus intercomStatus none The intercom status to get the content of.

Returns: string

Setting

Map.SetIntercomSpeaker(Player player)

Sets the intercom speaker. This method is affected by cooldown.

Parameters:

Type Name Default Description
Player player none The new speaker

Map.SetIntercomContent(IntercomStatus intercomStatus, string content)

Sets the content of the intercom status message. Keep in mind that this will only set the intercom status message of the intercom status you passed in intercomStatus. Which means after setting the intercom content of IntercomStatus.READY, it will only display when READY. Further testing required

Parameters:

Type Name Default Description
IntercomStatus intercomStatus none The IntercomStatus to set the content to.
string content none The content.

Properties

Map.WarheadDetonated

Has the warhead been detonated? Read only.

Field Value: bool

Map.LCZDecontaminated

Has Lower Containment been decontaminated? Read only.

Field Value: bool

Server Guides

API Documents

Clone this wiki locally