From 5b38431cdd9c86a4a7b7ece03a9fe73042670277 Mon Sep 17 00:00:00 2001 From: Mario Date: Sun, 25 Dec 2016 21:59:50 +1000 Subject: [PATCH] Add rudimentary support for World of Padman map entities, by Gnom --- qcsrc/server/compat/_mod.inc | 1 + qcsrc/server/compat/_mod.qh | 1 + qcsrc/server/compat/wop.qc | 60 +++++++++++++++++++ qcsrc/server/compat/wop.qh | 1 + qcsrc/server/mutators/mutator/gamemode_ctf.qc | 8 +++ 5 files changed, 71 insertions(+) create mode 100644 qcsrc/server/compat/wop.qc create mode 100644 qcsrc/server/compat/wop.qh diff --git a/qcsrc/server/compat/_mod.inc b/qcsrc/server/compat/_mod.inc index c8c941a0c..69d031eaf 100644 --- a/qcsrc/server/compat/_mod.inc +++ b/qcsrc/server/compat/_mod.inc @@ -2,3 +2,4 @@ #include #include #include +#include diff --git a/qcsrc/server/compat/_mod.qh b/qcsrc/server/compat/_mod.qh index 5c9b5914f..bd658580e 100644 --- a/qcsrc/server/compat/_mod.qh +++ b/qcsrc/server/compat/_mod.qh @@ -2,3 +2,4 @@ #include #include #include +#include diff --git a/qcsrc/server/compat/wop.qc b/qcsrc/server/compat/wop.qc new file mode 100644 index 000000000..7c27cf445 --- /dev/null +++ b/qcsrc/server/compat/wop.qc @@ -0,0 +1,60 @@ +#include "wop.qh" + +#include +// #include + +spawnfunc(weapon_arc); +spawnfunc(weapon_crylink); +spawnfunc(weapon_electro); +spawnfunc(weapon_mortar); +spawnfunc(weapon_hagar); +spawnfunc(weapon_machinegun); +spawnfunc(weapon_devastator); +spawnfunc(weapon_shotgun); +spawnfunc(weapon_vortex); + +spawnfunc(item_armor_big); +spawnfunc(item_armor_mega); +spawnfunc(item_armor_small); + +spawnfunc(item_bullets); +spawnfunc(item_cells); +spawnfunc(item_quad); +spawnfunc(item_rockets); +spawnfunc(item_shells); + +spawnfunc(item_haste); +spawnfunc(item_health_medium); +spawnfunc(item_health_mega); +spawnfunc(item_invis); +spawnfunc(item_medic); + +//*********************** +//WORD OF PADMAN ENTITIES - So people can play wop maps with the xonotic weapons +//*********************** + +spawnfunc(weapon_punchy) { spawnfunc_weapon_arc(this); } +spawnfunc(weapon_nipper) { spawnfunc_weapon_machinegun(this); } +spawnfunc(weapon_pumper) { spawnfunc_weapon_shotgun(this); } +spawnfunc(weapon_boaster) { spawnfunc_weapon_electro(this); } +spawnfunc(weapon_splasher) { spawnfunc_weapon_vortex(this); } +spawnfunc(weapon_bubbleg) { spawnfunc_weapon_hagar(this); } +spawnfunc(weapon_balloony) { spawnfunc_weapon_mortar(this); } +spawnfunc(weapon_betty) { spawnfunc_weapon_devastator(this); } +spawnfunc(weapon_imperius) { spawnfunc_weapon_crylink(this); } + +spawnfunc(ammo_pumper) { spawnfunc_item_shells(this); } +spawnfunc(ammo_nipper) { spawnfunc_item_bullets(this); } +spawnfunc(ammo_balloony) { spawnfunc_item_rockets(this); } +spawnfunc(ammo_bubbleg) { spawnfunc_item_rockets(this); } +spawnfunc(ammo_boaster) { spawnfunc_item_cells(this); } +spawnfunc(ammo_betty) { spawnfunc_item_rockets(this); } +spawnfunc(ammo_imperius) { spawnfunc_item_cells(this); } + +spawnfunc(item_padpower) { spawnfunc_item_quad(this); } +spawnfunc(item_climber) { spawnfunc_item_invincible(this); } +spawnfunc(item_speedy) { spawnfunc_item_haste(this); } +spawnfunc(item_jump) { spawnfunc_item_flight(this); } +spawnfunc(item_visionless) { spawnfunc_item_invis(this); } +spawnfunc(item_revival) { spawnfunc_item_medic(this); } +spawnfunc(item_armor_padshield) { spawnfunc_item_armor_mega(this); } diff --git a/qcsrc/server/compat/wop.qh b/qcsrc/server/compat/wop.qh new file mode 100644 index 000000000..6f70f09be --- /dev/null +++ b/qcsrc/server/compat/wop.qh @@ -0,0 +1 @@ +#pragma once diff --git a/qcsrc/server/mutators/mutator/gamemode_ctf.qc b/qcsrc/server/mutators/mutator/gamemode_ctf.qc index 27fd46b88..d1c97bd28 100644 --- a/qcsrc/server/mutators/mutator/gamemode_ctf.qc +++ b/qcsrc/server/mutators/mutator/gamemode_ctf.qc @@ -2592,6 +2592,14 @@ spawnfunc(team_CTF_bluespawn) { spawnfunc_info_player_team2(this); } spawnfunc(team_CTF_neutralflag) { spawnfunc_item_flag_neutral(this); } spawnfunc(team_neutralobelisk) { spawnfunc_item_flag_neutral(this); } +// compatibility for wop maps +spawnfunc(team_redplayer) { spawnfunc_info_player_team1(this); } +spawnfunc(team_blueplayer) { spawnfunc_info_player_team2(this); } +spawnfunc(team_ctl_redlolly) { spawnfunc_item_flag_team1(this); } +spawnfunc(team_CTL_redlolly) { spawnfunc_item_flag_team1(this); } +spawnfunc(team_ctl_bluelolly) { spawnfunc_item_flag_team2(this); } +spawnfunc(team_CTL_bluelolly) { spawnfunc_item_flag_team2(this); } + // ============== // Initialization -- 2.39.2