KTRose Problems

New forum to discuss KTRose code

Moderators: osRose dev team, ospRose dev team, osiRose dev team, Moderators

KTRose Problems

Postby rl2171 on Tue Dec 11, 2012 1:03 am

I have been looking at the various mobs on most of the maps, I have found the following maps are not showing any mobs on them, even with them listed in the list_spawnareas.sql file:

Junon Clan Fields, maps 11,12, 13

Arumic Valley, Map 53
Freezing Plateau, map 55
Forgotten Temple B1 & B2, maps 56 & 57

Looks like Mana Snowfields are missing alot of mobs as there is alot of empty areas.

Luna Clan Field has no mobs in listed in the sql file.

I quickly just looked around the maps to see what I could find, there might be more.

How do we convert existing older files to this version?

Anyone have a idea on why the mobs above that are listed in the sql file, but isn't showing up on the maps?

I have only one modification to the code in the Gmcmds file for the go command. The client is KTRose with he updates that we were told to do for it.
Image
rl2171
Admin
Admin
 
Posts: 1706
Joined: Mon Aug 06, 2007 5:17 pm
Location: Sacramento, CA USA - GMT-8

Re: KTRose Problems

Postby rl2171 on Tue Dec 11, 2012 1:09 am

update, I just re-read the initial message

list_special_spawns as a default

So, does that mean the list_spawnareas is not used?
Image
rl2171
Admin
Admin
 
Posts: 1706
Joined: Mon Aug 06, 2007 5:17 pm
Location: Sacramento, CA USA - GMT-8

Re: KTRose Problems

Postby PurpleYouko on Tue Dec 11, 2012 3:31 pm

That is correct.
I left it in so that if anyone wants to, they can switch back to using that table.
The code for both versions is still in the server but the list_spawnareas stuff is commented out.
Need to lookup information on NARose items, skills, quests?
Now featuring a newly completed skill tree for all classes
Formatting fixed for different resolutions
Image

"A Gazelle is nothing but a giraffe plotted logarithmicaly"
User avatar
PurpleYouko
Rose Guru
Rose Guru
 
Posts: 4733
Joined: Fri Aug 10, 2007 2:05 pm

Re: KTRose Problems

Postby Ultra on Tue Dec 11, 2012 4:35 pm

[BUG]
When you type /class muse (or whatever)
dont change your class.... but it says that the class is changed...
Also i have type /here to reset the character but still says visitor..
Ultra
Rackie
Rackie
 
Posts: 226
Joined: Thu Jul 22, 2010 6:31 pm
Location: Usa

Re: KTRose Problems

Postby PurpleYouko on Wed Dec 12, 2012 3:05 pm

You have to relog after changing class with a GM command in this version.
Fixing that was never one of my priorities ;)
Need to lookup information on NARose items, skills, quests?
Now featuring a newly completed skill tree for all classes
Formatting fixed for different resolutions
Image

"A Gazelle is nothing but a giraffe plotted logarithmicaly"
User avatar
PurpleYouko
Rose Guru
Rose Guru
 
Posts: 4733
Joined: Fri Aug 10, 2007 2:05 pm

Re: KTRose Problems

Postby rl2171 on Thu Dec 13, 2012 2:48 am

I tried to change back for the time being from the list_special_spawns to list_spawnareas


  1.  
  2.     MYSQL_ROW row;
  3.     MYSQL_RES *result = DB->QStore("SELECT id,map,montype,min,max,respawntime,points, spawntype, triggermontype, triggerammount, agressive, areatrigger, lim, spawnk FROM list_spawnareas");
  4.     //MYSQL_RES *result = DB->QStore("SELECT id, map, montype, min, max, respawntime, x, y, radius, spawntype, triggermontype, triggerammount, agressive, areatrigger, lim, spawnk, aip, refvar, refval FROM list_special_spawns");
  5.  
  6.     if(result == NULL)
  7.     {
  8.         DB->QFree( );
  9.         return false;
  10.     }
  11.     Log( MSG_INFO, "Loaded database data" );
  12.  


I unremarked the first one for the spawnareas and remarked the one with the special_spawns

All compiled ok, but when executed the world server it crashed at this part


