mirror of
https://github.com/mangosfour/server.git
synced 2025-12-16 04:37:00 +00:00
[9634] Remove fields 'data' and 'zone' from corpse table.
Signed-off-by: hunuza <hunuza@gmail.com>
This commit is contained in:
parent
6c553bf226
commit
d85e4228f1
12 changed files with 106 additions and 81 deletions
|
|
@ -81,6 +81,23 @@ Tokens StrSplit(const std::string &src, const std::string &sep)
|
|||
return r;
|
||||
}
|
||||
|
||||
uint32 GetUInt32ValueFromArray(Tokens const& data, uint16 index)
|
||||
{
|
||||
if(index >= data.size())
|
||||
return 0;
|
||||
|
||||
return (uint32)atoi(data[index].c_str());
|
||||
}
|
||||
|
||||
float GetFloatValueFromArray(Tokens const& data, uint16 index)
|
||||
{
|
||||
float result;
|
||||
uint32 temp = GetUInt32ValueFromArray(data,index);
|
||||
memcpy(&result, &temp, sizeof(result));
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
void stripLineInvisibleChars(std::string &str)
|
||||
{
|
||||
static std::string invChars = " \t\7\n";
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue