mirror of
https://github.com/EQEmu/Server.git
synced 2025-12-14 15:41:30 +00:00
Merge pull request #23 from addtheice/master
Fixed missing include that blocked compile on linux.
This commit is contained in:
commit
f7469412f1
@ -20,7 +20,7 @@ public:
|
||||
EmuTCPConnection *FindConnection(uint32 iID);
|
||||
|
||||
//exposed for some crap we pull. Do not call from outside this object.
|
||||
TCPServer<EmuTCPConnection>::AddConnection;
|
||||
using TCPServer<EmuTCPConnection>::AddConnection;
|
||||
|
||||
protected:
|
||||
virtual void Process();
|
||||
|
||||
@ -23,6 +23,7 @@
|
||||
#include <sys/types.h>
|
||||
#include <sys/stat.h>
|
||||
#include <fcntl.h>
|
||||
#include <unistd.h>
|
||||
#endif
|
||||
#include "types.h"
|
||||
#include "eqemu_exception.h"
|
||||
|
||||
@ -554,7 +554,7 @@ void build_hex_line(const char *buffer, unsigned long length, unsigned long offs
|
||||
char *ptr=out_buffer;
|
||||
int i;
|
||||
char printable[17];
|
||||
ptr+=sprintf(ptr,"%0*i:",padding,offset);
|
||||
ptr+=sprintf(ptr,"%0*lu:",padding,offset);
|
||||
for(i=0;i<16; i++) {
|
||||
if (i==8) {
|
||||
strcpy(ptr," -");
|
||||
|
||||
@ -347,7 +347,7 @@ bool PTimerList::Load(Database *db) {
|
||||
//if it expired allready, dont bother.
|
||||
|
||||
cur = new PersistentTimer(_char_id, type, start_time, timer_time, enabled);
|
||||
if(!cur->Expired(false))
|
||||
if(!cur->Expired(NULL, false))
|
||||
_list[type] = cur;
|
||||
else
|
||||
delete cur;
|
||||
|
||||
@ -292,7 +292,7 @@ bool RuleManager::LoadRules(Database *db, const char *ruleset) {
|
||||
{
|
||||
safe_delete_array(query);
|
||||
while((row = mysql_fetch_row(result))) {
|
||||
if(!SetRule(row[0], row[1], false))
|
||||
if(!SetRule(row[0], row[1],NULL, false))
|
||||
_log(RULES__ERROR, "Unable to interpret rule record for %s", row[0]);
|
||||
}
|
||||
mysql_free_result(result);
|
||||
|
||||
@ -215,7 +215,7 @@ bool QTBuilder::build(const char *shortname) {
|
||||
AddFace(v1, v2, v3);
|
||||
}
|
||||
|
||||
printf("There are %u vertices and %u faces.\n", _FaceList.size()*3, _FaceList.size());
|
||||
printf("There are %lu vertices and %lu faces.\n", _FaceList.size()*3, _FaceList.size());
|
||||
|
||||
if(fileloader->model_data.plac_count)
|
||||
{
|
||||
@ -232,7 +232,7 @@ bool QTBuilder::build(const char *shortname) {
|
||||
else
|
||||
printf("No placeable objects (or perhaps %s_obj.s3d not present).\n", shortname);
|
||||
|
||||
printf("After processing placeable objects, there are %u vertices and %u faces.\n", _FaceList.size()*3, _FaceList.size());
|
||||
printf("After processing placeable objects, there are %lu vertices and %lu faces.\n", _FaceList.size()*3, _FaceList.size());
|
||||
|
||||
unsigned long r;
|
||||
|
||||
@ -1262,7 +1262,7 @@ void QTBuilder::AddPlaceableV4(FileLoader *fileloader, char *ZoneFileName, bool
|
||||
//return;
|
||||
|
||||
printf("EQG V4 Placeable Zone Support\n");
|
||||
printf("ObjectGroupCount = %i\n", fileloader->model_data.ObjectGroups.size());
|
||||
printf("ObjectGroupCount = %lu\n", fileloader->model_data.ObjectGroups.size());
|
||||
|
||||
vector<ObjectGroupEntry>::iterator Iterator;
|
||||
|
||||
|
||||
@ -88,7 +88,7 @@ EQLConfig *EQLConfig::CreateLauncher(const char *name, uint8 dynamic_count) {
|
||||
namebuf, dynamic_count), errbuf)) {
|
||||
LogFile->write(EQEMuLog::Error, "Error in CreateLauncher query: %s", errbuf);
|
||||
safe_delete_array(query);
|
||||
return false;
|
||||
return NULL;
|
||||
}
|
||||
safe_delete_array(query);
|
||||
|
||||
|
||||
@ -3836,7 +3836,7 @@ void Bot::AI_Process() {
|
||||
if(instweapon)
|
||||
weapon = instweapon->GetItem();
|
||||
|
||||
int weapontype = NULL;
|
||||
int weapontype = 0; // No weapon type.
|
||||
bool bIsFist = true;
|
||||
|
||||
if(weapon) {
|
||||
@ -17359,8 +17359,8 @@ bool Bot::RemoveHealRotationTarget( int index ) {
|
||||
}
|
||||
|
||||
void Bot::ClearHealRotationMembers() {
|
||||
_healRotationMemberPrev = NULL;
|
||||
_healRotationMemberNext = NULL;
|
||||
_healRotationMemberPrev = 0; // No previous member
|
||||
_healRotationMemberNext = 0; // No next member
|
||||
}
|
||||
|
||||
void Bot::ClearHealRotationTargets() {
|
||||
|
||||
14
zone/bot.h
14
zone/bot.h
@ -32,7 +32,7 @@ const int MaxSpellTypes = 16;
|
||||
const int MaxHealRotationMembers = 6;
|
||||
const int MaxHealRotationTargets = 3;
|
||||
|
||||
typedef enum BotStanceType {
|
||||
enum BotStanceType {
|
||||
BotStancePassive,
|
||||
BotStanceBalanced,
|
||||
BotStanceEfficient,
|
||||
@ -42,7 +42,7 @@ typedef enum BotStanceType {
|
||||
BotStanceBurnAE
|
||||
};
|
||||
|
||||
typedef enum SpellTypeIndex {
|
||||
enum SpellTypeIndex {
|
||||
SpellType_NukeIndex,
|
||||
SpellType_HealIndex,
|
||||
SpellType_RootIndex,
|
||||
@ -64,7 +64,7 @@ typedef enum SpellTypeIndex {
|
||||
class Bot : public NPC {
|
||||
public:
|
||||
// Class enums
|
||||
typedef enum BotfocusType { //focus types
|
||||
enum BotfocusType { //focus types
|
||||
BotfocusSpellHaste = 1,
|
||||
BotfocusSpellDuration,
|
||||
BotfocusRange,
|
||||
@ -97,18 +97,18 @@ public:
|
||||
BotfocusAdditionalHeal,
|
||||
};
|
||||
|
||||
typedef enum BotTradeType { // types of trades a bot can do
|
||||
enum BotTradeType { // types of trades a bot can do
|
||||
BotTradeClientNormal,
|
||||
BotTradeClientNoDropNoTrade
|
||||
};
|
||||
|
||||
typedef enum BotRoleType {
|
||||
enum BotRoleType {
|
||||
BotRoleMainAssist,
|
||||
BotRoleGroupHealer,
|
||||
BotRoleRaidHealer
|
||||
};
|
||||
|
||||
typedef enum EqExpansions {
|
||||
enum EqExpansions {
|
||||
ExpansionNone,
|
||||
ExpansionEQ,
|
||||
ExpansionRoK,
|
||||
@ -237,7 +237,7 @@ public:
|
||||
bool RemoveHealRotationTarget( Mob* target );
|
||||
bool RemoveHealRotationTarget( int index);
|
||||
void NotifyNextHealRotationMember( bool notifyNow = false );
|
||||
void ClearHealRotationLeader() { _healRotationLeader = NULL; }
|
||||
void ClearHealRotationLeader() { _healRotationLeader = 0; }
|
||||
void ClearHealRotationMembers();
|
||||
void ClearHealRotationTargets();
|
||||
inline virtual int16 GetMaxStat();
|
||||
|
||||
@ -3850,7 +3850,7 @@ void Client::Handle_OP_LDoNInspect(const EQApplicationPacket *app)
|
||||
void Client::Handle_OP_Dye(const EQApplicationPacket *app)
|
||||
{
|
||||
if(app->size!=sizeof(DyeStruct))
|
||||
printf("Wrong size of DyeStruct, Got: %i, Expected: %i\n",app->size,sizeof(DyeStruct));
|
||||
printf("Wrong size of DyeStruct, Got: %i, Expected: %lu\n",app->size,sizeof(DyeStruct));
|
||||
else{
|
||||
DyeStruct* dye = (DyeStruct*)app->pBuffer;
|
||||
DyeArmor(dye);
|
||||
@ -3921,7 +3921,7 @@ void Client::Handle_OP_GuildPublicNote(const EQApplicationPacket *app)
|
||||
|
||||
if (app->size < sizeof(GuildUpdate_PublicNote)) {
|
||||
// client calls for a motd on login even if they arent in a guild
|
||||
printf("Error: app size of %i < size of OP_GuildPublicNote of %i\n",app->size,sizeof(GuildUpdate_PublicNote));
|
||||
printf("Error: app size of %i < size of OP_GuildPublicNote of %lu\n",app->size,sizeof(GuildUpdate_PublicNote));
|
||||
return;
|
||||
}
|
||||
GuildUpdate_PublicNote* gpn=(GuildUpdate_PublicNote*)app->pBuffer;
|
||||
@ -3979,7 +3979,7 @@ void Client::Handle_OP_SetGuildMOTD(const EQApplicationPacket *app)
|
||||
|
||||
if (app->size != sizeof(GuildMOTD_Struct)) {
|
||||
// client calls for a motd on login even if they arent in a guild
|
||||
printf("Error: app size of %i != size of GuildMOTD_Struct of %i\n",app->size,sizeof(GuildMOTD_Struct));
|
||||
printf("Error: app size of %i != size of GuildMOTD_Struct of %lu\n",app->size,sizeof(GuildMOTD_Struct));
|
||||
return;
|
||||
}
|
||||
if(!IsInAGuild()) {
|
||||
@ -6876,7 +6876,7 @@ void Client::Handle_OP_DeleteSpell(const EQApplicationPacket *app)
|
||||
void Client::Handle_OP_LoadSpellSet(const EQApplicationPacket *app)
|
||||
{
|
||||
if(app->size!=sizeof(LoadSpellSet_Struct)) {
|
||||
printf("Wrong size of LoadSpellSet_Struct! Expected: %i, Got: %i\n",sizeof(LoadSpellSet_Struct),app->size);
|
||||
printf("Wrong size of LoadSpellSet_Struct! Expected: %lu, Got: %i\n",sizeof(LoadSpellSet_Struct),app->size);
|
||||
return;
|
||||
}
|
||||
int i;
|
||||
@ -6891,7 +6891,7 @@ void Client::Handle_OP_LoadSpellSet(const EQApplicationPacket *app)
|
||||
void Client::Handle_OP_PetitionBug(const EQApplicationPacket *app)
|
||||
{
|
||||
if(app->size!=sizeof(PetitionBug_Struct))
|
||||
printf("Wrong size of BugStruct! Expected: %i, Got: %i\n",sizeof(PetitionBug_Struct),app->size);
|
||||
printf("Wrong size of BugStruct! Expected: %lu, Got: %i\n",sizeof(PetitionBug_Struct),app->size);
|
||||
else{
|
||||
Message(0, "Petition Bugs are not supported, please use /bug.");
|
||||
}
|
||||
@ -6901,7 +6901,7 @@ void Client::Handle_OP_PetitionBug(const EQApplicationPacket *app)
|
||||
void Client::Handle_OP_Bug(const EQApplicationPacket *app)
|
||||
{
|
||||
if(app->size!=sizeof(BugStruct))
|
||||
printf("Wrong size of BugStruct got %d expected %d!\n", app->size, sizeof(BugStruct));
|
||||
printf("Wrong size of BugStruct got %d expected %lu!\n", app->size, sizeof(BugStruct));
|
||||
else{
|
||||
BugStruct* bug=(BugStruct*)app->pBuffer;
|
||||
database.UpdateBug(bug);
|
||||
@ -8306,7 +8306,7 @@ void Client::Handle_OP_OpenTributeMaster(const EQApplicationPacket *app)
|
||||
_pkt(TRIBUTE__IN, app);
|
||||
|
||||
if(app->size != sizeof(StartTribute_Struct))
|
||||
printf("Error in OP_OpenTributeMaster. Expected size of: %i, but got: %i\n",sizeof(StartTribute_Struct),app->size);
|
||||
printf("Error in OP_OpenTributeMaster. Expected size of: %lu, but got: %i\n",sizeof(StartTribute_Struct),app->size);
|
||||
else {
|
||||
//Opens the tribute master window
|
||||
StartTribute_Struct* st = (StartTribute_Struct*)app->pBuffer;
|
||||
@ -8331,7 +8331,7 @@ void Client::Handle_OP_OpenGuildTributeMaster(const EQApplicationPacket *app)
|
||||
_pkt(TRIBUTE__IN, app);
|
||||
|
||||
if(app->size != sizeof(StartTribute_Struct))
|
||||
printf("Error in OP_OpenGuildTributeMaster. Expected size of: %i, but got: %i\n",sizeof(StartTribute_Struct),app->size);
|
||||
printf("Error in OP_OpenGuildTributeMaster. Expected size of: %lu, but got: %i\n",sizeof(StartTribute_Struct),app->size);
|
||||
else {
|
||||
//Opens the guild tribute master window
|
||||
StartTribute_Struct* st = (StartTribute_Struct*)app->pBuffer;
|
||||
@ -8357,7 +8357,7 @@ void Client::Handle_OP_TributeItem(const EQApplicationPacket *app)
|
||||
|
||||
//player donates an item...
|
||||
if(app->size != sizeof(TributeItem_Struct))
|
||||
printf("Error in OP_TributeItem. Expected size of: %i, but got: %i\n",sizeof(StartTribute_Struct),app->size);
|
||||
printf("Error in OP_TributeItem. Expected size of: %lu, but got: %i\n",sizeof(StartTribute_Struct),app->size);
|
||||
else {
|
||||
TributeItem_Struct* t = (TributeItem_Struct*)app->pBuffer;
|
||||
|
||||
@ -8386,7 +8386,7 @@ void Client::Handle_OP_TributeMoney(const EQApplicationPacket *app)
|
||||
|
||||
//player donates money
|
||||
if(app->size != sizeof(TributeMoney_Struct))
|
||||
printf("Error in OP_TributeMoney. Expected size of: %i, but got: %i\n",sizeof(StartTribute_Struct),app->size);
|
||||
printf("Error in OP_TributeMoney. Expected size of: %lu, but got: %i\n",sizeof(StartTribute_Struct),app->size);
|
||||
else {
|
||||
TributeMoney_Struct* t = (TributeMoney_Struct*)app->pBuffer;
|
||||
|
||||
@ -8534,7 +8534,7 @@ void Client::Handle_OP_Ignore(const EQApplicationPacket *app)
|
||||
void Client::Handle_OP_FindPersonRequest(const EQApplicationPacket *app)
|
||||
{
|
||||
if(app->size != sizeof(FindPersonRequest_Struct))
|
||||
printf("Error in FindPersonRequest_Struct. Expected size of: %i, but got: %i\n",sizeof(FindPersonRequest_Struct),app->size);
|
||||
printf("Error in FindPersonRequest_Struct. Expected size of: %lu, but got: %i\n",sizeof(FindPersonRequest_Struct),app->size);
|
||||
else {
|
||||
FindPersonRequest_Struct* t = (FindPersonRequest_Struct*)app->pBuffer;
|
||||
|
||||
|
||||
@ -1812,7 +1812,7 @@ void Merc::AI_Process() {
|
||||
//now off hand
|
||||
if(GetTarget() && attack_dw_timer.Check() && CanThisClassDualWield()) {
|
||||
|
||||
int weapontype = NULL;
|
||||
int weapontype = 0; // No weapon type
|
||||
bool bIsFist = true;
|
||||
|
||||
if(bIsFist || ((weapontype != ItemType2HS) && (weapontype != ItemType2HPierce) && (weapontype != ItemType2HB))) {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user