X-Git-Url: http://de.git.xonotic.org/?a=blobdiff_plain;ds=sidebyside;f=qcsrc%2Fcommon%2Fweapons%2Fall.qh;h=42805b3a082a64ff988dea1c37497ecc399dc6fe;hb=123b8faad91aa21fb4e87d48f0f776dd77735b2e;hp=beaa6cb48a3773e2555b4817177696242b7b7e43;hpb=81062a39c99785039ceee2dcd187fed9352a08c5;p=xonotic%2Fxonotic-data.pk3dir.git diff --git a/qcsrc/common/weapons/all.qh b/qcsrc/common/weapons/all.qh index beaa6cb48..42805b3a0 100644 --- a/qcsrc/common/weapons/all.qh +++ b/qcsrc/common/weapons/all.qh @@ -130,7 +130,7 @@ REGISTER_WEAPON(Null, NEW(Weapon)); Weapon Weapons_fromstr(string s) { FOREACH(Weapons, it != WEP_Null && it.netname == s, return it); - return NULL; + return WEP_Null; } @@ -144,9 +144,9 @@ X(weaponstart, float) X(weaponthrowable, float) #ifdef SVQC X(reload_ammo, float) -.float reloading_ammo = reload_ammo; +const .float reloading_ammo = reload_ammo; X(reload_time, float) -.float reloading_time = reload_time; +const .float reloading_time = reload_time; #endif #undef X @@ -304,7 +304,6 @@ STATIC_INIT(register_weapons_done) WepSet set = it.m_wepset = _WepSet_FromWeapon(it.m_id = i); WEPSET_ALL |= set; if ((it.spawnflags) & WEP_FLAG_SUPERWEAPON) WEPSET_SUPERWEAPONS |= set; - it.weapons = set; if (it == WEP_Null) continue; int imp = WEP_IMPULSE_BEGIN + it.m_id - 1; if (imp <= WEP_IMPULSE_END) @@ -359,6 +358,17 @@ ENUMCLASS_END(WFRAME) .WFRAME wframe; +#ifdef SVQC + #define G_SHOOTFROMFIXEDORIGIN autocvar_g_shootfromfixedorigin +#elif defined(CSQC) + string autocvar_cl_shootfromfixedorigin; + #define G_SHOOTFROMFIXEDORIGIN autocvar_cl_shootfromfixedorigin +#endif + vector shotorg_adjust_values(vector vecs, bool y_is_right, bool visual, int algn); void CL_WeaponEntity_SetModel(entity this, string name, bool _anim); + +#ifdef SVQC +void wframe_send(entity actor, entity weaponentity, vector a, bool restartanim); +#endif #endif