Merge branch 'master' into bones_was_here/q3compat
authorbones_was_here <bones_was_here@xa.org.au>
Sun, 18 Oct 2020 11:18:12 +0000 (21:18 +1000)
committerbones_was_here <bones_was_here@xa.org.au>
Sun, 18 Oct 2020 11:18:12 +0000 (21:18 +1000)
18 files changed:
1  2 
qcsrc/common/mapobjects/func/door.qc
qcsrc/common/mapobjects/trigger/jumppads.qc
qcsrc/common/mutators/mutator/buffs/sv_buffs.qc
qcsrc/common/physics/player.qc
qcsrc/common/weapons/all.qc
qcsrc/common/weapons/weapon/shockwave.qc
qcsrc/lib/spawnfunc.qh
qcsrc/lib/warpzone/common.qc
qcsrc/server/client.qc
qcsrc/server/compat/quake.qc
qcsrc/server/compat/quake3.qc
qcsrc/server/items/items.qc
qcsrc/server/items/spawning.qc
qcsrc/server/main.qc
qcsrc/server/race.qc
qcsrc/server/teamplay.qc
qcsrc/server/weapons/spawning.qc
qcsrc/server/world.qc

Simple merge
index 88fd6aa73128469763ef254fb227682798a0425a,50b5d91b50dba9d844b301ea1586319e6e13f662..dbe43ace3b7ab002bf2f957aab568e8b76c1fb46
@@@ -57,9 -56,16 +56,16 @@@ void buffs_BuffModel_Spawn(entity playe
        setcefc(player.buff_model, buffs_BuffModel_Customize);
  }
  
+ void buffs_BuffModel_Remove(entity player)
+ {
+       if(player.buff_model)
+               delete(player.buff_model);
+       player.buff_model = NULL;
+ }
  vector buff_GlowColor(entity buff)
  {
 -      //if(buff.team) { return Team_ColorRGB(buff.team); }
 +      //if(buff.team_forced) { return Team_ColorRGB(buff.team_forced); }
        return buff.m_color;
  }
  
Simple merge
Simple merge
index 939c5a7e5307daa94e54b2346dcf53efa0467345,5c1cfac379a440723d76e44b1f842fdf36706039..54732766b4a3df0dad3024c210c8b6f141eb828b
@@@ -283,13 -277,9 +283,14 @@@ noref bool __spawnfunc_first
                if (!this.sourceLoc) { \
                        this.sourceLoc = __FILE__":"STR(__LINE__); \
                } \
