User:Nescius: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
(Created page with "I just want to see my name in blue. You can leave now")
 
No edit summary
Line 1: Line 1:
I just want to see my name in blue. You can leave now
I just want to see my name in blue. You can leave now
probably useful
<source lang=c>
getconsttable() = { ... } //variables made with const and enum go here
getroottable() = { //script and script_execute scripts are executed in this scope
    //global shortcuts {
    g_ModeScript = DirectorScript.MapScript.ChallengeScript
    g_MapScript = DirectorScript.MapScript
    SessionOptions = g_ModeScript.DirectorOptions
    SessionState = g_ModeScript.MutationState
    SessionSpawns = g_MapScript.MapSpawns
    // }
    g_RoundState = { ... } //used by hints and StartBox stuff in sm_utilities
    g_rr = { ... } //response rules related stuff
    GameEventCallbacks = { ... } //OnGameEvent_
    ScriptEventCallbacks = { ... } //OnScriptEvent_
    DirectorScript = { //director_base.nut executed in this scope
        DirectorOptions = { ... } //4
        MapScript = { //mapscripts, trigger_finale scripts and scriptedmode.nut executed in this scope
            DirectorOptions = { ... } //3
            BaseScriptedDOTable = { ... } //added into ChallengeScript.DirectorOptions
            //these come from mapscripts {
            MapOptions = { ... } //added into ChallengeScript.DirectorOptions
            MapState = { ... } //added into ChallengeScript.MutationState
            MapSpawns = [] //entity groups to spawn
            SanitizeTable = { ... } //entities to remove
            // }
            ChallengeScript = { //modescripts executed in this scope
                MutationOptions = { ... } //added into DirectorOptions (below)
                MutationState = { ... }
                ModeSpawns = [] //added into MapSpawns
                DirectorOptions = { ... } //1
            }
            LocalScript = { //director's BeginScript input runs script in this scope
                DirectorOptions = { ... } //2
            }
            ScriptedDamageInfo = { ... } //used by AllowTakeDamage
            //entity group related
            EntityGroups = { ... }
            InstancedEntityGroup = { ... }
            ReplacementParms = { ... }
            UniqueTargetnames = { ... }
            //startbox related
            StartboxFloating_Info = { ... }
            StartboxCenter_Info = { ... }
            StartboxSpeedbump_Info = { ... }
            defaultClearout = { ... } //for clearout (used in holdout)
        }
    }
    g_ClearoutTable = { ... } //for clearout (used in holdout)
    //script_debug commands related
    ScriptDebugTraces = { ... }
    ScriptDebugTextFilters = { ... }
    //documentation
    _PublishedHelp = { ... }
    Documentation = {
        classes = { ... }
        instances = { ... }
        functions = { ... }
    }
    SPAWN_FLAGS = { ... } //entitygroup related, used in MapSpawns thingy
    //entity scopes are created in getroottable() example:
    //<uniquestring><targetname or classname if no targetname> = {}
    _10dc_worldspawn = { ... }
    //name of this scope is saved in entity's m_iszScriptId
    //entity's RunScriptCode,RunScriptFile inputs create this scope if it doesn't exist and executes script in it
    //also scripts specified in entity's 'vscripts' keyvalue executed in this scope
}
</source>

Revision as of 23:09, 8 April 2022

I just want to see my name in blue. You can leave now

probably useful

getconsttable() = { ... } //variables made with const and enum go here
getroottable() = { //script and script_execute scripts are executed in this scope

    //global shortcuts {
    g_ModeScript = DirectorScript.MapScript.ChallengeScript
    g_MapScript = DirectorScript.MapScript

    SessionOptions = g_ModeScript.DirectorOptions
    SessionState = g_ModeScript.MutationState
    SessionSpawns = g_MapScript.MapSpawns
    // }

    g_RoundState = { ... } //used by hints and StartBox stuff in sm_utilities

    g_rr = { ... } //response rules related stuff

    GameEventCallbacks = { ... } //OnGameEvent_
    ScriptEventCallbacks = { ... } //OnScriptEvent_

    DirectorScript = { //director_base.nut executed in this scope
        DirectorOptions = { ... } //4

        MapScript = { //mapscripts, trigger_finale scripts and scriptedmode.nut executed in this scope
            DirectorOptions = { ... } //3
            BaseScriptedDOTable = { ... } //added into ChallengeScript.DirectorOptions

            //these come from mapscripts {
            MapOptions = { ... } //added into ChallengeScript.DirectorOptions
            MapState = { ... } //added into ChallengeScript.MutationState
            MapSpawns = [] //entity groups to spawn

            SanitizeTable = { ... } //entities to remove
            // }

            ChallengeScript = { //modescripts executed in this scope
                MutationOptions = { ... } //added into DirectorOptions (below)
                MutationState = { ... }
                ModeSpawns = [] //added into MapSpawns

                DirectorOptions = { ... } //1
            }

            LocalScript = { //director's BeginScript input runs script in this scope
                DirectorOptions = { ... } //2
            }

            ScriptedDamageInfo = { ... } //used by AllowTakeDamage

            //entity group related
            EntityGroups = { ... }
            InstancedEntityGroup = { ... }
            ReplacementParms = { ... }
            UniqueTargetnames = { ... }

            //startbox related
            StartboxFloating_Info = { ... }
            StartboxCenter_Info = { ... }
            StartboxSpeedbump_Info = { ... }

            defaultClearout = { ... } //for clearout (used in holdout)
        }
    }

    g_ClearoutTable = { ... } //for clearout (used in holdout)

    //script_debug commands related
    ScriptDebugTraces = { ... }
    ScriptDebugTextFilters = { ... }

    //documentation
    _PublishedHelp = { ... }
    Documentation = {
        classes = { ... }
        instances = { ... }
        functions = { ... }
    }

    SPAWN_FLAGS = { ... } //entitygroup related, used in MapSpawns thingy

    //entity scopes are created in getroottable() example:
    //<uniquestring><targetname or classname if no targetname> = {}
    _10dc_worldspawn = { ... }
    //name of this scope is saved in entity's m_iszScriptId
    //entity's RunScriptCode,RunScriptFile inputs create this scope if it doesn't exist and executes script in it
    //also scripts specified in entity's 'vscripts' keyvalue executed in this scope
}