ok so the KTRose server on my github is actually built for project 137.
It uses the custom trigger spawn system from pre-evo KTRose
The database table it uses is list_special_spawns
Spawns can actually be permanently created by using the GM command "spawn"
You are going to need the IsDev field in the characters database set to 1 for the GM character and an access level of 900 in the accounts table for teh GM characters account.
You will have to look at the code to figure out the precise format of the command. It can be very complicated if you want to set up sequences with triggerspawns. Here is the code
- if (strcmp(command, "spawn")==0)
- {
- SendPM(thisclient,"Attempting to use spawn command.");
- if(Config.Command_ESpawn > thisclient->Session->accesslevel || thisclient->CharInfo->isDev == 0)
- {
- return true;
- }
- int mobid;
- int max;
- int radius;
- int stime;
- int spawntype;
- int triggermontype;
- int triggeramount;
- int lim;
- int spawnk;
- int aggro;
- int refvar; //Objvar NPC reference
- int refval; //Objvar array reference
-
- if ((tmp = strtok(NULL, " "))==NULL)
- return true;
- else
- mobid = atoi(tmp);
- if ((tmp = strtok(NULL, " "))==NULL)
- return true;
- else
- max = atoi(tmp);
- if ((tmp = strtok(NULL, " "))==NULL)
- return true;
- else
- radius = atoi(tmp);
- if ((tmp = strtok(NULL, " "))==NULL)
- return true;
- else
- stime = atoi(tmp);
- if ((tmp = strtok(NULL, " "))==NULL)
- return true;
- else
- spawntype = atoi(tmp);
- if ((tmp = strtok(NULL, " "))==NULL)
- triggermontype = 0;
- else
- triggermontype = atoi(tmp);
- if ((tmp = strtok(NULL, " "))==NULL)
- triggeramount = 0;
- else
- triggeramount = atoi(tmp);
- if ((tmp = strtok(NULL, " "))==NULL)
- lim = 0;
- else
- lim = atoi(tmp);
- if ((tmp = strtok(NULL, " "))==NULL)
- spawnk = 1;
- else
- spawnk = atoi(tmp);
- if ((tmp = strtok(NULL, " "))==NULL)
- aggro = 1;
- else
- aggro = atoi(tmp);
- if ((tmp = strtok(NULL, " "))==NULL)
- refvar = 0;
- else
- refvar = atoi(tmp);
- if ((tmp = strtok(NULL, " "))==NULL)
- refval = 0;
- else
- refval = atoi(tmp);
-
- GServer->DB->QExecute("INSERT INTO list_special_spawns (map,montype,min,max,respawntime,x,y,radius,agressive,triggerammount,triggermontype,spawntype,areatrigger,lim,spawnk,refvar,refval) VALUES(%i,%i,%i,%i,%i,%f,%f,%i,%i,%i,%i,%i,%i,%i,%i,%i,%i)",
- thisclient->Position->Map,mobid,0,max,stime,thisclient->Position->current.x,thisclient->Position->current.y,radius,aggro,triggeramount,triggermontype,spawntype,1,lim,spawnk,refvar,refval );
- CSpawnArea* thisspawn = new (nothrow) CSpawnArea;
- if(thisspawn == NULL)
- {
- Log(MSG_ERROR, "Error allocing memory" );
- DB->QFree( );
- return false;
- }
- GServer->maxSpawnId++;
- thisspawn->id = GServer->maxSpawnId;
- thisspawn->map = thisclient->Position->Map;
- thisspawn->montype = mobid;
- thisspawn->min = 0;//atoi(row[3]);
- thisspawn->max = max;
- thisspawn->respawntime = stime;
- thisspawn->point.x = thisclient->Position->current.x;
- thisspawn->point.y = thisclient->Position->current.y;
- thisspawn->radius = radius;
- thisspawn->amon = 0;
- thisspawn->lastRespawnTime = 0;
- thisspawn->type = spawntype;
- thisspawn->triggertype = triggermontype;
- thisspawn->triggeramount = triggeramount;
- thisspawn->aggressive = aggro;
- thisspawn->typeoftrigger = 1;
- thisspawn->limit = lim;
- thisspawn->spawnkey = spawnk;
- thisspawn->triggercount = 0;
- thisspawn->thisnpc = GetNPCDataByID( thisspawn->montype );
- thisspawn->RefVar = refvar;
- thisspawn->RefVal = refval;
- if(thisspawn->thisnpc == NULL)
- {
- SendPM(thisclient, "Invalid montype - Spawn %i will not be added", thisspawn->id );
- delete thisspawn;
- return true;
- }
- MapList.Index[thisspawn->map]->MonsterSpawnList.push_back( thisspawn );
- SendPM(thisclient,"Spawn successfully saved with spawn id %i.",thisspawn->id);
- return true;
- }
A lot of the parameters can be ignored as they have default values.
What I really want to know though is
WHAT Client you are using this with?
It should only work with 137