From: samual Date: Thu, 20 May 2010 20:42:57 +0000 (-0400) Subject: Added g_pickup__anyway to health/armor items (todo: add ammo), added defaultSam... X-Git-Tag: xonotic-v0.1.0preview~592 X-Git-Url: http://de.git.xonotic.org/?p=xonotic%2Fxonotic-data.pk3dir.git;a=commitdiff_plain;h=667c2bd61b3d37ca1051df895921a8e02cf8d980 Added g_pickup__anyway to health/armor items (todo: add ammo), added defaultSamual.cfg, minor changes to balanceSamual.cfg and physicsSamual.cfg --- diff --git a/balance.cfg b/balance.cfg index cdb8170809..d8c62d1c18 100644 --- a/balance.cfg +++ b/balance.cfg @@ -65,20 +65,28 @@ set g_pickup_fuel_jetpack 50 set g_pickup_fuel_max 999 set g_pickup_armorsmall 10 set g_pickup_armorsmall_max 100 +set g_pickup_armorsmall_anyway 0 set g_pickup_armormedium 25 set g_pickup_armormedium_max 100 +set g_pickup_armormedium_anyway 0 set g_pickup_armorbig 50 set g_pickup_armorbig_max 100 +set g_pickup_armorbig_anyway 0 set g_pickup_armorlarge 100 set g_pickup_armorlarge_max 100 +set g_pickup_armorlarge_anyway 0 set g_pickup_healthsmall 10 set g_pickup_healthsmall_max 200 +set g_pickup_healthsmall_anyway 0 set g_pickup_healthmedium 25 set g_pickup_healthmedium_max 200 +set g_pickup_healthmedium_anyway 0 set g_pickup_healthlarge 50 set g_pickup_healthlarge_max 200 +set g_pickup_healthlarge_anyway 0 set g_pickup_healthmega 100 set g_pickup_healthmega_max 200 +set g_pickup_healthmega_anyway 0 set g_pickup_respawntime_short 15 set g_pickup_respawntime_medium 20 set g_pickup_respawntime_long 30 diff --git a/balance25.cfg b/balance25.cfg index 7c1fa180c1..db772801e7 100644 --- a/balance25.cfg +++ b/balance25.cfg @@ -65,20 +65,28 @@ set g_pickup_fuel_jetpack 50 set g_pickup_fuel_max 999 set g_pickup_armorsmall 5 set g_pickup_armorsmall_max 999 +set g_pickup_armorsmall_anyway 0 set g_pickup_armormedium 25 set g_pickup_armormedium_max 999 +set g_pickup_armormedium_anyway 0 set g_pickup_armorbig 50 set g_pickup_armorbig_max 999 +set g_pickup_armorbig_anyway 0 set g_pickup_armorlarge 100 set g_pickup_armorlarge_max 999 +set g_pickup_armorlarge_anyway 0 set g_pickup_healthsmall 5 set g_pickup_healthsmall_max 999 +set g_pickup_healthsmall_anyway 0 set g_pickup_healthmedium 25 set g_pickup_healthmedium_max 999 +set g_pickup_healthmedium_anyway 0 set g_pickup_healthlarge 50 set g_pickup_healthlarge_max 999 +set g_pickup_healthlarge_anyway 0 set g_pickup_healthmega 100 set g_pickup_healthmega_max 999 +set g_pickup_healthmega_anyway 0 set g_pickup_respawntime_short 15 set g_pickup_respawntime_medium 20 set g_pickup_respawntime_long 30 diff --git a/balanceSamual.cfg b/balanceSamual.cfg index a8cd085705..e08c608a46 100644 --- a/balanceSamual.cfg +++ b/balanceSamual.cfg @@ -16,7 +16,7 @@ set g_start_weapon_campingrifle -1 "0 = never provide the weapon, 1 = always pro set g_start_weapon_tuba -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default, -2 = provide the weapon in ca and lms" set g_start_weapon_fireball 0 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default, -2 = provide the weapon in ca and lms" set g_start_weapon_seeker 0 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default, -2 = provide the weapon in ca and lms" -set g_balance_health_start 100 +set g_balance_health_start 125 set g_balance_armor_start 0 set g_start_ammo_shells 30 set g_start_ammo_nails 0 @@ -65,20 +65,28 @@ set g_pickup_fuel_jetpack 50 set g_pickup_fuel_max 999 set g_pickup_armorsmall 10 set g_pickup_armorsmall_max 200 +set g_pickup_armorsmall_anyway 1 set g_pickup_armormedium 25 set g_pickup_armormedium_max 200 +set g_pickup_armormedium_anyway 1 set g_pickup_armorbig 50 set g_pickup_armorbig_max 200 +set g_pickup_armorbig_anyway 1 set g_pickup_armorlarge 100 set g_pickup_armorlarge_max 200 +set g_pickup_armorlarge_anyway 1 set g_pickup_healthsmall 10 set g_pickup_healthsmall_max 200 +set g_pickup_healthsmall_anyway 1 set g_pickup_healthmedium 25 set g_pickup_healthmedium_max 200 +set g_pickup_healthmedium_anyway 1 set g_pickup_healthlarge 50 set g_pickup_healthlarge_max 200 +set g_pickup_healthlarge_anyway 1 set g_pickup_healthmega 100 set g_pickup_healthmega_max 200 +set g_pickup_healthmega_anyway 1 set g_pickup_respawntime_short 15 set g_pickup_respawntime_medium 20 set g_pickup_respawntime_long 30 @@ -108,13 +116,13 @@ set g_balance_health_limit 999 set g_balance_armor_regen 0 set g_balance_armor_regenlinear 3 set g_balance_armor_rot 0 -set g_balance_armor_rotlinear 0 +set g_balance_armor_rotlinear 3 set g_balance_pause_armor_rot 1 set g_balance_pause_armor_rot_spawn 1 set g_balance_armor_regenstable 100 set g_balance_armor_rotstable 100 set g_balance_armor_limit 999 -set g_balance_armor_blockpercent 0.5 +set g_balance_armor_blockpercent 0.6 set g_balance_fuel_regen 0.1 "fuel regeneration (only applies if the player owns IT_FUEL_REGEN)" set g_balance_fuel_regenlinear 0 set g_balance_pause_fuel_regen 2 // other than this, fuel uses the health regen counter @@ -128,7 +136,7 @@ set g_balance_fuel_limit 999 // }}} // {{{ misc -set g_balance_selfdamagepercent 0.6 +set g_balance_selfdamagepercent 0.75 set g_balance_weaponswitchdelay 0.15 set g_weaponspeedfactor 1 "weapon projectile speed multiplier" set g_weaponratefactor 1 "weapon fire rate multiplier" diff --git a/balanceXPM.cfg b/balanceXPM.cfg index e47e1a8858..faf5d24728 100644 --- a/balanceXPM.cfg +++ b/balanceXPM.cfg @@ -65,20 +65,28 @@ set g_pickup_fuel_jetpack 50 set g_pickup_fuel_max 999 set g_pickup_armorsmall 5 set g_pickup_armorsmall_max 200 +set g_pickup_armorsmall_anyway 0 set g_pickup_armormedium 25 set g_pickup_armormedium_max 200 +set g_pickup_armormedium_anyway 0 set g_pickup_armorbig 50 set g_pickup_armorbig_max 200 +set g_pickup_armorbig_anyway 0 set g_pickup_armorlarge 100 set g_pickup_armorlarge_max 200 +set g_pickup_armorlarge_anyway 0 set g_pickup_healthsmall 5 set g_pickup_healthsmall_max 200 +set g_pickup_healthsmall_anyway 0 set g_pickup_healthmedium 25 set g_pickup_healthmedium_max 100 +set g_pickup_healthmedium_anyway 0 set g_pickup_healthlarge 50 set g_pickup_healthlarge_max 100 +set g_pickup_healthlarge_anyway 0 set g_pickup_healthmega 100 set g_pickup_healthmega_max 200 +set g_pickup_healthmega_anyway 0 set g_pickup_respawntime_short 30 set g_pickup_respawntime_medium 30 set g_pickup_respawntime_long 30 diff --git a/defaultSamual.cfg b/defaultSamual.cfg new file mode 100644 index 0000000000..c0dce41e13 --- /dev/null +++ b/defaultSamual.cfg @@ -0,0 +1,31 @@ +// Samual's mod configuration file +exec defaultXonotic.cfg + +// weapon replace options +set g_weaponreplace_laser "" +set g_weaponreplace_shotgun "" +set g_weaponreplace_uzi "" +set g_weaponreplace_grenadelauncher "" +set g_weaponreplace_electro "" +set g_weaponreplace_crylink "" +set g_weaponreplace_nex "" +set g_weaponreplace_hagar "" +set g_weaponreplace_rocketlauncher "" +set g_weaponreplace_porto "" +set g_weaponreplace_minstanex "" +set g_weaponreplace_hook "" +set g_weaponreplace_hlac 0 // Maybe will be enabled later after I figure out what I want to do with it +set g_weaponreplace_campingrifle "" +set g_weaponreplace_tuba "" +set g_weaponreplace_fireball 0 // Same with this +set g_weaponreplace_seeker 0 // Same with this +set sv_q3acompat_machineshotgunswap 0 + +// other options +set sv_fragmessage_information_ping 1 +set sv_fragmessage_information_handicap 2 +set sv_fragmessage_information_stats 1 +set sv_fragmessage_information_typefrag 1 + +exec physicsSamual.cfg +exec balanceSamual.cfg diff --git a/physicsSamual.cfg b/physicsSamual.cfg index 3631c8011f..9a3f1e113c 100644 --- a/physicsSamual.cfg +++ b/physicsSamual.cfg @@ -1,13 +1,14 @@ -sv_gravity 880 +// Mix of 2.3 physics and NANL physics, goal of going for faster movement +sv_gravity 800 sv_maxspeed 420 sv_maxairspeed 235 sv_stopspeed 200 sv_accelerate 6 sv_airaccelerate 6 sv_friction 4 -edgefriction 0 +edgefriction 1 sv_stepheight 34 -sv_jumpvelocity 330 +sv_jumpvelocity 300 sv_wateraccelerate -1 sv_waterfriction -1 sv_airaccel_sideways_friction 0.3 diff --git a/qcsrc/server/miscfunctions.qc b/qcsrc/server/miscfunctions.qc index 22f5458309..ebb3ee1444 100644 --- a/qcsrc/server/miscfunctions.qc +++ b/qcsrc/server/miscfunctions.qc @@ -825,20 +825,28 @@ float g_pickup_fuel_jetpack; float g_pickup_fuel_max; float g_pickup_armorsmall; float g_pickup_armorsmall_max; +float g_pickup_armorsmall_anyway; float g_pickup_armormedium; float g_pickup_armormedium_max; +float g_pickup_armormedium_anyway; float g_pickup_armorbig; float g_pickup_armorbig_max; +float g_pickup_armorbig_anyway; float g_pickup_armorlarge; float g_pickup_armorlarge_max; +float g_pickup_armorlarge_anyway; float g_pickup_healthsmall; float g_pickup_healthsmall_max; +float g_pickup_healthsmall_anyway; float g_pickup_healthmedium; float g_pickup_healthmedium_max; +float g_pickup_healthmedium_anyway; float g_pickup_healthlarge; float g_pickup_healthlarge_max; +float g_pickup_healthlarge_anyway; float g_pickup_healthmega; float g_pickup_healthmega_max; +float g_pickup_healthmega_anyway; float g_weaponarena; float g_weaponarena_random; string g_weaponarena_list; @@ -1262,20 +1270,28 @@ void readlevelcvars(void) g_pickup_fuel_max = cvar("g_pickup_fuel_max"); g_pickup_armorsmall = cvar("g_pickup_armorsmall"); g_pickup_armorsmall_max = cvar("g_pickup_armorsmall_max"); + g_pickup_armorsmall_anyway = cvar("g_pickup_armorsmall_anyway"); g_pickup_armormedium = cvar("g_pickup_armormedium"); g_pickup_armormedium_max = cvar("g_pickup_armormedium_max"); + g_pickup_armormedium_anyway = cvar("g_pickup_armormedium_anyway"); g_pickup_armorbig = cvar("g_pickup_armorbig"); g_pickup_armorbig_max = cvar("g_pickup_armorbig_max"); + g_pickup_armorbig_anyway = cvar("g_pickup_armorbig_anyway"); g_pickup_armorlarge = cvar("g_pickup_armorlarge"); g_pickup_armorlarge_max = cvar("g_pickup_armorlarge_max"); + g_pickup_armorlarge_anyway = cvar("g_pickup_armorlarge_anyway"); g_pickup_healthsmall = cvar("g_pickup_healthsmall"); g_pickup_healthsmall_max = cvar("g_pickup_healthsmall_max"); + g_pickup_healthsmall_anyway = cvar("g_pickup_healthsmall_anyway"); g_pickup_healthmedium = cvar("g_pickup_healthmedium"); g_pickup_healthmedium_max = cvar("g_pickup_healthmedium_max"); + g_pickup_healthmedium_anyway = cvar("g_pickup_healthmedium_anyway"); g_pickup_healthlarge = cvar("g_pickup_healthlarge"); g_pickup_healthlarge_max = cvar("g_pickup_healthlarge_max"); + g_pickup_healthlarge_anyway = cvar("g_pickup_healthlarge_anyway"); g_pickup_healthmega = cvar("g_pickup_healthmega"); g_pickup_healthmega_max = cvar("g_pickup_healthmega_max"); + g_pickup_healthmega_anyway = cvar("g_pickup_healthmega_anyway"); g_pinata = cvar("g_pinata"); diff --git a/qcsrc/server/t_items.qc b/qcsrc/server/t_items.qc index 2801958076..ee56acc9ca 100644 --- a/qcsrc/server/t_items.qc +++ b/qcsrc/server/t_items.qc @@ -40,6 +40,7 @@ string Item_CounterFieldName(float it) } .float max_armorvalue; +.float pickup_anyway; float Item_Customize() { @@ -429,14 +430,14 @@ float Item_GiveTo(entity item, entity player) } if (item.health) - if (player.health < item.max_health) + if ((player.health < item.max_health) || item.pickup_anyway) { pickedup = TRUE; player.health = min(player.health + item.health, item.max_health); player.pauserothealth_finished = max(player.pauserothealth_finished, time + cvar("g_balance_pause_health_rot")); } if (item.armorvalue) - if (player.armorvalue < item.max_armorvalue) + if ((player.armorvalue < item.max_armorvalue) || item.pickup_anyway) { pickedup = TRUE; player.armorvalue = min(player.armorvalue + item.armorvalue, item.max_armorvalue); @@ -1195,6 +1196,8 @@ void spawnfunc_item_armor_small (void) { self.armorvalue = g_pickup_armorsmall; if(!self.max_armorvalue) self.max_armorvalue = g_pickup_armorsmall_max; + if(!self.pickup_anyway) + self.pickup_anyway = g_pickup_armorsmall_anyway; StartItem ("models/items/g_a1.md3", "misc/armor1.wav", g_pickup_respawntime_short, g_pickup_respawntimejitter_short, "5 Armor", IT_ARMOR_SHARD, 0, 0, commodity_pickupevalfunc, BOT_PICKUP_RATING_LOW); } @@ -1203,6 +1206,8 @@ void spawnfunc_item_armor_medium (void) { self.armorvalue = g_pickup_armormedium; if(!self.max_armorvalue) self.max_armorvalue = g_pickup_armormedium_max; + if(!self.pickup_anyway) + self.pickup_anyway = g_pickup_armormedium_anyway; StartItem ("models/items/g_armormedium.md3", "misc/armor10.wav", g_pickup_respawntime_medium, g_pickup_respawntimejitter_medium, "25 Armor", IT_ARMOR, 0, 0, commodity_pickupevalfunc, BOT_PICKUP_RATING_MID); } @@ -1211,6 +1216,8 @@ void spawnfunc_item_armor_big (void) { self.armorvalue = g_pickup_armorbig; if(!self.max_armorvalue) self.max_armorvalue = g_pickup_armorbig_max; + if(!self.pickup_anyway) + self.pickup_anyway = g_pickup_armorbig_anyway; StartItem ("models/items/g_a50.md3", "misc/armor17_5.wav", g_pickup_respawntime_long, g_pickup_respawntimejitter_long, "50 Armor", IT_ARMOR, 0, 0, commodity_pickupevalfunc, 20000); } @@ -1219,6 +1226,8 @@ void spawnfunc_item_armor_large (void) { self.armorvalue = g_pickup_armorlarge; if(!self.max_armorvalue) self.max_armorvalue = g_pickup_armorlarge_max; + if(!self.pickup_anyway) + self.pickup_anyway = g_pickup_armorlarge_anyway; StartItem ("models/items/g_a25.md3", "misc/armor25.wav", g_pickup_respawntime_long, g_pickup_respawntimejitter_long, "100 Armor", IT_ARMOR, 0, 0, commodity_pickupevalfunc, BOT_PICKUP_RATING_HIGH); } @@ -1227,6 +1236,8 @@ void spawnfunc_item_health_small (void) { self.max_health = g_pickup_healthsmall_max; if(!self.health) self.health = g_pickup_healthsmall; + if(!self.pickup_anyway) + self.pickup_anyway = g_pickup_healthsmall_anyway; StartItem ("models/items/g_h1.md3", "misc/minihealth.wav", g_pickup_respawntime_short, g_pickup_respawntimejitter_short, "5 Health", IT_5HP, 0, 0, commodity_pickupevalfunc, BOT_PICKUP_RATING_LOW); } @@ -1235,6 +1246,8 @@ void spawnfunc_item_health_medium (void) { self.max_health = g_pickup_healthmedium_max; if(!self.health) self.health = g_pickup_healthmedium; + if(!self.pickup_anyway) + self.pickup_anyway = g_pickup_healthmedium_anyway; StartItem ("models/items/g_h25.md3", "misc/mediumhealth.wav", g_pickup_respawntime_short, g_pickup_respawntimejitter_short, "25 Health", IT_25HP, 0, 0, commodity_pickupevalfunc, BOT_PICKUP_RATING_MID); } @@ -1243,6 +1256,8 @@ void spawnfunc_item_health_large (void) { self.max_health = g_pickup_healthlarge_max; if(!self.health) self.health = g_pickup_healthlarge; + if(!self.pickup_anyway) + self.pickup_anyway = g_pickup_healthlarge_anyway; StartItem ("models/items/g_h50.md3", "misc/mediumhealth.wav", g_pickup_respawntime_medium, g_pickup_respawntimejitter_medium, "50 Health", IT_25HP, 0, 0, commodity_pickupevalfunc, BOT_PICKUP_RATING_MID); } @@ -1260,6 +1275,8 @@ void spawnfunc_item_health_mega (void) { self.max_health = g_pickup_healthmega_max; if(!self.health) self.health = g_pickup_healthmega; + if(!self.pickup_anyway) + self.pickup_anyway = g_pickup_healthmega_anyway; StartItem ("models/items/g_h100.md3", "misc/megahealth.wav", g_pickup_respawntime_long, g_pickup_respawntimejitter_long, "100 Health", IT_HEALTH, 0, 0, commodity_pickupevalfunc, BOT_PICKUP_RATING_HIGH); } }