spawnfunc_target_print(this);
}
-.bool notteam;
-.bool notsingle;
-.bool notfree;
-.bool notta;
-.bool notvq3;
-.bool notcpm;
.string gametype;
.string not_gametype;
bool DoesQ3ARemoveThisEntity(entity this)
// Xonotic is usually played with a CPM-based physics so we default to CPM mode
if(cvar_string("g_mod_physics") == "Q3")
{
- if(this.notvq3)
+ if(stof(GetField_fullspawndata(this, "notvq3")))
return true;
}
- else if(this.notcpm)
+ else if(stof(GetField_fullspawndata(this, "notcpm")))
return true;
// Q3 mappers use "notq3a" or "notta" to disable an entity in Q3A or Q3TA
// Xonotic has ~equivalent features to Team Arena
- if(this.notta)
+ if(stof(GetField_fullspawndata(this, "notta")))
return true;
// FIXME: singleplayer does not use maxclients 1 as that would prevent bots,
// this is the case in Q3 also, it uses another method to block clients.
// Only accessible in VQ3, via the `spmap` command.
- if(this.notsingle)
+ if(stof(GetField_fullspawndata(this, "notsingle")))
if(maxclients == 1 && IS_GAMETYPE(DEATHMATCH))
return true;
- if(this.notteam)
+ if(stof(GetField_fullspawndata(this, "notteam")))
if(teamplay)
return true;
- if(this.notfree)
+ if(stof(GetField_fullspawndata(this, "notfree")))
if(!teamplay)
return true;
q3compat = BITSET(q3compat, Q3COMPAT_DEFI, _MapInfo_FindArenaFile(mapname, ".defi") != "");
// quake 3 music support
- if(world.music || world.noise)
- {
+ // bones_was_here: Q3 doesn't support .noise but the Nexuiz _MapInfo_Generate() does.
+ // TODO: Q3 supports an optional intro file: "music/intro.wav music/loop.wav"
+ string music = GetField_fullspawndata(world, "music", true);
+ if (music || world.noise)
// prefer .music over .noise
- string chosen_music;
- if(world.music)
- chosen_music = world.music;
- else
- chosen_music = world.noise;
-
- string newstuff = strcat(clientstuff, "cd loop \"", chosen_music, "\"\n");
- strcpy(clientstuff, newstuff);
- }
+ strcpy(clientstuff, strcat(clientstuff, "cd loop \"", (music ? music : world.noise), "\"\n"));
if(whichpack(strcat("maps/", mapname, ".cfg")) != "")
{
void CheckRules_World();
float RedirectionThink();
-// quake 3 music compatibility
-.string music;
-.string noise;
-
void readplayerstartcvars();
void readlevelcvars();