]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Merge branch 'master' into terencehill/ca_ft_fixes
authorterencehill <piuntn@gmail.com>
Mon, 16 Sep 2013 09:40:02 +0000 (11:40 +0200)
committerterencehill <piuntn@gmail.com>
Mon, 16 Sep 2013 09:40:02 +0000 (11:40 +0200)
Conflicts:
gamemodes.cfg
qcsrc/server/mutators/gamemode_ca.qc
qcsrc/server/mutators/gamemode_lms.qc

1  2 
gamemodes.cfg
qcsrc/server/autocvars.qh
qcsrc/server/cl_impulse.qc
qcsrc/server/g_world.qc
qcsrc/server/mutators/gamemode_arena.qc
qcsrc/server/mutators/gamemode_ca.qc
qcsrc/server/mutators/gamemode_freezetag.qc
qcsrc/server/mutators/gamemode_lms.qc
qcsrc/server/teamplay.qc

diff --cc gamemodes.cfg
index 2b032f773f7ceeb17361678a0d41227cd154fb23,665fa558490b75fac0e554e8f8badc87cc00e218..7d1194f0a4d64c89430f31f8680eb2d283bad42d
@@@ -279,7 -278,9 +279,9 @@@ seta g_freezetag_point_leadlimit -1        "Fr
  set g_freezetag_revive_speed 0.4 "Speed for reviving a frozen teammate"
  set g_freezetag_revive_clearspeed 1.6 "Speed at which reviving progress gets lost when out of range"
  set g_freezetag_revive_extra_size 100 "Distance in qu that you can stand from a frozen teammate to keep reviving him"
 -set g_freezetag_round_timelimit 180
+ set g_freezetag_revive_falldamage 0 "Enable reviving from this amount of fall damage"
+ set g_freezetag_revive_falldamage_health 40 "Amount of health player has if they revived from falling"
 +set g_freezetag_round_timelimit 180 "round time limit in seconds"
  set g_freezetag_frozen_force 0.6 "How much to multiply the force on a frozen player with"
  set g_freezetag_frozen_maxtime 60 "frozen players will be automatically unfrozen after this time in seconds"
  seta g_freezetag_teams_override 0
