Guys, I'm running into a little trouble here. I'm adding ogres to my QW mod. Here's the code:
void() create_ogre =
{
local entity ogre, spawn_spot;
// start entity and place it in world
ogre = spawn();
spawn_spot = SelectSpawnPoint ();
ogre.origin = spawn_spot.origin + '0 0 1';
ogre.angles = spawn_spot.angles;
ogre.fixangle = TRUE;
spawn_tfog (ogre.origin);
spawn_tdeath (ogre.origin, ogre);
// set size and shape
setsize (ogre, VEC_HULL2_MIN, VEC_HULL2_MAX);
ogre.solid = SOLID_SLIDEBOX;
ogre.movetype = MOVETYPE_STEP;
setmodel(ogre, "progs/ogre.mdl");
ogre.flags = ogre.flags | FL_MONSTER;
ogre.takedamage = DAMAGE_AIM;
// define his animation
ogre.th_stand = ogre_stand1;
ogre.th_walk = ogre_walk1;
ogre.th_run = ogre_run1;
ogre.th_die = ogre_die;
ogre.th_melee = ogre_melee;
ogre.th_missile = ogre_nail1;
ogre.th_pain = ogre_pain;
ogre.health = 200;
// polish him up
ogre.classname = "monster_ogre";
ogre.ideal_yaw = bot.angles * '0 1 0';
ogre.yaw_speed = 120;
ogre.view_ofs = '0 0 22';
bprint("an ogre joins the game\n");
// begin his thinking
ogre.nextthink = time + 0.1 + random();
ogre.think = bot.th_walk;
};
The line in bold seems to be the problem. Here is the error:
Type mismatch for = (entity and void)
What does that mean?