SetGlobalInt

From Garry's Mod
Jump to: navigation, search
 SetGlobalInt( )

Contents

Description

Sets an integer that is shared between the server and all clients.

NOTE

Running this function clientside will only set it clientside for the client it is called on!

BUG

This function will not round decimal values as it actually networks a float internally.

Issue Tracker: #3374

Arguments

string index

The unique index to identify the global value with.

Arguments

number value

The value to set the global value to

Examples

Example

Sets the current round number.

SetGlobalInt("RoundNumber", 4)


Personal tools
Navigation