Es.getInt

From EventScripts Community Encyclopedia
This article is a stub. Please help by adding to it.



Method: getInt

Module: es
Class: (no class)
EventScripts version: 2.0

Method Overview

Table of Contents

Contents


Description

Returns a server variable as Integer in Python.

Arguments

es.getInt('<server_variable>')


Examples

import es
 
def load():
    # Gets gravity
    grav = es.getInt('sv_gravity')
    # Divides gravity by 2
    grav /= 2
    # Sets gravity to the new value
    es.set('sv_gravity',grav)

Notes


See Also

blog comments powered by Disqus