Пример #1
0
        public static void initDefTypes()
        {
            {
                UInt16        utype    = 2;
                string        typeName = "ENTITY_SUBSTATE";
                string        name     = "UINT8";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 3;
                string        typeName = "UINT16";
                string        name     = "UINT16";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 5;
                string        typeName = "SPACE_KEY";
                string        name     = "UINT64";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 4;
                string        typeName = "FRAMEID";
                string        name     = "UINT32";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 6;
                string        typeName = "ENTITY_STATE";
                string        name     = "INT8";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 7;
                string        typeName = "INT16";
                string        name     = "INT16";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 8;
                string        typeName = "ENTITY_FORBIDS";
                string        name     = "INT32";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 9;
                string        typeName = "INT64";
                string        name     = "INT64";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 1;
                string        typeName = "STRING";
                string        name     = "STRING";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 12;
                string        typeName = "UNICODE";
                string        name     = "UNICODE";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 13;
                string        typeName = "FLOAT";
                string        name     = "FLOAT";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 14;
                string        typeName = "DOUBLE";
                string        name     = "DOUBLE";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 10;
                string        typeName = "UID1";
                string        name     = "PYTHON";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 10;
                string        typeName = "PY_DICT";
                string        name     = "PY_DICT";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 10;
                string        typeName = "PY_TUPLE";
                string        name     = "PY_TUPLE";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 10;
                string        typeName = "PY_LIST";
                string        name     = "PY_LIST";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 20;
                string        typeName = "ENTITYCALL";
                string        name     = "ENTITYCALL";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 11;
                string        typeName = "BLOB";
                string        name     = "BLOB";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 15;
                string        typeName = "VECTOR2";
                string        name     = "VECTOR2";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 16;
                string        typeName = "DIRECTION3D";
                string        name     = "VECTOR3";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 17;
                string        typeName = "VECTOR4";
                string        name     = "VECTOR4";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16 utype    = 22;
                string typeName = "ENTITY_FORBID_COUNTER";
                DATATYPE_ENTITY_FORBID_COUNTER datatype = new DATATYPE_ENTITY_FORBID_COUNTER();
                EntityDef.datatypes[typeName]   = datatype;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16 utype    = 23;
                string typeName = "ENTITYID_LIST";
                DATATYPE_ENTITYID_LIST datatype = new DATATYPE_ENTITYID_LIST();
                EntityDef.datatypes[typeName]   = datatype;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16 utype    = 24;
                string typeName = "AVATAR_DATA";
                DATATYPE_AVATAR_DATA datatype = new DATATYPE_AVATAR_DATA();
                EntityDef.datatypes[typeName]   = datatype;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16 utype    = 25;
                string typeName = "AVATAR_INFOS";
                DATATYPE_AVATAR_INFOS datatype = new DATATYPE_AVATAR_INFOS();
                EntityDef.datatypes[typeName]   = datatype;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16 utype    = 26;
                string typeName = "AVATAR_INFOS_LIST";
                DATATYPE_AVATAR_INFOS_LIST datatype = new DATATYPE_AVATAR_INFOS_LIST();
                EntityDef.datatypes[typeName]   = datatype;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16 utype    = 28;
                string typeName = "SPACE_INFO";
                DATATYPE_SPACE_INFO datatype = new DATATYPE_SPACE_INFO();
                EntityDef.datatypes[typeName]   = datatype;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16 utype    = 29;
                string typeName = "SPACE_LIST";
                DATATYPE_SPACE_LIST datatype = new DATATYPE_SPACE_LIST();
                EntityDef.datatypes[typeName]   = datatype;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16 utype    = 31;
                string typeName = "ENTITY_DATA";
                DATATYPE_ENTITY_DATA datatype = new DATATYPE_ENTITY_DATA();
                EntityDef.datatypes[typeName]   = datatype;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16 utype    = 32;
                string typeName = "FRAME_DATA";
                DATATYPE_FRAME_DATA datatype = new DATATYPE_FRAME_DATA();
                EntityDef.datatypes[typeName]   = datatype;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16 utype    = 34;
                string typeName = "FRAME_LIST";
                DATATYPE_FRAME_LIST datatype = new DATATYPE_FRAME_LIST();
                EntityDef.datatypes[typeName]   = datatype;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16       utype    = 36;
                string       typeName = "BAG";
                DATATYPE_BAG datatype = new DATATYPE_BAG();
                EntityDef.datatypes[typeName]   = datatype;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16            utype    = 39;
                string            typeName = "EXAMPLES";
                DATATYPE_EXAMPLES datatype = new DATATYPE_EXAMPLES();
                EntityDef.datatypes[typeName]   = datatype;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 40;
                string        typeName = "AnonymousArray_40";
                string        name     = "ENTITY_COMPONENT";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            foreach (string datatypeStr in EntityDef.datatypes.Keys)
            {
                DATATYPE_BASE dataType = EntityDef.datatypes[datatypeStr];
                if (dataType != null)
                {
                    dataType.bind();
                }
            }
        }
Пример #2
0
        public static void initDefTypes()
        {
            {
                UInt16        utype    = 2;
                string        typeName = "CMD_TYPE";
                string        name     = "UINT8";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 3;
                string        typeName = "UINT16";
                string        name     = "UINT16";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 5;
                string        typeName = "SPACE_KEY";
                string        name     = "UINT64";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 4;
                string        typeName = "FRAMEID";
                string        name     = "UINT32";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 6;
                string        typeName = "INT8";
                string        name     = "INT8";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 7;
                string        typeName = "INT16";
                string        name     = "INT16";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 8;
                string        typeName = "ENTITY_ID";
                string        name     = "INT32";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 9;
                string        typeName = "INT64";
                string        name     = "INT64";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 1;
                string        typeName = "STRING";
                string        name     = "STRING";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 12;
                string        typeName = "UNICODE";
                string        name     = "UNICODE";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 13;
                string        typeName = "FLOAT";
                string        name     = "FLOAT";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 14;
                string        typeName = "DOUBLE";
                string        name     = "DOUBLE";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 10;
                string        typeName = "PYTHON";
                string        name     = "PYTHON";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 10;
                string        typeName = "PY_DICT";
                string        name     = "PY_DICT";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 10;
                string        typeName = "PY_TUPLE";
                string        name     = "PY_TUPLE";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 10;
                string        typeName = "PY_LIST";
                string        name     = "PY_LIST";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 20;
                string        typeName = "ENTITYCALL";
                string        name     = "ENTITYCALL";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 11;
                string        typeName = "BLOB";
                string        name     = "BLOB";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 15;
                string        typeName = "VECTOR2";
                string        name     = "VECTOR2";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 16;
                string        typeName = "DIRECTION3D";
                string        name     = "VECTOR3";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16        utype    = 17;
                string        typeName = "VECTOR4";
                string        name     = "VECTOR4";
                DATATYPE_BASE val      = null;
                EntityDef.datatypes.TryGetValue(name, out val);
                EntityDef.datatypes[typeName]   = val;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16 utype    = 22;
                string typeName = "ENTITY_DATA";
                DATATYPE_ENTITY_DATA datatype = new DATATYPE_ENTITY_DATA();
                EntityDef.datatypes[typeName]   = datatype;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16 utype    = 23;
                string typeName = "FRAME_DATA";
                DATATYPE_FRAME_DATA datatype = new DATATYPE_FRAME_DATA();
                EntityDef.datatypes[typeName]   = datatype;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            {
                UInt16 utype    = 25;
                string typeName = "FRAME_LIST";
                DATATYPE_FRAME_LIST datatype = new DATATYPE_FRAME_LIST();
                EntityDef.datatypes[typeName]   = datatype;
                EntityDef.id2datatypes[utype]   = EntityDef.datatypes[typeName];
                EntityDef.datatype2id[typeName] = utype;
            }

            foreach (string datatypeStr in EntityDef.datatypes.Keys)
            {
                DATATYPE_BASE dataType = EntityDef.datatypes[datatypeStr];
                if (dataType != null)
                {
                    dataType.bind();
                }
            }
        }