getEngineState COMMAND && DOC

git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@6197 e016b1c5-ed68-44aa-a2f7-31cac88cffde
This commit is contained in:
flowtron
2011-04-02 15:41:52 +00:00
parent 0b2b78389b
commit 5bce19a3fd
2 changed files with 31 additions and 8 deletions
+26 -8
View File
@@ -90,18 +90,17 @@
</command>
<command name="push">
<description>Temporarily redefines the value of an alias.</description>
<description>Temporarily redefines the value of an alias.</description>
<arguments>
<argument token="N" description="alias name"/>
<argument token="A" description="action"/>
</arguments>
<examples>
<example>
<code><![CDATA[p = 1; push p 2; echo $p]]></code>
<explanation>Output: 2
</explanation>
</example>
</examples>
<examples>
<example>
<code><![CDATA[p = 1; push p 2; echo $p]]></code>
<explanation>Output: 2</explanation>
</example>
</examples>
<references>
<identifierReference identifier="pop"/>
</references>
@@ -1021,6 +1020,25 @@
</arguments>
</command>
<command name="getEngineState">
<description>Returns a list of values describing the current engine (rendering) state.</description>
<remarks>
<remark>It will only be filled after the first frame was drawn.</remark>
<remark>The list is: FPS LOD WQD WVT EVT</remark>
<remark>FPS = Frames Per Second</remark>
<remark>LOD = Level Of Detail</remark>
<remark>WQD = World QuaD Count</remark>
<remark>WVT = World VerTex Count </remark>
<remark>EVT = Extra VerTex Count (HUD &amp; menu)</remark>
</remarks>
<examples>
<example>
<code><![CDATA[echo (getEngineState)
]]></code>
</example>
</examples>
</command>
<variable name="networkdebug">
<description>Enables output of processed network packets.</description>
<remarks>
+5
View File
@@ -692,6 +692,10 @@ void drawscores()
glPopAttrib();
}
string enginestateinfo = "";
void CSgetEngineState() { result(enginestateinfo); }
COMMANDN(getEngineState, CSgetEngineState, ARG_NONE);
VARP(clockdisplay,0,0,2);
VARP(dbgpos,0,0,1);
void gl_drawhud(int w, int h, int curfps, int nquads, int curvert, bool underwater)
@@ -781,6 +785,7 @@ void gl_drawhud(int w, int h, int curfps, int nquads, int curvert, bool underwat
extern void r_accuracy();
if (!is_spect) r_accuracy();
if(!hideconsole) renderconsole();
formatstring(enginestateinfo)("%d %d %d %d %d", curfps, lod_factor(), nquads, curvert, xtraverts);
if(showstats)
{
if(showstats==2)