var hSpawnfile = file_open_read(strDatFile);
STRING *strSpawnList = str_create("#1024");
int i;
for(i = 0; i < 1024; i++)
{
if(file_str_read(hSpawnfile, strSpawnList) == -1)
break;
var tempCnt = 0;
var vTemp[3];
while(true)
{
var sym = str_stri(strSpawnList, ";");
if(!sym)
break;
STRING *strTmp = str_create("#16");
str_cpy(strTmp, strSpawnList);
str_clip(strSpawnList, sym);
str_trunc(strTmp, str_len(strTmp) - sym + 1);
if(tempCnt <= 2)//Vector hat 3 Zeichen (<=2) und danach kommt das team.
{
vTemp[tempCnt] = str_to_num(strTmp);
tempCnt++;
}
else//Erstellt die entity am zuvor ausgelesenen vector
{
ENTITY *entTmp = ent_create(NULL, vTemp, net_SpawnPoint);
entTmp.skill1 = str_to_num(strTmp); //Team
tempCnt = 0;
}
str_remove(strTmp);
}
file_close(hSpawnfile);
}