mirror of
https://github.com/nzp-team/quakec.git
synced 2024-11-24 21:02:14 +00:00
CLIENT: CSQC overriding Zombie skin variances
This commit is contained in:
parent
3ad99583df
commit
81b4aa187e
2 changed files with 29 additions and 0 deletions
|
@ -241,6 +241,23 @@ vector playerOrigin;
|
|||
vector playerOriginOld;
|
||||
vector playerVelocity;
|
||||
|
||||
//
|
||||
// List of Zombie limb meshes for custom skinning
|
||||
//
|
||||
string zombie_skins[] =
|
||||
{
|
||||
"models/ai/zb%.mdl",
|
||||
"models/ai/zbc%.mdl",
|
||||
"models/ai/zcfull.mdl",
|
||||
"models/ai/zhc^.mdl",
|
||||
"models/ai/zalc(.mdl",
|
||||
"models/ai/zarc(.mdl",
|
||||
"models/ai/zfull.mdl",
|
||||
"models/ai/zh^.mdl",
|
||||
"models/ai/zal(.mdl",
|
||||
"models/ai/zar(.mdl"
|
||||
};
|
||||
|
||||
//
|
||||
// Screen sizes, self-explanatory.
|
||||
//
|
||||
|
|
|
@ -56,6 +56,13 @@ void() ToggleMenu =
|
|||
}
|
||||
}
|
||||
|
||||
float(float isnew) SetZombieSkinning =
|
||||
{
|
||||
self.drawmask = MASK_ENGINE;
|
||||
setcustomskin(self, __NULL__, sprintf("replace \"\" \"models/ai/zfull.mdl_%d.pcx\"\n", self.skin));
|
||||
return PREDRAW_NEXT;
|
||||
};
|
||||
|
||||
noref void(float apiver, string enginename, float enginever) CSQC_Init =
|
||||
{
|
||||
setwindowcaption("Nazi Zombies: Portable");
|
||||
|
@ -163,6 +170,11 @@ noref void(float apiver, string enginename, float enginever) CSQC_Init =
|
|||
build_datetime = fgets(file);
|
||||
fclose(file);
|
||||
}
|
||||
|
||||
// Intercept every Zombie mesh to apply custom skinning
|
||||
for(float i = 0; i < zombie_skins.length; i++) {
|
||||
deltalisten(zombie_skins[i], SetZombieSkinning, 0);
|
||||
}
|
||||
};
|
||||
|
||||
noref void() CSQC_WorldLoaded =
|
||||
|
|
Loading…
Reference in a new issue