Wed Dec 12 17:40:59 2012 - Loading NPC Data
Wed Dec 12 17:40:59 2012 - Loading Telegates data
Wed Dec 12 17:40:59 2012 - Loading RespawnZones data
Wed Dec 12 17:40:59 2012 - Loading SpawnZones data
Wed Dec 12 17:40:59 2012 - Loaded database data

This is where it stopped

Did something get removed from the code as I dont see anymore remarked out in there to re-enable the spawnareas at the moment

  1.  
  2. bool CWorldServer::LoadMonsterSpawn( )
  3. {
  4.     Log( MSG_INFO, "Loading SpawnZones data" );
  5.     //clear the respawns data first
  6.  
  7.     for(int i=0;i<MapList.Map.size();i++)
  8.     {
  9.         MapList.Index[i]->MonsterSpawnList.clear();
  10.     }
  11.     MYSQL_ROW row;
  12.     MYSQL_RES *result = DB->QStore("SELECT id,map,montype,min,max,respawntime,points, spawntype, triggermontype, triggerammount, agressive, areatrigger, lim, spawnk FROM list_spawnareas");
  13.     //MYSQL_RES *result = DB->QStore("SELECT id, map, montype, min, max, respawntime, x, y, radius, spawntype, triggermontype, triggerammount, agressive, areatrigger, lim, spawnk, aip, refvar, refval FROM list_special_spawns");
  14.  
  15.     if(result == NULL)
  16.     {
  17.         DB->QFree( );
  18.         return false;
  19.     }
  20.     Log( MSG_INFO, "Loaded database data" );
  21.     while(row = mysql_fetch_row(result))
  22.     {
  23.         bool flag = true;
  24.         char* tmp;
  25.         CSpawnArea* thisspawn = new (nothrow) CSpawnArea;
  26.         if(thisspawn==NULL)
  27.         {
  28.             Log(MSG_ERROR, "Error allocing memory" );
  29.             DB->QFree( );
  30.             return false;
  31.         }
  32.         thisspawn->id = atoi(row[0]);
  33.         if(thisspawn->id > GServer->maxSpawnId)
  34.             GServer->maxSpawnId = thisspawn->id;
  35.         thisspawn->map = atoi(row[1]);
  36.         thisspawn->montype = atoi(row[2]);
  37.         thisspawn->min = 0;//atoi(row[3]);
  38.         thisspawn->max = atoi(row[4]);
  39.         thisspawn->respawntime = atoi(row[5]);
  40.         thisspawn->point.x = atoi(row[6]);
  41.         if(thisspawn->map == 3)
  42.             thisspawn->point.x -= 100; //for some reason some JP map has an X offset.
  43.         thisspawn->point.y = atoi(row[7]);
  44.         thisspawn->radius = atoi(row[8]);
  45.         if (thisspawn->respawntime == 0)
  46.             thisspawn->respawntime=5;
  47.         thisspawn->amon = 0;
  48.         thisspawn->lastRespawnTime = clock();
  49.         thisspawn->type = atoi(row[9]);
  50.         thisspawn->triggertype = atoi(row[10]);
  51.         thisspawn->triggeramount = atoi(row[11]);
  52.         thisspawn->aggressive = atoi(row[12]);
  53.         thisspawn->typeoftrigger = atoi(row[13]);
  54.         thisspawn->limit = atoi(row[14]);
  55.         thisspawn->spawnkey = atoi(row[15]);
  56.         thisspawn->AI = atoi(row[16]);
  57.         thisspawn->RefVar = atoi(row[17]);
  58.         thisspawn->RefVal = atoi(row[18]);
  59.         thisspawn->triggercount = 0;
  60.         //if(thisspawn->id >= 10000) //tower defense spawn
  61.         //    thisspawn->triggercount = 10000; //disables the spawn until it is reset to 0
  62.         //if(flag)
  63.         //{
  64.             thisspawn->thisnpc = GetNPCDataByID( thisspawn->montype );
  65.             if(thisspawn->thisnpc == NULL)
  66.             {
  67.                 Log( MSG_WARNING, "Invalid montype - Spawn %i will not be added", thisspawn->id );
  68.                 delete thisspawn;
  69.                 continue;
  70.             }
  71.             MapList.Index[thisspawn->map]->MonsterSpawnList.push_back( thisspawn );
  72.         //}
  73.     }
  74.     DB->QFree( );
  75.     return true;
  76. }
  77.  
  78.  


