OSDN Git Service

- Moved Sqrt, FixedSqrt, and VectorLength to zspecial.acs.
[zandronum/zandronum-acc.git] / symbol.c
index ee53db7..3c6a6d0 100644 (file)
--- a/symbol.c
+++ b/symbol.c
@@ -57,7 +57,8 @@ static internFuncDef_t InternalFunctions[] =
 {\r
        { "tagwait", PCD_TAGWAITDIRECT, PCD_TAGWAIT, 1, 0, 0, NO, YES },\r
        { "polywait", PCD_POLYWAITDIRECT, PCD_POLYWAIT, 1, 0, 0, NO, YES },\r
-       { "scriptwait", PCD_SCRIPTWAITDIRECT, PCD_SCRIPTWAIT, 1, 0, 0, NO, YES},\r
+       { "scriptwait", PCD_SCRIPTWAITDIRECT, PCD_SCRIPTWAIT, 1, 0, 0, NO, YES },\r
+       { "namedscriptwait", PCD_NOP, PCD_SCRIPTWAITNAMED, 1, 0, 0, NO, YES },\r
        { "delay", PCD_DELAYDIRECT, PCD_DELAY, 1, 0, 0, NO, YES },\r
        { "random", PCD_RANDOMDIRECT, PCD_RANDOM, 2, 0, 0, YES, NO },\r
        { "thingcount", PCD_THINGCOUNTDIRECT, PCD_THINGCOUNT, 2, 0, 0, YES, NO },\r
@@ -100,6 +101,8 @@ static internFuncDef_t InternalFunctions[] =
        { "bluescore", PCD_NOP, PCD_BLUETEAMSCORE, 0, 0, 0, YES, NO },\r
        { "redscore", PCD_NOP, PCD_REDTEAMSCORE, 0, 0, 0, YES, NO },\r
        { "isoneflagctf", PCD_NOP, PCD_ISONEFLAGCTF, 0, 0, 0, YES, NO },\r
+       { "getinvasionwave", PCD_NOP, PCD_GETINVASIONWAVE, 0, 0, 0, YES, NO },\r
+       { "getinvasionstate", PCD_NOP, PCD_GETINVASIONSTATE, 0, 0, 0, YES, NO },\r
        { "music_change", PCD_NOP, PCD_MUSICCHANGE, 2, 0, 0, NO, NO },\r
        { "consolecommand", PCD_CONSOLECOMMANDDIRECT, PCD_CONSOLECOMMAND, 3, 2|4, 0, NO, NO },\r
        { "singleplayer", PCD_NOP, PCD_SINGLEPLAYER, 0, 0, 0, YES, NO },\r
@@ -189,6 +192,11 @@ static internFuncDef_t InternalFunctions[] =
        { "setmugshotstate", PCD_NOP, PCD_SETMUGSHOTSTATE, 1, 0, 0, NO, NO },\r
        { "thingcountsector", PCD_NOP, PCD_THINGCOUNTSECTOR, 3, 0, 0, YES, NO },\r
        { "thingcountnamesector", PCD_NOP, PCD_THINGCOUNTNAMESECTOR, 3, 0, 0, YES, NO },\r
+       { "checkplayercamera", PCD_NOP, PCD_CHECKPLAYERCAMERA, 1, 0, 0, YES, NO },\r
+       { "morphactor", PCD_NOP, PCD_MORPHACTOR, 7, 2|4|8|16|32|64, 0, YES, NO },\r
+       { "unmorphactor", PCD_NOP, PCD_UNMORPHACTOR, 2, 2, 0, YES, NO },\r
+       { "getplayerinput", PCD_NOP, PCD_GETPLAYERINPUT, 2, 0, 0, YES, NO },\r
+       { "classifyactor", PCD_NOP, PCD_CLASSIFYACTOR, 1, 0, 0, YES, NO },\r
        \r
        { NULL, PCD_NOP, PCD_NOP, 0, 0, 0, NO, NO }\r
 };\r
@@ -513,6 +521,7 @@ static void FreeNodesAtDepth(symbolNode_t **root, int depth)
 static void DeleteNode(symbolNode_t *node, symbolNode_t **parent_p)\r
 {\r
        symbolNode_t **temp;\r
+       char *nametemp;\r
 \r
        if(node->left == NULL)\r
        {\r
@@ -548,7 +557,9 @@ static void DeleteNode(symbolNode_t *node, symbolNode_t **parent_p)
                                temp = &(*temp)->left;\r
                        }\r
                }\r
+               nametemp = node->name;\r
                node->name = (*temp)->name;\r
+               (*temp)->name = nametemp;\r
                node->type = (*temp)->type;\r
                node->unused = (*temp)->unused;\r
                node->imported = (*temp)->imported;\r