Simple merge
Simple merge
Simple merge
index 457654a5722fd4f488e678ce30f31a605b56da09,f55c46e00ad5e34468bdfaae2e614227e7702aba..0a89494a21735a5d5995ed9106e2afb6c66f05c1
@@@ -222,18 -224,67 +222,52 @@@ MUTATOR_HOOKFUNCTION(ca_GiveFragsForKil
  
  MUTATOR_HOOKFUNCTION(ca_SetStartItems)
  {
-       start_items &~= IT_UNLIMITED_AMMO;
 -      start_health = cvar("g_lms_start_health");
 -      start_armorvalue = cvar("g_lms_start_armor");
 -
 -      start_ammo_shells = cvar("g_lms_start_ammo_shells");
 -      start_ammo_nails = cvar("g_lms_start_ammo_nails");
 -      start_ammo_rockets = cvar("g_lms_start_ammo_rockets");
 -      start_ammo_cells = cvar("g_lms_start_ammo_cells");
 -      start_ammo_fuel = cvar("g_lms_start_ammo_fuel");
 -      
+       start_items &= ~IT_UNLIMITED_AMMO;
 +      start_health       = warmup_start_health       = cvar("g_lms_start_health");
 +      start_armorvalue   = warmup_start_armorvalue   = cvar("g_lms_start_armor");
 +      start_ammo_shells  = warmup_start_ammo_shells  = cvar("g_lms_start_ammo_shells");
 +      start_ammo_nails   = warmup_start_ammo_nails   = cvar("g_lms_start_ammo_nails");
 +      start_ammo_rockets = warmup_start_ammo_rockets = cvar("g_lms_start_ammo_rockets");
 +      start_ammo_cells   = warmup_start_ammo_cells   = cvar("g_lms_start_ammo_cells");
 +      start_ammo_fuel    = warmup_start_ammo_fuel    = cvar("g_lms_start_ammo_fuel");
  
        return 0;
  }
  
 -// scoreboard setup
 -void ca_ScoreRules()
 -{
 -      ScoreRules_basics(2, SFL_SORT_PRIO_PRIMARY, 0, TRUE);
 -      ScoreInfo_SetLabel_TeamScore  (ST_CA_ROUNDS,    "rounds",    SFL_SORT_PRIO_PRIMARY);
 -      ScoreRules_basics_end();
 -}
 -
 -void ca_DelayedInit() // Do this check with a delay so we can wait for teams to be set up.
 -{
 -      ca_ScoreRules();
 -}
 -
+ MUTATOR_HOOKFUNCTION(ca_PlayerDamage)
+ {
+       if(IS_PLAYER(frag_target))
+       if(frag_target.deadflag == DEAD_NO)
+       if(frag_target == frag_attacker || SAME_TEAM(frag_target, frag_attacker) || frag_deathtype == DEATH_FALL)
+               frag_damage = 0;
+               
+       frag_mirrordamage = 0;
+               
+       return FALSE;
+ }
+ MUTATOR_HOOKFUNCTION(ca_FilterItem)
+ {
+       if(autocvar_g_powerups <= 0)
+       if(self.flags & FL_POWERUP)
+               return TRUE;
+               
+       if(autocvar_g_pickup_items <= 0)
+               return TRUE;
+               
+       return FALSE;
+ }
+ MUTATOR_HOOKFUNCTION(ca_PlayerDamage_SplitHealthArmor)
+ {
+       float excess = max(0, frag_damage - damage_take - damage_save);
+       
+       if(frag_target != frag_attacker && IS_PLAYER(frag_attacker))
+               PlayerTeamScore_Add(frag_attacker, SP_SCORE, ST_SCORE, (frag_damage - excess) * autocvar_g_ca_damage2score_multiplier);
+               
+       return FALSE;
+ }
  void ca_Initialize()
  {
        allowed_to_spawn = TRUE;
index 1684c998863990fe8229eae6b8b77fa5ffaf56b7,f980607a7e5b71c2332707d07fc5827b4cd9633d..850b4e21e261598300d624f31f218d68cd6e2f72
@@@ -173,14 -121,14 +121,14 @@@ MUTATOR_HOOKFUNCTION(lms_GiveFragsForKi
  
  MUTATOR_HOOKFUNCTION(lms_SetStartItems)
  {
-       start_items &~= IT_UNLIMITED_AMMO;
+       start_items &= ~IT_UNLIMITED_AMMO;
 -      start_ammo_shells = cvar("g_lms_start_ammo_shells");
 -      start_ammo_nails = cvar("g_lms_start_ammo_nails");
 -      start_ammo_rockets = cvar("g_lms_start_ammo_rockets");
 -      start_ammo_cells = cvar("g_lms_start_ammo_cells");
 -      start_ammo_fuel = cvar("g_lms_start_ammo_fuel");
 -      start_health = cvar("g_lms_start_health");
 -      start_armorvalue = cvar("g_lms_start_armor");
 +      start_health       = warmup_start_health       = cvar("g_lms_start_health");
 +      start_armorvalue   = warmup_start_armorvalue   = cvar("g_lms_start_armor");
 +      start_ammo_shells  = warmup_start_ammo_shells  = cvar("g_lms_start_ammo_shells");
 +      start_ammo_nails   = warmup_start_ammo_nails   = cvar("g_lms_start_ammo_nails");
 +      start_ammo_rockets = warmup_start_ammo_rockets = cvar("g_lms_start_ammo_rockets");
 +      start_ammo_cells   = warmup_start_ammo_cells   = cvar("g_lms_start_ammo_cells");
 +      start_ammo_fuel    = warmup_start_ammo_fuel    = cvar("g_lms_start_ammo_fuel");
  
        return FALSE;
  }
Simple merge