+               this.classname = #id; \
                if (!this.spawnfunc_checked) { \
                        _checkWhitelisted(this, #id); \
 +                      if (__fullspawndata) { \
 +                              /* not supported in old DP */ \
 +                              /* must be read inside the real spawnfunc */ \
 +                              this.fullspawndata = __fullspawndata; \
 +                      } \
                        this.spawnfunc_checked = true; \
                        if (this) { \
                                /* not worldspawn, delay spawn */ \
Simple merge
Simple merge
index 8c227f9bebaf003e89a2014b9f74ef439e8bcad3,a49b85f18f60b0150898a491d78ac86a0879fec0..279b3155db68baf2296de2f3e8a5a382d40ebc22
@@@ -1,16 -1,13 +1,16 @@@
  #include "quake.qh"
  
- #include <common/weapons/_all.qh>
  #include <common/stats.qh>
  #include <common/weapons/_all.qh>
+ #include <common/weapons/_all.qh>
  
 -//***********************
 -//QUAKE 1 ENTITIES - So people can play quake1 maps with the xonotic weapons
 -//***********************
 -SPAWNFUNC_WEAPON(weapon_nailgun, WEP_ELECTRO)
 +/***********************
 + * QUAKE 1 ENTITIES - So people can play quake1 maps with the xonotic weapons
 + ***********************
 + weapon_nailgun handled in quake3.qc
 + item_armor1 handled in items.qc
 +*/
 +
  SPAWNFUNC_WEAPON(weapon_supernailgun, WEP_HAGAR)
  SPAWNFUNC_WEAPON(weapon_supershotgun, WEP_MACHINEGUN)
  
index 4c50ea51f66822002ca47d48f9509b2f20df34c3,ea951ddceb3e573b9b0137b4f9bc1fb45b8a1435..5acd24a58aea87f4e1d660e0ff9cfa73c34e3d59
@@@ -1,84 -1,54 +1,85 @@@
  #include "quake3.qh"
  
- #include <server/client.qh>
- #include <common/weapons/_all.qh>
- #include <common/stats.qh>
- #include <server/items/items.qh>
- #include <server/items/spawning.qh>
- #include <server/resources.qh>
- #include <server/world.qh>
  #include <common/gamemodes/_mod.qh>
  #include <common/gamemodes/gamemode/ctf/sv_ctf.qh>
- #include <common/mapobjects/triggers.qh>
  #include <common/mapobjects/trigger/counter.qh>
+ #include <common/mapobjects/triggers.qh>
  #include <common/mutators/mutator/buffs/buffs.qh>
  #include <common/notifications/all.qh>
+ #include <common/stats.qh>
+ #include <common/weapons/_all.qh>
+ #include <common/weapons/_all.qh>
+ #include <server/client.qh>
+ #include <server/items/items.qh>
+ #include <server/items/spawning.qh>
+ #include <server/resources.qh>
+ #include <server/world.qh>
  
 -//***********************
 -//QUAKE 3 ENTITIES - So people can play quake3 maps with the xonotic weapons
 -//***********************
 +/***********************
 + * QUAKE 3 ENTITIES - So people can play quake3 maps with the xonotic weapons
 + ***********************
 +
 + * Map entities NOT handled in this file:
 + holdable_invulnerability     Q3TA    buffs mutator
 + holdable_kamikaze            Q3TA    buffs mutator
 + holdable_teleporter          Q3A     buffs mutator
 + item_ammoregen                       Q3TA    buffs mutator
 + item_doubler                 Q3TA    buffs mutator
 + item_guard                   Q3TA    buffs mutator
 + item_scout                   Q3TA    buffs mutator
 + item_armor_jacket            CPMA    quake2.qc
 + item_flight                  Q3A     buffs mutator
 + item_haste                   Q3A     buffs mutator
 + item_health                  Q3A     quake.qc
 + item_health_large            Q3A     items.qc
 + item_health_small            Q3A     health.qh
 + item_health_mega             Q3A     health.qh
 + item_invis                   Q3A     buffs mutator
 + item_quad                    Q3A     items.qc
 + item_regen                   Q3A     buffs mutator
 + weapon_machinegun            Q3A     machinegun.qh
 + weapon_grenadelauncher               Q3A     mortar.qh
 + weapon_rocketlauncher                Q3A     devastator.qh
 + CTF spawnfuncs handled in sv_ctf.qc
 +
 + NOTE: for best experience, you need to swap MGs with SGs in the map or it won't have a MG
 +*/
 +
 +// SG -> MG || SG
 +SPAWNFUNC_Q3_COND(weapon_shotgun, ammo_shells, (q3compat & Q3COMPAT_ARENA), WEP_MACHINEGUN, WEP_SHOTGUN)
 +
 +// MG -> SG || MG
 +// Technically we should replace weapon_machinegun with WEP_SHOTGUN if Q3COMPAT_ARENA, but it almost never occurs on Q3 maps
 +SPAWNFUNC_Q3AMMO_COND(ammo_bullets, (q3compat & Q3COMPAT_ARENA), WEP_SHOTGUN, WEP_MACHINEGUN)
  
 -// NOTE: for best experience, you need to swap MGs with SGs in the map or it won't have a MG
 +// GL -> Mortar
 +SPAWNFUNC_Q3AMMO(ammo_grenades, WEP_MORTAR)
  
 -// SG -> SG
 -SPAWNFUNC_ITEM(ammo_shells, ITEM_Shells)
 +// Team Arena Proximity Launcher -> Mortar
 +// It's more accurate to spawn Mine Layer but players prefer Mortar, and weapon_grenadelauncher is usually disabled by "notta" and weapon_prox_launcher placed at the same origin
 +SPAWNFUNC_Q3(weapon_prox_launcher, ammo_mines, WEP_MORTAR)
  
 -// MG -> MG
 -SPAWNFUNC_ITEM(ammo_bullets, ITEM_Bullets)
 +// Team Arena Chaingun -> HLAC
 +SPAWNFUNC_Q3(weapon_chaingun, ammo_belt, WEP_HLAC)
  
 -// GL -> Mortar
 -SPAWNFUNC_ITEM(ammo_grenades, ITEM_Rockets)
 +// Quake Live Heavy Machine Gun -> HLAC
 +SPAWNFUNC_Q3(weapon_hmg, ammo_hmg, WEP_HLAC)
  
 -// Mines -> Rockets
 -SPAWNFUNC_WEAPON(weapon_prox_launcher, WEP_MINE_LAYER)
 -SPAWNFUNC_ITEM(ammo_mines, ITEM_Rockets)
 +// Team Arena Nailgun -> Crylink || Quake Nailgun -> Electro
 +SPAWNFUNC_Q3_COND(weapon_nailgun, ammo_nails, cvar("sv_mapformat_is_quake3"), WEP_CRYLINK, WEP_ELECTRO)
  
 -// LG -> Lightning
 -SPAWNFUNC_WEAPON(weapon_lightning, WEP_ELECTRO)
 -SPAWNFUNC_ITEM(ammo_lightning, ITEM_Cells)
 +// LG -> Electro
 +SPAWNFUNC_Q3(weapon_lightning, ammo_lightning, WEP_ELECTRO)
  
  // Plasma -> Hagar
 -SPAWNFUNC_WEAPON(weapon_plasmagun, WEP_HAGAR)
 -SPAWNFUNC_ITEM(ammo_cells, ITEM_Rockets)
 +SPAWNFUNC_Q3(weapon_plasmagun, ammo_cells, WEP_HAGAR)
  
  // Rail -> Vortex
 -SPAWNFUNC_WEAPON(weapon_railgun, WEP_VORTEX)
 -SPAWNFUNC_ITEM(ammo_slugs, ITEM_Cells)
 +SPAWNFUNC_Q3(weapon_railgun, ammo_slugs, WEP_VORTEX)
  
 -// BFG -> Crylink
 -SPAWNFUNC_WEAPON(weapon_bfg, WEP_CRYLINK)
 -SPAWNFUNC_ITEM(ammo_bfg, ITEM_Cells)
 +// BFG -> Crylink || Fireball
 +SPAWNFUNC_Q3_COND(weapon_bfg, ammo_bfg, cvar_string("g_mod_balance") == "XDF", WEP_CRYLINK, WEP_FIREBALL)
 +      // FIXME: WEP_FIREBALL has no ammo_type field so ammo_bfg is deleted by SPAWNFUNC_BODY
  
  // grappling hook -> hook
  SPAWNFUNC_WEAPON(weapon_grapplinghook, WEP_HOOK)
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge