16.12.2018, 12:13
PHP код:
new str[14], _rand = random(sizeof(ZombiesSpawnCords)), _thenpc;
for(new o; o<MAX_ZOMBIES; o++)
{
_rand = random(sizeof(ZombiesSpawnCords));
format(str, sizeof(str), "Zombie_%d", _thenpc);
_thenpc = FCNPC_Create(str);
FCNPC_Spawn(_thenpc, random(311), ZombiesSpawnCords[_rand][0], ZombiesSpawnCords[_rand][1], ZombiesSpawnCords[_rand][2] + 1.0);
zInfo[o][zLabel] = CreateDynamic3DTextLabel(""COL_RED"Roamer Zombie\n"COL_WHITE"Health: 100", -1, 0.0, 0.0, 0.2, 20.0, .attachedplayer = _thenpc, .testlos = 1);
zInfo[o][zID] = _thenpc;
zInfo[o][zType] = ZOMBIE_TYPE_ROAMER;