void train_next()
{
- entity targ, cp;
- vector cp_org;
+ entity targ, cp = world;
+ vector cp_org = '0 0 0';
targ = find(world, targetname, self.target);
self.target = targ.target;
cp = find(world, targetname, targ.curvetarget); // get its second target (the control point)
cp_org = cp.origin - self.view_ofs; // no control point found, assume a straight line to the destination
}
- else
- cp = world; // no cp
}
if (self.target == "")
objerror("train_next: no next target");