]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/server/weapons/weaponsystem.qc
Remove the g_ prefix from some server code files and rename sv_main to main
[xonotic/xonotic-data.pk3dir.git] / qcsrc / server / weapons / weaponsystem.qc
index 5f4f6f8332deb1d0b4d171c31a839922b4267bd3..7638813882d306ca3e67544c10290ed80231d866 100644 (file)
@@ -3,14 +3,19 @@
 #include "selection.qh"
 
 #include "../command/common.qh"
+#include <server/client.qh>
+#include <server/damage.qh>
+#include <server/world.qh>
+#include <server/items/items.qh>
 #include <server/mutators/_mod.qh>
 #include "../round_handler.qh"
 #include <server/cheats.qh>
 #include <server/resources.qh>
-#include <common/t_items.qh>
 #include <common/animdecide.qh>
 #include <common/constants.qh>
+#include <common/items/_mod.qh>
 #include <common/net_linked.qh>
+#include <common/mapobjects/platforms.qh>
 #include <common/monsters/_mod.qh>
 #include <common/notifications/all.qh>
 #include <common/util.qh>
@@ -55,7 +60,7 @@ bool CL_Weaponentity_CustomizeEntityForClient(entity this, entity client)
 
 vector CL_Weapon_GetShotOrg(int wpn)
 {
-       entity wi = Weapons_from(wpn);
+       entity wi = REGISTRY_GET(Weapons, wpn);
        entity e = spawn();
        CL_WeaponEntity_SetModel(e, wi.mdl, false);
        vector ret = e.movedir;
@@ -846,7 +851,7 @@ void W_Reload(entity actor, .entity weaponentity, float sent_ammo_min, Sound sen
 
 void W_DropEvent(.void(Weapon, entity actor, .entity) event, entity player, float weapon_type, entity weapon_item, .entity weaponentity)
 {
-       Weapon w = Weapons_from(weapon_type);
+       Weapon w = REGISTRY_GET(Weapons, weapon_type);
        weapon_dropevent_item = weapon_item;
        w.event(w, player, weaponentity);
 }