I'm still trying to see what is wrong, I would think it is some different between the 2 lines, but have not seen it yet.

Thank you.
Image
rl2171
Admin
Admin
 
Posts: 1706
Joined: Mon Aug 06, 2007 5:17 pm
Location: Sacramento, CA USA - GMT-8

Re: KTRose Problems

Postby WiseGuy on Thu Dec 13, 2012 6:24 am

This part is your error:

thisspawn->point.x = atoi(row[6]);
thisspawn->point.y = atoi(row[7]);


in the first query:
row[6] = 'points' an array type column
and maybe on the next entry of them have the similar problems.

CMIIW.
It is nice to be important
but very very important to be nice
User avatar
WiseGuy
Pomic
Pomic
 
Posts: 112
Joined: Sat Nov 21, 2009 4:03 am
Location: Jakarta

Re: KTRose Problems

Postby PurpleYouko on Thu Dec 13, 2012 2:58 pm

There's a lot more differences than just the queries.
The actual data called in by the new query is completely different than the old one so a whole bunch of code will need to be modified.
I just left in the old query so that somebody could rebuild the other method if they really wanted to.
It won't be a very easy rebuild though and i don't know why you would want to anyway. The mobgroups system developed by Drakia was found to be completely flawed anyway. The groups were not being used properly, half of the IFO data never got used at all and the tactical points were being completely misused.

There are some very far reaching consequences to using a different monster spawn system to the default one. There are large amounts of code all thoughout the server that would fail to compile or run if the correct structures are not initialized in the monster load function
Need to lookup information on NARose items, skills, quests?
Now featuring a newly completed skill tree for all classes
Formatting fixed for different resolutions
Image

"A Gazelle is nothing but a giraffe plotted logarithmicaly"
User avatar
PurpleYouko
Rose Guru
Rose Guru
 
Posts: 4733
Joined: Fri Aug 10, 2007 2:05 pm

Re: KTRose Problems

Postby jopjopjop on Fri Jun 20, 2014 6:02 pm

Hi. I used the server files and the client you guys gave for KTRose and everything went perfectly.

I tested it for a while and I noticed that, no matter what, weapons and armors don't drop. Only mats and pots.

So, what do you think is the problem there? Sorry for the noob question. :oops:

When I compiled the files, there are lots of warnings. Is that what causes the problem?
jopjopjop
Little soul
Little soul
 
Posts: 2
Joined: Fri Jun 20, 2014 5:54 am

Re: KTRose Problems

Postby PurpleYouko on Mon Jun 23, 2014 2:33 pm

No the warnings are not the issue. 99% of them actually come from the pthreads library that we link and are mostly due to code in those modules that will never run... because we don't actually call the functions
The rest of the warnings are trivial things such as floating point decimals getting recast as integers with "potential data loss".

If weapons are not dropping then the chances are that they are not in your drops table.
KTRose currently uses table new_drops in the database.
Try looking in the database table to see what should be dropping. I haven't really worked with drops for a long time so I don't remember exactly what is in the table. I'm pretty sure the weapons drops are in there but they are pretty rare.

The way the table is set up is similar to the old drops stb file
the row number of the table relates to the drop id of the monsters in LIST_NPC.STB.
The first 100 rows relate to map ids so we can define map drops.
There are up to 100 items and chances in each drops row. The current entries are made such that all the drop chances added together comes to ~100,000 for each row. The actual total doesn't really matter except for calculating the actual percentage drop chance of each item. If you add a new item with it's own chance then you obviously reduce the chance of anything else dropping simply because the total is now bigger.
Need to lookup information on NARose items, skills, quests?
Now featuring a newly completed skill tree for all classes
Formatting fixed for different resolutions
Image

"A Gazelle is nothing but a giraffe plotted logarithmicaly"
User avatar
PurpleYouko
Rose Guru
Rose Guru
 
Posts: 4733
Joined: Fri Aug 10, 2007 2:05 pm

Next

Return to KTRose Release

Who is online

Users browsing this forum: No registered users and 1 guest

cron