View Single Post
[HL Mod] C++ Scripting Help
Old
  (#1)
Bend3R
Member
 
Status: Offline
Posts: 50
Join Date: Jun 2005
Default [HL Mod] C++ Scripting Help - 08-02-2007

Hi, I need help with code line/s if you can.
I have a model with 11 different body sub-models and I don't know how to do
so the Plugin choose random sub-model from the model file.
What for lines do I need to add?

Code:
void CMZombie :: Spawn()
{
 Precache( );
 SET_MODEL(ENT(pev), "modelname.mdl");
 UTIL_SetSize( pev, VEC_HUMAN_HULL_MIN, VEC_HUMAN_HULL_MAX );
 
 pev->solid   = SOLID_SLIDEBOX;
 pev->movetype  = MOVETYPE_STEP;
 m_bloodColor  = BLOOD_COLOR_RED;
 pev->health   = gSkillData.zombieHealth;
 pev->view_ofs  = VEC_VIEW;// position of the eyes relative to monster's origin.
 m_flFieldOfView  = 0.5;// indicates the width of this monster's forward view cone ( as a dotproduct result )
 m_MonsterState  = MONSTERSTATE_NONE;
 m_afCapability  = bits_CAP_DOORS_GROUP;
 
.......
 
 MonsterInit();
}

Last edited by Bend3R; 08-02-2007 at 21:50..
  
Reply With Quote