mirror of
https://github.com/mangosfour/server.git
synced 2025-12-13 13:37:05 +00:00
[9881] Add additional fields to *_scripts tables for storage of more data.
Currently not in use by any SCRIPT_COMMAND_* but we have secret plans to be revealed in the future! Signed-off-by: NoFantasy <nofantasy@nf.no>
This commit is contained in:
parent
fecf6fdb72
commit
faf3e287c7
7 changed files with 65 additions and 14 deletions
|
|
@ -4159,7 +4159,7 @@ void ObjectMgr::LoadScripts(ScriptMapMap& scripts, char const* tablename)
|
|||
|
||||
scripts.clear(); // need for reload support
|
||||
|
||||
QueryResult *result = WorldDatabase.PQuery( "SELECT id,delay,command,datalong,datalong2,dataint, x, y, z, o FROM %s", tablename );
|
||||
QueryResult *result = WorldDatabase.PQuery( "SELECT id, delay, command, datalong, datalong2, datalong3, datalong4, data_flags, dataint, x, y, z, o FROM %s", tablename );
|
||||
|
||||
uint32 count = 0;
|
||||
|
||||
|
|
@ -4181,16 +4181,19 @@ void ObjectMgr::LoadScripts(ScriptMapMap& scripts, char const* tablename)
|
|||
|
||||
Field *fields = result->Fetch();
|
||||
ScriptInfo tmp;
|
||||
tmp.id = fields[0].GetUInt32();
|
||||
tmp.delay = fields[1].GetUInt32();
|
||||
tmp.command = fields[2].GetUInt32();
|
||||
tmp.datalong = fields[3].GetUInt32();
|
||||
tmp.datalong2 = fields[4].GetUInt32();
|
||||
tmp.dataint = fields[5].GetInt32();
|
||||
tmp.x = fields[6].GetFloat();
|
||||
tmp.y = fields[7].GetFloat();
|
||||
tmp.z = fields[8].GetFloat();
|
||||
tmp.o = fields[9].GetFloat();
|
||||
tmp.id = fields[0].GetUInt32();
|
||||
tmp.delay = fields[1].GetUInt32();
|
||||
tmp.command = fields[2].GetUInt32();
|
||||
tmp.datalong = fields[3].GetUInt32();
|
||||
tmp.datalong2 = fields[4].GetUInt32();
|
||||
tmp.datalong3 = fields[5].GetUInt32();
|
||||
tmp.datalong4 = fields[6].GetUInt32();
|
||||
tmp.data_flags = fields[7].GetUInt32();
|
||||
tmp.dataint = fields[8].GetInt32();
|
||||
tmp.x = fields[9].GetFloat();
|
||||
tmp.y = fields[10].GetFloat();
|
||||
tmp.z = fields[11].GetFloat();
|
||||
tmp.o = fields[12].GetFloat();
|
||||
|
||||
// generic command args check
|
||||
switch(tmp.command)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue