Forum




Spawners
3 replies



objects_stuff.inf
Note that the
varstatements in the definition are required as well.
### Turtle Spawner
id=230
name=Turtle Spawner
group=building
icon=gfx\turtlespawner.bmp
model=gfx\turtlespawner.b3d
health=100
mat=stone
maxweight=100000
script=start
}
on:build_finish {
event "turtlespawnerbuild",0,0;
}
on:use {
msgbox "Turtle Spawner","sys/scripts/turtlespawner.s2s";
}
on:changeday {
local $c;
$c+=count_inrange("unit",10,20,"self");
if ($c<3){
create "unit",10,getx("self"),getz("self");
if (random(2)==1){
create "unit",10,getx("self"),getz("self");
}
}
}
script=end
description=start
Creates turtles
description=end
I also had an idea to make a beehive that spawns bees, but I cant make models for them



