if (self.traileffect)
{
particles_alphamin = particles_alphamax = particles_fade = sqrt(self.alpha);
- boxparticles(particleeffectnum(effects_ent[self.traileffect]), self, from, to, self.velocity, self.velocity, 1, PARTICLES_USEALPHA | PARTICLES_USEFADE | PARTICLES_DRAWASTRAIL);
+ boxparticles(particleeffectnum(Effects[self.traileffect]), self, from, to, self.velocity, self.velocity, 1, PARTICLES_USEALPHA | PARTICLES_USEFADE | PARTICLES_DRAWASTRAIL);
}
}
#include "../teams.qh"
#include "../util.qh"
-REGISTRY(Buffs, 16)
+REGISTRY(Buffs, BIT(4))
REGISTER_REGISTRY(RegisterBuffs)
#define REGISTER_BUFF(id) \
- REGISTER(RegisterBuffs, BUFF, Buffs, Buffs_COUNT, id, m_id, NEW(Buff)); \
+ REGISTER(RegisterBuffs, BUFF, Buffs, id, m_id, NEW(Buff)); \
REGISTER_INIT_POST(BUFF, id) { \
this.netname = this.m_name; \
this.m_itemid = BIT(this.m_id - 1); \
}
-void RegisterEffectInfo();
-const int MAX_EFFECTINFOS = 512;
-entity EFFECTINFOS[MAX_EFFECTINFOS], EFFECTINFOS_first, EFFECTINFOS_last;
-int EFFECTINFOS_COUNT;
-
+REGISTRY(EffectInfos, BIT(9))
+REGISTER_REGISTRY(RegisterEffectInfos)
#define EFFECTINFO(name) \
[[accumulate]] void effectinfo_##name(EffectInfoGroup parent, EffectInfo this) { } \
- REGISTER(RegisterEffectInfo, EFFECTINFO, EFFECTINFOS, EFFECTINFOS_COUNT, name, m_id, NEW(EffectInfoGroup)) { \
+ REGISTER(RegisterEffectInfos, EFFECTINFO, EffectInfos, name, m_id, NEW(EffectInfoGroup)) { \
effectinfo_##name(this, NULL); \
}
-REGISTER_REGISTRY(RegisterEffectInfo)
-
-
-#define REGISTER_EFFECTINFO(id) var void effectinfo_##id(EffectInfoGroup parent)
#define MY(f) this.effectinfo_##f
#define DEF(name) EFFECTINFO(name)
#ifdef CSQC
void Read_Effect(bool is_new)
{
- int net_name = (EFFECT_COUNT >= 255) ? ReadShort() : ReadByte();
+ int net_name = (Effects_COUNT >= 255) ? ReadShort() : ReadByte();
- entity eff = effects_ent[net_name];
+ entity eff = Effects[net_name];
vector v, vel = '0 0 0';
int eff_cnt = 1;
bool Net_Write_Effect(entity this, entity client, int sf)
{
WriteByte(MSG_ENTITY, ENT_CLIENT_EFFECT);
- (EFFECT_COUNT >= 255)
+ (Effects_COUNT >= 255)
? WriteShort(MSG_ENTITY, self.m_id)
: WriteByte(MSG_ENTITY, self.m_id);
WriteCoord(MSG_ENTITY, self.eent_net_location_x);
void Send_Effect_(string eff_name, vector eff_loc, vector eff_vel, int eff_cnt)
{
// problem with this is, we might not have all the available effects for it
- FOREACH(effects_ent, it.eent_eff_name == eff_name, LAMBDA(
+ FOREACH(Effects, it.eent_eff_name == eff_name, LAMBDA(
Send_Effect(it, eff_loc, eff_vel, eff_cnt);
return;
));
#define particleeffectnum(e) _particleeffectnum(e.eent_eff_name)
-void RegisterEffects();
-const int MAX_EFFECTS = 512;
-entity effects_ent[MAX_EFFECTS], effects_ent_first, effects_ent_last;
-int EFFECT_COUNT;
-
-#define EFFECT(istrail, name, realname) \
- REGISTER(RegisterEffects, EFFECT, effects_ent, EFFECT_COUNT, name, m_id, Create_Effect_Entity(realname, istrail));
+REGISTRY(Effects, BIT(8))
REGISTER_REGISTRY(RegisterEffects)
+#define EFFECT(istrail, name, realname) \
+ REGISTER(RegisterEffects, EFFECT, Effects, name, m_id, Create_Effect_Entity(realname, istrail));
.int m_id;
.string eent_eff_name;
#include "item.qh"
-REGISTRY(Items, 24)
+REGISTRY(Items, BIT(5))
REGISTER_REGISTRY(RegisterItems)
/** If you register a new item, make sure to add it to all.inc */
-#define REGISTER_ITEM(id, class) REGISTER(RegisterItems, ITEM, Items, Items_COUNT, id, m_id, NEW(class))
+#define REGISTER_ITEM(id, class) REGISTER(RegisterItems, ITEM, Items, id, m_id, NEW(class))
void Dump_Items();
string _MapInfo_GetDefaultEx(float t)
{
- FOREACH(MAPINFO_TYPES, it.items == t, LAMBDA(return it.model2));
+ FOREACH(Gametypes, it.items == t, LAMBDA(return it.model2));
return "";
}
float _MapInfo_GetTeamPlayBool(float t)
{
- FOREACH(MAPINFO_TYPES, it.items == t, LAMBDA(return it.team));
+ FOREACH(Gametypes, it.items == t, LAMBDA(return it.team));
return false;
}
deprecate(assault, as);
deprecate(race, rc);
if (t == "all") return MAPINFO_TYPE_ALL;
- FOREACH(MAPINFO_TYPES, it.mdl == t, LAMBDA(return it.items));
+ FOREACH(Gametypes, it.mdl == t, LAMBDA(return it.items));
return 0;
#undef deprecate
}
string MapInfo_Type_Description(float t)
{
- FOREACH(MAPINFO_TYPES, it.items == t, LAMBDA(return it.gametype_description));
+ FOREACH(Gametypes, it.items == t, LAMBDA(return it.gametype_description));
return "";
}
{
if(t == MAPINFO_TYPE_ALL)
return "all";
- FOREACH(MAPINFO_TYPES, it.items == t, LAMBDA(return it.mdl));
+ FOREACH(Gametypes, it.items == t, LAMBDA(return it.mdl));
return "";
}
string MapInfo_Type_ToText(float t)
{
- FOREACH(MAPINFO_TYPES, it.items == t, LAMBDA(return it.message));
+ FOREACH(Gametypes, it.items == t, LAMBDA(return it.message));
/* xgettext:no-c-format */
return _("@!#%'n Tuba Throwing");
}
int MapInfo_CurrentGametype()
{
int prev = cvar("gamecfg");
- FOREACH(MAPINFO_TYPES, cvar(it.netname) && it.items != prev, LAMBDA(return it.items));
+ FOREACH(Gametypes, cvar(it.netname) && it.items != prev, LAMBDA(return it.items));
if (prev) return prev;
return MAPINFO_TYPE_DEATHMATCH;
}
void MapInfo_SwitchGameType(int t)
{
- FOREACH(MAPINFO_TYPES, true, LAMBDA(
+ FOREACH(Gametypes, true, LAMBDA(
cvar_set(it.netname, (it.items == t) ? "1" : "0")
));
}
}
ENDCLASS(Gametype)
-void RegisterGametypes();
-const int MAX_MAPINFO_TYPES = 24;
-entity MAPINFO_TYPES[MAX_MAPINFO_TYPES], MAPINFO_TYPES_first, MAPINFO_TYPES_last;
-int MAPINFO_TYPE_COUNT;
+REGISTRY(Gametypes, BIT(4))
+REGISTER_REGISTRY(RegisterGametypes)
int MAPINFO_TYPE_ALL;
-
#define REGISTER_GAMETYPE(hname, sname, g_name, NAME, gteamplay, defaults, gdescription) \
int MAPINFO_TYPE_##NAME; \
- REGISTER(RegisterGametypes, MAPINFO_TYPE, MAPINFO_TYPES, MAPINFO_TYPE_COUNT, g_name, m_id, \
+ REGISTER(RegisterGametypes, MAPINFO_TYPE, Gametypes, g_name, m_id, \
NEW(Gametype, hname, #sname, #g_name, gteamplay, defaults, gdescription) \
) { \
/* same as `1 << m_id` */ \
MAPINFO_TYPE_##NAME = MAPINFO_TYPE_ALL + 1; MAPINFO_TYPE_ALL |= MAPINFO_TYPE_##NAME; \
this.items = MAPINFO_TYPE_##NAME; \
}
-REGISTER_REGISTRY(RegisterGametypes)
#define IS_GAMETYPE(NAME) \
(MapInfo_LoadedGametype == MAPINFO_TYPE_##NAME)
while( (entityvar = findentity(entityvar,owner,active_minigame)) )
-void RegisterMinigames();
-const int MINIGAMES_MAX = 24;
-entity MINIGAMES[MINIGAMES_MAX], MINIGAMES_first, MINIGAMES_last;
-int MINIGAMES_COUNT;
+REGISTRY(Minigames, BIT(3))
+REGISTER_REGISTRY(RegisterMinigames)
#define REGISTER_MINIGAME(name,nicename) \
- REGISTER(RegisterMinigames, MINIGAME, MINIGAMES, MINIGAMES_COUNT, name, m_id, spawn()); \
+ REGISTER(RegisterMinigames, MINIGAME, Minigames, name, m_id, spawn()); \
void name##_hud_board(vector, vector); \
void name##_hud_status(vector, vector); \
int name##_client_event(entity, string, ...); \
this.minigame_event = name##_client_event; \
} \
REGISTER_INIT(MINIGAME, name)
-REGISTER_REGISTRY(RegisterMinigames)
#endif
{
entity curr;
entity prev = self;
- FOREACH(MINIGAMES, true, LAMBDA(
+ FOREACH(Minigames, true, LAMBDA(
{
curr = HUD_MinigameMenu_SpawnSubEntry(
it.message, HUD_MinigameMenu_ClickCreate_Entry, self );
entity minigame_get_descriptor(string id)
{
- FOREACH(MINIGAMES, true, LAMBDA(
+ FOREACH(Minigames, true, LAMBDA(
{
if(it.netname == id)
return it;
}
else if ( minig_cmd == "list" )
{
- FOREACH(MINIGAMES, true, LAMBDA(
+ FOREACH(Minigames, true, LAMBDA(
{
sprint(self,it.netname," (",it.message,") ","\n");
}));
bool minigame_SendEntity(entity this, entity to, int sf);
-void RegisterMinigames();
-const int MINIGAMES_MAX = 24;
-entity MINIGAMES[MINIGAMES_MAX], MINIGAMES_first, MINIGAMES_last;
-int MINIGAMES_COUNT;
+REGISTRY(Minigames, BIT(3))
+REGISTER_REGISTRY(RegisterMinigames)
#define REGISTER_MINIGAME(name,nicename) \
- REGISTER(RegisterMinigames, MINIGAME, MINIGAMES, MINIGAMES_COUNT, name, m_id, spawn()); \
+ REGISTER(RegisterMinigames, MINIGAME, Minigames, name, m_id, spawn()); \
int name##_server_event(entity, string, ...); \
REGISTER_INIT_POST(MINIGAME, name) { \
this.classname = "minigame_descriptor"; \
this.minigame_event = name##_server_event; \
} \
REGISTER_INIT(MINIGAME, name)
-REGISTER_REGISTRY(RegisterMinigames)
#endif
#define setmodel(e, m) _setmodel((e), (m).model_str())
-REGISTRY(Models, 128)
+REGISTRY(Models, BIT(9))
REGISTER_REGISTRY(RegisterModels)
CLASS(Model, Object)
#define MODEL(name, path) \
string MDL_##name##_get() { return path; } \
- REGISTER(RegisterModels, MDL, Models, Models_COUNT, name, m_id, NEW(Model, MDL_##name##_get))
+ REGISTER(RegisterModels, MDL, Models, name, m_id, NEW(Model, MDL_##name##_get))
STATIC_INIT(RegisterModels_precache) {
FOREACH(Models, true, LAMBDA({
#include "monster.qh"
-REGISTRY(Monsters, 24)
+REGISTRY(Monsters, BIT(3))
REGISTER_REGISTRY(RegisterMonsters)
const int MON_FIRST = 1;
#define MON_LAST (Monsters_COUNT - 1)
/** If you register a new monster, make sure to add it to all.inc */
-#define REGISTER_MONSTER(id, inst) REGISTER(RegisterMonsters, MON, Monsters, Monsters_COUNT, id, monsterid, inst)
+#define REGISTER_MONSTER(id, inst) REGISTER(RegisterMonsters, MON, Monsters, id, monsterid, inst)
REGISTER_MONSTER(Null, NEW(Monster));
bool ret = MUTATORFUNCTION_##id##_hooks(mode); if (ret) return ret; \
} \
bool MUTATOR_##id##_check() { return dependence; } \
- REGISTER(RegisterMutators, MUTATOR, MUTATORS, MUTATORS_COUNT, id, m_id, NEW(Mutator, #id, MUTATORFUNCTION_##id)) \
+ REGISTER(RegisterMutators, MUTATOR, MUTATORS, id, m_id, NEW(Mutator, #id, MUTATORFUNCTION_##id)) \
{ this.mutatorcheck = MUTATOR_##id##_check; } \
[[accumulate]] bool MUTATORFUNCTION_##id(int mode)
#include "waypointsprites.qh"
-void RegisterWaypoints();
-const int MAX_WAYPOINTS = 240;
-entity WAYPOINTS[MAX_WAYPOINTS], WAYPOINTS_first, WAYPOINTS_last;
-int WAYPOINT_COUNT;
-/** If you register a new waypoint, make sure to add it to all.inc */
-#define REGISTER_WAYPOINT_(id, init) REGISTER(RegisterWaypoints, WP, WAYPOINTS, WAYPOINT_COUNT, id, m_id, init)
+REGISTRY(Waypoints, BIT(6))
REGISTER_REGISTRY(RegisterWaypoints)
+/** If you register a new waypoint, make sure to add it to all.inc */
+#define REGISTER_WAYPOINT_(id, init) REGISTER(RegisterWaypoints, WP, Waypoints, id, m_id, init)
CLASS(Waypoint, Object)
ATTRIB(Waypoint, m_id, int, 0)
if (s == WP_Monster.netname) return get_monsterinfo(self.wp_extra).monster_name;
// need to loop, as our netname could be one of three
- FOREACH(WAYPOINTS, it.netname == s, LAMBDA(
+ FOREACH(Waypoints, it.netname == s, LAMBDA(
return it.m_name;
));
const int PROJECTILE_NADE_MONSTER = 82;
const int PROJECTILE_NADE_MONSTER_BURN = 83;
-REGISTRY(Nades, 8)
+REGISTRY(Nades, BIT(3))
REGISTER_REGISTRY(RegisterNades)
-#define REGISTER_NADE(id) REGISTER(RegisterNades, NADE_TYPE, Nades, Nades_COUNT, id, m_id, NEW(Nade))
+#define REGISTER_NADE(id) REGISTER(RegisterNades, NADE_TYPE, Nades, id, m_id, NEW(Nade))
CLASS(Nade, Object)
ATTRIB(Nade, m_id, int, 0)
// Used in places where a string is required
#define SND(id) (SND_##id.sound_str())
-REGISTRY(Sounds, 128)
+REGISTRY(Sounds, BIT(8))
REGISTER_REGISTRY(RegisterSounds)
CLASS(Sound, Object)
#define SOUND(name, path) \
string SND_##name##_get() { return path; } \
- REGISTER(RegisterSounds, SND, Sounds, Sounds_COUNT, name, m_id, NEW(Sound, SND_##name##_get))
+ REGISTER(RegisterSounds, SND, Sounds, name, m_id, NEW(Sound, SND_##name##_get))
STATIC_INIT(RegisterSounds_precache) {
FOREACH(Sounds, true, LAMBDA({
#include "turret.qh"
-REGISTRY(Turrets, 24)
+REGISTRY(Turrets, BIT(5))
REGISTER_REGISTRY(RegisterTurrets)
const int TUR_FIRST = 1;
#define TUR_LAST (Turrets_COUNT - 1)
-#define REGISTER_TURRET(id, inst) REGISTER(RegisterTurrets, TUR, Turrets, Turrets_COUNT, id, m_id, inst)
+#define REGISTER_TURRET(id, inst) REGISTER(RegisterTurrets, TUR, Turrets, id, m_id, inst)
REGISTER_TURRET(Null, NEW(Turret));
#include "vehicle.qh"
-REGISTRY(Vehicles, 24)
+REGISTRY(Vehicles, BIT(3))
REGISTER_REGISTRY(RegisterVehicles)
const int VEH_FIRST = 1;
#define VEH_LAST (Vehicles_COUNT - 1)
/** If you register a new vehicle, make sure to add it to all.inc */
-#define REGISTER_VEHICLE(id, inst) REGISTER(RegisterVehicles, VEH, Vehicles, Vehicles_COUNT, id, vehicleid, inst)
+#define REGISTER_VEHICLE(id, inst) REGISTER(RegisterVehicles, VEH, Vehicles, id, vehicleid, inst)
#if defined(SVQC)
#include "sv_vehicles.qh"
if(self.total_damages < time)
{
- boxparticles(particleeffectnum(effects_ent[self.traileffect]), self, self.origin, self.origin + _dir * -64, _dir * -_len , _dir * -_len, 1, PARTICLES_USEALPHA);
+ boxparticles(particleeffectnum(Effects[self.traileffect]), self, self.origin, self.origin + _dir * -64, _dir * -_len , _dir * -_len, 1, PARTICLES_USEALPHA);
boxparticles(self.lip, self, self.move_origin, self.move_origin + _dir * -64, _dir * -200 , _dir * -200, 1, PARTICLES_USEALPHA);
self.total_damages = time + 0.1;
}
#define REGISTER_WEAPON(id, inst) \
/* WepSet WEPSET_##id; */ \
- REGISTER(RegisterWeapons, WEP, Weapons, Weapons_COUNT, id, m_id, inst)
+ REGISTER(RegisterWeapons, WEP, Weapons, id, m_id, inst)
// create cvars for weapon settings
#define WEP_ADD_CVAR_NONE(wepname,name) [[last]] float autocvar_g_balance_##wepname##_##name;
#ifdef CSQC
#define REGISTER_NET_LINKED(id, param) \
void Ent_Read##id(entity this, param) { this = self; } \
- REGISTER(RegisterLinkedEntities, NET, LinkedEntities, LinkedEntities_COUNT, id, m_id, spawn()) { \
+ REGISTER(RegisterLinkedEntities, NET, LinkedEntities, id, m_id, spawn()) { \
this.netname = #id; \
this.m_read = Ent_Read##id; \
} \
#else
#define REGISTER_NET_LINKED(id, param) \
const bool NET_##id##_istemp = false; \
- REGISTER(RegisterLinkedEntities, NET, LinkedEntities, LinkedEntities_COUNT, id, m_id, spawn()) { \
+ REGISTER(RegisterLinkedEntities, NET, LinkedEntities, id, m_id, spawn()) { \
this.netname = #id; \
}
#endif
-REGISTRY(LinkedEntities, 24)
+REGISTRY(LinkedEntities, BIT(0))
REGISTER_REGISTRY(RegisterLinkedEntities)
REGISTRY_SORT(LinkedEntities, netname, 0)
STATIC_INIT(RegisterLinkedEntities_renumber) {
#ifdef CSQC
#define REGISTER_NET_TEMP(id, param) \
void Net_Read##id(entity this, param); \
- REGISTER(RegisterTempEntities, NET, TempEntities, TempEntities_COUNT, id, m_id, spawn()) { \
+ REGISTER(RegisterTempEntities, NET, TempEntities, id, m_id, spawn()) { \
this.netname = #id; \
this.m_read = Net_Read##id; \
} \
#else
#define REGISTER_NET_TEMP(id, param) \
const bool NET_##id##_istemp = true; \
- REGISTER(RegisterTempEntities, NET, TempEntities, TempEntities_COUNT, id, m_id, spawn()) { \
+ REGISTER(RegisterTempEntities, NET, TempEntities, id, m_id, spawn()) { \
this.netname = #id; \
}
#endif
-REGISTRY(TempEntities, 24)
+REGISTRY(TempEntities, BIT(0))
REGISTER_REGISTRY(RegisterTempEntities)
REGISTRY_SORT(TempEntities, netname, 0)
STATIC_INIT(RegisterTempEntities_renumber) {
* Must be followed by a semicolon or a function body with a `this` parameter.
* Wrapper macros may perform actions after user initialization like so:
* #define REGISTER_FOO(id) \
- * REGISTER(RegisterFoos, FOO, FOOS, FOOS_COUNT, id, m_id, NEW(Foo)); \
+ * REGISTER(RegisterFoos, FOO, FOOS, id, m_id, NEW(Foo)); \
* REGISTER_INIT_POST(FOO, id) { \
* print("Registering foo #", this.m_id + 1, "\n"); \
* } \
* @param initfunc The global constructor to accumulate into
* @param ns Short for namespace, prefix for each global (ns##_##id)
* @param array The array to add each entity to. Also requires `array##_first` and `array##_last` to be defined
- * @param counter Global to count number of entries
* @param id The identifier of the current entity being registered
* @param fld The field to store the current count into
* @param inst An expression to create a new instance, invoked for every registration
*/
-#define REGISTER(initfunc, ns, array, counter, id, fld, inst) \
+#define REGISTER(initfunc, ns, array, id, fld, inst) \
entity ns##_##id; \
REGISTER_INIT(ns, id) { } \
REGISTER_INIT_POST(ns, id) { } \
.entity enemy; /* internal next pointer */ \
void Register_##ns##_##id() { \
+ if (array##_COUNT >= array##_MAX) LOG_FATALF("Registry capacity exceeded (%s)", ftos(array##_MAX)); \
entity this = inst; \
ns##_##id = this; \
- this.fld = counter; \
- array[counter++] = this; \
+ this.fld = array##_COUNT; \
+ array[array##_COUNT++] = this; \
if (!array##_first) array##_first = this; \
if ( array##_last) array##_last.enemy = this; \
array##_last = this; \
#ifndef GAMESETTINGS_H
#define GAMESETTINGS_H
-void RegisterSettings();
-const int MAX_SETTINGS = 24;
-Lazy SETTINGS[MAX_SETTINGS], SETTINGS_first, SETTINGS_last;
-int SETTINGS_COUNT;
+REGISTRY(Settings, BIT(3))
+REGISTER_REGISTRY(RegisterSettings)
#define REGISTER_SETTINGS(id, impl) \
LAZY_NEW(id, impl) \
- REGISTER(RegisterSettings, MENU, SETTINGS, SETTINGS_COUNT, id, m_id, NEW(Lazy, LAZY(id)))
-REGISTER_REGISTRY(RegisterSettings)
+ REGISTER(RegisterSettings, MENU, Settings, id, m_id, NEW(Lazy, LAZY(id)))
#endif
#endif
CLASS(SettingSource, DataSource)
METHOD(SettingSource, getEntry, entity(entity this, int i, void(string name, string icon) returns))
{
- Lazy l = SETTINGS[i];
+ Lazy l = Settings[i];
entity it = l.m_get();
if (returns) returns(it.title, string_null);
return it;
}
- METHOD(SettingSource, reload, int(entity this, string filter)) { return SETTINGS_COUNT; }
+ METHOD(SettingSource, reload, int(entity this, string filter)) { return Settings_COUNT; }
ENDCLASS(SettingSource)
#include "listbox.qc"
{
if (!k.owner) continue;
entity first = WP_Null;
- FOREACH(WAYPOINTS, it.netname == k.owner.waypointsprite_attachedforcarrier.model1, LAMBDA(first = it; break));
+ FOREACH(Waypoints, it.netname == k.owner.waypointsprite_attachedforcarrier.model1, LAMBDA(first = it; break));
entity third = WP_Null;
- FOREACH(WAYPOINTS, it.netname == k.owner.waypointsprite_attachedforcarrier.model3, LAMBDA(third = it; break));
+ FOREACH(Waypoints, it.netname == k.owner.waypointsprite_attachedforcarrier.model3, LAMBDA(third = it; break));
WaypointSprite_UpdateSprites(k.owner.waypointsprite_attachedforcarrier, first, WP_KeyCarrierFinish, third);
}
}
{
if (!k.owner) continue;
entity first = WP_Null;
- FOREACH(WAYPOINTS, it.netname == k.owner.waypointsprite_attachedforcarrier.model1, LAMBDA(first = it; break));
+ FOREACH(Waypoints, it.netname == k.owner.waypointsprite_attachedforcarrier.model1, LAMBDA(first = it; break));
entity third = WP_Null;
- FOREACH(WAYPOINTS, it.netname == k.owner.waypointsprite_attachedforcarrier.model3, LAMBDA(third = it; break));
+ FOREACH(Waypoints, it.netname == k.owner.waypointsprite_attachedforcarrier.model3, LAMBDA(third = it; break));
WaypointSprite_UpdateSprites(k.owner.waypointsprite_attachedforcarrier, first, WP_KeyCarrierFriend, third);
}
}