bumxd
-
Posts
728 -
Joined
-
Last visited
-
Days Won
1 -
Feedback
0%
Content Type
Forums
Store
Third Party - Providers Directory
Feature Plan
Release Notes
Docs
Events
Posts posted by bumxd
-
-
input_main.cpp: In member function 'int CInputMain::Chat(CHARACTER*, const char*, size_t)':input_main.cpp:698: error: 'chatbuf' was not declared in this scopeinput_main.cpp:736: error: 'g_iShoutLimitLevel' was not declared in this scopegmake: *** [OBJDIR/input_main.o] Error 1gmake: *** Waiting for unfinished jobs....
-
-
add it like this
char chatbuf_global[CHAT_MAX_LEN + 1]; int len = snprintf(chatbuf_global, sizeof(chatbuf), "%s %s : %s", (ch->IsGM()?colorbuf[0]:colorbuf[MINMAX(0, ch->GetEmpire(), 3)]), ch->GetName(), buf);
input_main.cpp: In member function 'int CInputMain::Chat(CHARACTER*, const char*, size_t)':input_main.cpp:747: error: 'chatbuf_global' was not declared in this scopeinput_main.cpp:747: warning: unused variable 'len'compile mining.cppcompile mob_manager.cppcompile monarch.cppgmake: *** [OBJDIR/input_main.o] Error 1gmake: *** Waiting for unfinished jobs....error..this code:static const char* colorbuf[]={"|cFFffa200|H|h[Team-Member]|h|r", "|cFFff0000|H|h[Shinsoo]|h|r", "|cFFffc700|H|h[Chunjo]|h|r", "|cFF000bff|H|h[Jinno]|h|r"}; int len = snprintf(chatbuf_global, sizeof(chatbuf), "%s %s : %s", (ch->IsGM()?colorbuf[0]:colorbuf[MINMAX(0, ch->GetEmpire(), 3)]), ch->GetName(), buf); char chatbuf_global[CHAT_MAX_LEN + 1];
747 linea:
int len = snprintf(chatbuf_global, sizeof(chatbuf), "%s %s : %s", (ch->IsGM()?colorbuf[0]:colorbuf[MINMAX(0, ch->GetEmpire(), 3)]), ch->GetName(), buf);
not like that , like this :
char chatbuf_global[CHAT_MAX_LEN + 1]; static const char* colorbuf[]={"|cFFffa200|H|h[Team-Member]|h|r", "|cFFff0000|H|h[Shinsoo]|h|r", "|cFFffc700|H|h[Chunjo]|h|r", "|cFF000bff|H|h[Jinno]|h|r"}; int len = snprintf(chatbuf_global, sizeof(chatbuf), "%s %s : %s", (ch->IsGM()?colorbuf[0]:colorbuf[MINMAX(0, ch->GetEmpire(), 3)]), ch->GetName(), buf);
chatbuf_global must be declared b4 len
In file included from char.cpp:25:shop_manager.h:40:7: warning: no newline at end of fileIn file included from char.cpp:62:PetSystem.h:163:31: warning: no newline at end of filechar.cpp:7211: warning: this decimal constant is unsigned only in ISO C90compile char_change_empire.cppcompile char_horse.cppIn file included from char_battle.cpp:27:shop_manager.h:40:7: warning: no newline at end of filecompile char_item.cppcompile char_manager.cppIn file included from char_horse.cpp:14:../../common/VnumHelper.h:59:32: warning: no newline at end of filecompile char_quickslot.cppIn file included from char_item.cpp:44:../../common/VnumHelper.h:59:32: warning: no newline at end of fileIn file included from char_item.cpp:47:belt_inventory_helper.h:108:42: warning: no newline at end of filecompile char_resist.cppcompile char_skill.cppcompile char_state.cppcompile PetSystem.cppcompile cmd.cppcompile cmd_emotion.cppcompile cmd_general.cppIn file included from char_state.cpp:25:../../common/VnumHelper.h:59:32: warning: no newline at end of filecompile cmd_gm.cppcompile cmd_oxevent.cppcompile config.cppcompile constants.cppIn file included from PetSystem.cpp:8:PetSystem.h:163:31: warning: no newline at end of fileIn file included from PetSystem.cpp:9:../../common/VnumHelper.h:59:32: warning: no newline at end of filePetSystem.cpp:637:2: warning: no newline at end of filecompile crc32.cppcompile cube.cppchar.cpp: In member function 'void CHARACTER::PointChange(BYTE, int, bool, bool)':char.cpp:3088: warning: comparison between signed and unsigned integer expressionsIn file included from cmd_general.cpp:36:../../common/VnumHelper.h:59:32: warning: no newline at end of filecompile db.cppIn file included from char_item.cpp:47:belt_inventory_helper.h: In static member function 'static BYTE CBeltInventoryHelper::GetBeltGradeByRefineLevel(int)':belt_inventory_helper.h:28: warning: comparison between signed and unsigned integer expressionschar_item.cpp: In member function 'bool CHARACTER::IsEmptyItemGrid(TItemPos, BYTE, int) const':char_item.cpp:640: warning: comparison is always false due to limited range of data typechar_item.cpp:666: warning: comparison is always false due to limited range of data typeconstants.cpp:276: warning: this decimal constant is unsigned only in ISO C90constants.cpp:277: warning: this decimal constant is unsigned only in ISO C90constants.cpp:278: warning: this decimal constant is unsigned only in ISO C90constants.cpp:279: warning: this decimal constant is unsigned only in ISO C90constants.cpp:280: warning: this decimal constant is unsigned only in ISO C90constants.cpp:281: warning: this decimal constant is unsigned only in ISO C90compile desc.cppchar_item.cpp: In member function 'bool CHARACTER::UseItemEx(CItem*, TItemPos)':char_item.cpp:2387: warning: format '%d' expects type 'int', but argument 6 has type 'long int'char_item.cpp:2391: warning: format '%d' expects type 'int', but argument 6 has type 'long int'char_item.cpp:2403: warning: format '%d' expects type 'int', but argument 5 has type 'long int'char_item.cpp:2407: warning: format '%d' expects type 'int', but argument 5 has type 'long int'char_item.cpp:2434: warning: format '%d' expects type 'int', but argument 6 has type 'long int'char_item.cpp:2442: warning: format '%d' expects type 'int', but argument 5 has type 'long int'char_item.cpp:5090: warning: comparison between signed and unsigned integer expressionschar_item.cpp: In member function 'bool CHARACTER::UseItem(TItemPos, TItemPos)':char_item.cpp:5162: warning: unused variable 'wDestCell'char_item.cpp:5163: warning: unused variable 'bDestInven'char_item.cpp: In member function 'bool CHARACTER::EquipItem(CItem*, int)':char_item.cpp:6167: warning: array subscript has type 'char'char_item.cpp: In member function 'void CHARACTER::BuffOnAttr_AddBuffsFromItem(CItem*)':char_item.cpp:6231: warning: comparison between signed and unsigned integer expressionschar_item.cpp: In member function 'void CHARACTER::BuffOnAttr_RemoveBuffsFromItem(CItem*)':char_item.cpp:6243: warning: comparison between signed and unsigned integer expressionscompile desc_client.cppcompile desc_manager.cppPetSystem.cpp: In member function 'virtual bool CPetActor::_UpdateFollowAI()':PetSystem.cpp:246: warning: unused variable 'bDoMoveAlone'PetSystem.cpp: In member function 'CPetActor* CPetSystem::Summon(DWORD, CItem*, const char*, bool, DWORD)':PetSystem.cpp:552: warning: unused variable 'petVID'char_item.cpp: In member function 'bool CHARACTER::CanEquipNow(CItem*, const TItemPos&, const TItemPos&)':char_item.cpp:7429: warning: unused variable 'itemType'char_item.cpp:7430: warning: unused variable 'itemSubType'compile desc_p2p.cppcompile dev_log.cppcompile dungeon.cppchar_state.cpp: In member function 'virtual void CHARACTER::StateMove()':char_state.cpp:901: warning: unused variable 'rider'compile empire_text_convert.cppdesc_client.cpp: In member function 'void CLIENT_DESC::UpdateChannelStatus(DWORD, bool)':desc_client.cpp:299: warning: comparison between signed and unsigned integer expressionscompile entity.cppcompile entity_view.cppcube.cpp: In function 'bool Cube_make(CHARACTER*)':cube.cpp:544: warning: comparison between signed and unsigned integer expressionscube.cpp: In function 'void Cube_MakeCubeInformationText()':cube.cpp:716: warning: unused variable 'npcVNUM'cube.cpp: In function 'bool Cube_InformationInitialize()':cube.cpp:783: warning: comparison between signed and unsigned integer expressionscmd_gm.cpp: In function 'void do_set_stat(CHARACTER*, const char*, int, int)':cmd_gm.cpp:3935: warning: NULL used in arithmeticchar_item.cpp: In member function 'bool CHARACTER::IsEmptyItemGrid(TItemPos, BYTE, int) const':char_item.cpp:679: warning: control reaches end of non-void functioncompile event.cppcompile event_queue.cppIn file included from desc_manager.cpp:15:ClientPackageCryptInfo.h:117:41: warning: no newline at end of fileIn file included from config.cpp:22:check_server.h: In static member function 'static bool CheckServer::CheckIp(const char*)':check_server.h:24: warning: comparison between signed and unsigned integer expressionsconfig.cpp: In function 'void config_init(const std::string&)':config.cpp:442: warning: NULL used in arithmeticconfig.cpp:466: warning: NULL used in arithmeticconfig.cpp:490: warning: NULL used in arithmeticconfig.cpp:512: warning: unused variable 'line'compile exchange.cppcompile file_loader.cppcompile fishing.cppcompile gm.cppcompile guild.cppchar_item.cpp: In member function 'void CHARACTER::BuffOnAttr_ValueChange(BYTE, BYTE, BYTE)':char_item.cpp:6278: warning: 'pBuff' may be used uninitialized in this functioncmd_gm.cpp: In function 'void do_use_item(CHARACTER*, const char*, int, int)':cmd_gm.cpp:4357: warning: 'cell' may be used uninitialized in this functioncmd_gm.cpp: In function 'void do_set_stat(CHARACTER*, const char*, int, int)':cmd_gm.cpp:3977: warning: 'n' may be used uninitialized in this functioncmd_gm.cpp: In function 'void do_mob_ld(CHARACTER*, const char*, int, int)':cmd_gm.cpp:855: warning: 'x' may be used uninitialized in this functioncmd_gm.cpp:855: warning: 'y' may be used uninitialized in this functioncompile guild_manager.cppcompile guild_war.cppcompile horse_rider.cppcompile horsename_manager.cppcompile input.cppcompile input_auth.cppcompile input_db.cppcompile input_login.cppcompile input_main.cppcompile input_p2p.cppIn file included from input_db.cpp:13:shop_manager.h:40:7: warning: no newline at end of fileinput_db.cpp:2722:2: warning: no newline at end of filecompile input_teen.cppcompile input_udp.cppcompile ip_ban.cppIn file included from input_main.cpp:16:shop_manager.h:40:7: warning: no newline at end of filecompile item.cppIn file included from item.cpp:22:belt_inventory_helper.h:108:42: warning: no newline at end of fileIn file included from item.cpp:23:../../common/VnumHelper.h:59:32: warning: no newline at end of fileitem.cpp:2087:2: warning: no newline at end of fileinput_auth.cpp: In member function 'int CInputAuth::auth_OpenID(const char*, const char*, char*)':input_auth.cpp:467: warning: unused variable 'last'In file included from item.cpp:22:belt_inventory_helper.h: In static member function 'static BYTE CBeltInventoryHelper::GetBeltGradeByRefineLevel(int)':belt_inventory_helper.h:28: warning: comparison between signed and unsigned integer expressionsitem.h: In constructor 'CItem::CItem(DWORD)':item.h:286: warning: 'CItem::m_pkRealTimeExpireEvent' will be initialized afteritem.h:283: warning: 'LPEVENT CItem::m_pkExpireEvent'item.cpp:25: warning: when initialized hereitem.cpp: In function 'const bool CanPutIntoRing(CItem*, CItem*)':item.cpp:1728: warning: unused variable 'vnum'item.cpp: In member function 'bool CItem::CanPutInto(CItem*)':item.cpp:1761: warning: comparison between signed and unsigned integer expressionsitem.cpp: In member function 'int CItem::GiveMoreTime_Per(float)':item.cpp:2017: warning: comparison between signed and unsigned integer expressionsitem.cpp:2019: warning: comparison between signed and unsigned integer expressionsitem.cpp: In member function 'int CItem::GiveMoreTime_Fix(DWORD)':item.cpp:2041: warning: comparison between signed and unsigned integer expressionsitem.cpp: In member function 'int CItem::GetDuration()':item.cpp:2072: warning: array subscript has type 'char'compile item_addon.cppcompile item_attribute.cppcompile item_manager.cppinput_main.cpp: In member function 'int CInputMain::Chat(CHARACTER*, const char*, size_t)':input_main.cpp:750: error: expected primary-expression before 'p'input_main.cpp:752: error: 'p' was not declared in this scopeinput_main.cpp:748: warning: unused variable 'len'gmake: *** [OBJDIR/input_main.o] Error 1gmake: *** Waiting for unfinished jobs....In file included from item_manager.cpp:21:../../common/VnumHelper.h:59:32: warning: no newline at end of fileitem_manager.cpp: In member function 'TItemTable* ITEM_MANAGER::GetTable(DWORD)':item_manager.cpp:604: warning: comparison between signed and unsigned integer expressionsroot@BddAdsa:/usr/src/mainline/Srcs/Server/game/src # -
add it like this
char chatbuf_global[CHAT_MAX_LEN + 1]; int len = snprintf(chatbuf_global, sizeof(chatbuf), "%s %s : %s", (ch->IsGM()?colorbuf[0]:colorbuf[MINMAX(0, ch->GetEmpire(), 3)]), ch->GetName(), buf);
input_main.cpp: In member function 'int CInputMain::Chat(CHARACTER*, const char*, size_t)':input_main.cpp:747: error: 'chatbuf_global' was not declared in this scopeinput_main.cpp:747: warning: unused variable 'len'compile mining.cppcompile mob_manager.cppcompile monarch.cppgmake: *** [OBJDIR/input_main.o] Error 1gmake: *** Waiting for unfinished jobs....error..this code:static const char* colorbuf[]={"|cFFffa200|H|h[Team-Member]|h|r", "|cFFff0000|H|h[Shinsoo]|h|r", "|cFFffc700|H|h[Chunjo]|h|r", "|cFF000bff|H|h[Jinno]|h|r"}; int len = snprintf(chatbuf_global, sizeof(chatbuf), "%s %s : %s", (ch->IsGM()?colorbuf[0]:colorbuf[MINMAX(0, ch->GetEmpire(), 3)]), ch->GetName(), buf); char chatbuf_global[CHAT_MAX_LEN + 1];
747 linea:
int len = snprintf(chatbuf_global, sizeof(chatbuf), "%s %s : %s", (ch->IsGM()?colorbuf[0]:colorbuf[MINMAX(0, ch->GetEmpire(), 3)]), ch->GetName(), buf);
-
this is the definition in your old code
char chatbuf_global[CHAT_MAX_LEN + 1];
just do this :
change
int len = snprintf(chatbuf, sizeof(chatbuf), "%s %s : %s", (ch->IsGM()?colorbuf[0]:colorbuf[MINMAX(0, ch->GetEmpire(), 3)]), ch->GetName(), buf);
to :
int len = snprintf(chatbuf_global, sizeof(chatbuf), "%s %s : %s", (ch->IsGM()?colorbuf[0]:colorbuf[MINMAX(0, ch->GetEmpire(), 3)]), ch->GetName(), buf);
and add this
char chatbuf_global[CHAT_MAX_LEN + 1];
above it
where add?char chatbuf_global[CHAT_MAX_LEN + 1];
-
-
input_main.cpp:752: error: 'chatbuf_global' was not declared in this scope
whats on line 752?
this problem in your function.. but here screen:
-
static const char* colorbuf[]={"|cFFffa200|H|h[Team-Member]|h|r", "|cFFff0000|H|h[Shinsoo]|h|r", "|cFFffc700|H|h[Chunjo]|h|r", "|cFF000bff|H|h[Jinno]|h|r"}; int len = snprintf(chatbuf, sizeof(chatbuf), "%s %s : %s", (ch->IsGM()?colorbuf[0]:colorbuf[MINMAX(0, ch->GetEmpire(), 3)]), ch->GetName(), buf);
they it
change global chat code for your?
me function change for this function?
don`t compile:
PetSystem.h:163:31: warning: no newline at end of filechar.cpp:7211: warning: this decimal constant is unsigned only in ISO C90compile char_change_empire.cppcompile char_horse.cppIn file included from char_battle.cpp:27:shop_manager.h:40:7: warning: no newline at end of filecompile char_item.cppcompile char_manager.cppIn file included from char_horse.cpp:14:../../common/VnumHelper.h:59:32: warning: no newline at end of filecompile char_quickslot.cppIn file included from char_item.cpp:44:../../common/VnumHelper.h:59:32: warning: no newline at end of fileIn file included from char_item.cpp:47:belt_inventory_helper.h:108:42: warning: no newline at end of filecompile char_resist.cppcompile char_skill.cppcompile char_state.cppcompile PetSystem.cppcompile cmd.cppcompile cmd_emotion.cppcompile cmd_general.cppcompile cmd_gm.cppcompile cmd_oxevent.cppIn file included from char_state.cpp:25:../../common/VnumHelper.h:59:32: warning: no newline at end of filecompile config.cppIn file included from cmd_general.cpp:36:../../common/VnumHelper.h:59:32: warning: no newline at end of filecompile constants.cppIn file included from PetSystem.cpp:8:PetSystem.h:163:31: warning: no newline at end of fileIn file included from PetSystem.cpp:9:../../common/VnumHelper.h:59:32: warning: no newline at end of filePetSystem.cpp:637:2: warning: no newline at end of filechar.cpp: In member function 'void CHARACTER::PointChange(BYTE, int, bool, bool)':char.cpp:3088: warning: comparison between signed and unsigned integer expressionscompile crc32.cppcompile cube.cppcompile db.cppcompile desc.cppconstants.cpp:276: warning: this decimal constant is unsigned only in ISO C90constants.cpp:277: warning: this decimal constant is unsigned only in ISO C90constants.cpp:278: warning: this decimal constant is unsigned only in ISO C90constants.cpp:279: warning: this decimal constant is unsigned only in ISO C90constants.cpp:280: warning: this decimal constant is unsigned only in ISO C90constants.cpp:281: warning: this decimal constant is unsigned only in ISO C90compile desc_client.cppcompile desc_manager.cppcompile desc_p2p.cppIn file included from char_item.cpp:47:belt_inventory_helper.h: In static member function 'static BYTE CBeltInventoryHelper::GetBeltGradeByRefineLevel(int)':belt_inventory_helper.h:28: warning: comparison between signed and unsigned integer expressionsIn file included from desc_manager.cpp:15:ClientPackageCryptInfo.h:117:41: warning: no newline at end of filechar_item.cpp: In member function 'bool CHARACTER::IsEmptyItemGrid(TItemPos, BYTE, int) const':char_item.cpp:640: warning: comparison is always false due to limited range of data typechar_item.cpp:666: warning: comparison is always false due to limited range of data typechar_item.cpp: In member function 'bool CHARACTER::UseItemEx(CItem*, TItemPos)':char_item.cpp:2387: warning: format '%d' expects type 'int', but argument 6 has type 'long int'char_item.cpp:2391: warning: format '%d' expects type 'int', but argument 6 has type 'long int'char_item.cpp:2403: warning: format '%d' expects type 'int', but argument 5 has type 'long int'char_item.cpp:2407: warning: format '%d' expects type 'int', but argument 5 has type 'long int'char_item.cpp:2434: warning: format '%d' expects type 'int', but argument 6 has type 'long int'char_item.cpp:2442: warning: format '%d' expects type 'int', but argument 5 has type 'long int'char_item.cpp:5090: warning: comparison between signed and unsigned integer expressionschar_item.cpp: In member function 'bool CHARACTER::UseItem(TItemPos, TItemPos)':char_item.cpp:5162: warning: unused variable 'wDestCell'char_item.cpp:5163: warning: unused variable 'bDestInven'char_item.cpp: In member function 'bool CHARACTER::EquipItem(CItem*, int)':char_item.cpp:6167: warning: array subscript has type 'char'char_item.cpp: In member function 'void CHARACTER::BuffOnAttr_AddBuffsFromItem(CItem*)':char_item.cpp:6231: warning: comparison between signed and unsigned integer expressionschar_item.cpp: In member function 'void CHARACTER::BuffOnAttr_RemoveBuffsFromItem(CItem*)':char_item.cpp:6243: warning: comparison between signed and unsigned integer expressionschar_item.cpp: In member function 'bool CHARACTER::CanEquipNow(CItem*, const TItemPos&, const TItemPos&)':char_item.cpp:7429: warning: unused variable 'itemType'char_item.cpp:7430: warning: unused variable 'itemSubType'compile dev_log.cppdesc_client.cpp: In member function 'void CLIENT_DESC::UpdateChannelStatus(DWORD, bool)':desc_client.cpp:299: warning: comparison between signed and unsigned integer expressionscube.cpp: In function 'bool Cube_make(CHARACTER*)':cube.cpp:544: warning: comparison between signed and unsigned integer expressionscube.cpp: In function 'void Cube_MakeCubeInformationText()':cube.cpp:716: warning: unused variable 'npcVNUM'cube.cpp: In function 'bool Cube_InformationInitialize()':cube.cpp:783: warning: comparison between signed and unsigned integer expressionsPetSystem.cpp: In member function 'virtual bool CPetActor::_UpdateFollowAI()':PetSystem.cpp:246: warning: unused variable 'bDoMoveAlone'PetSystem.cpp: In member function 'CPetActor* CPetSystem::Summon(DWORD, CItem*, const char*, bool, DWORD)':PetSystem.cpp:552: warning: unused variable 'petVID'compile dungeon.cppcompile empire_text_convert.cppIn file included from config.cpp:22:check_server.h: In static member function 'static bool CheckServer::CheckIp(const char*)':check_server.h:24: warning: comparison between signed and unsigned integer expressionsconfig.cpp: In function 'void config_init(const std::string&)':config.cpp:442: warning: NULL used in arithmeticconfig.cpp:466: warning: NULL used in arithmeticconfig.cpp:490: warning: NULL used in arithmeticconfig.cpp:512: warning: unused variable 'line'char_state.cpp: In member function 'virtual void CHARACTER::StateMove()':char_state.cpp:901: warning: unused variable 'rider'compile entity.cppchar_item.cpp: In member function 'bool CHARACTER::IsEmptyItemGrid(TItemPos, BYTE, int) const':char_item.cpp:679: warning: control reaches end of non-void functioncompile entity_view.cppcompile event.cppcmd_gm.cpp: In function 'void do_set_stat(CHARACTER*, const char*, int, int)':cmd_gm.cpp:3935: warning: NULL used in arithmeticcompile event_queue.cppcompile exchange.cppcompile file_loader.cppcompile fishing.cppcompile gm.cppcompile guild.cppcompile guild_manager.cppcompile guild_war.cppchar_item.cpp: In member function 'void CHARACTER::BuffOnAttr_ValueChange(BYTE, BYTE, BYTE)':char_item.cpp:6278: warning: 'pBuff' may be used uninitialized in this functioncmd_gm.cpp: In function 'void do_use_item(CHARACTER*, const char*, int, int)':cmd_gm.cpp:4357: warning: 'cell' may be used uninitialized in this functioncmd_gm.cpp: In function 'void do_set_stat(CHARACTER*, const char*, int, int)':cmd_gm.cpp:3977: warning: 'n' may be used uninitialized in this functioncmd_gm.cpp: In function 'void do_mob_ld(CHARACTER*, const char*, int, int)':cmd_gm.cpp:855: warning: 'x' may be used uninitialized in this functioncmd_gm.cpp:855: warning: 'y' may be used uninitialized in this functioncompile horse_rider.cppcompile horsename_manager.cppcompile input.cppcompile input_auth.cppcompile input_db.cppcompile input_login.cppcompile input_main.cppIn file included from input_db.cpp:13:shop_manager.h:40:7: warning: no newline at end of fileinput_db.cpp:2722:2: warning: no newline at end of filecompile input_p2p.cppIn file included from input_main.cpp:16:shop_manager.h:40:7: warning: no newline at end of fileinput_auth.cpp: In member function 'int CInputAuth::auth_OpenID(const char*, const char*, char*)':input_auth.cpp:467: warning: unused variable 'last'compile input_teen.cppcompile input_udp.cppcompile ip_ban.cppcompile item.cppcompile item_addon.cppcompile item_attribute.cppcompile item_manager.cppcompile item_manager_idrange.cppcompile locale.cppIn file included from item_manager.cpp:21:../../common/VnumHelper.h:59:32: warning: no newline at end of fileIn file included from item.cpp:22:belt_inventory_helper.h:108:42: warning: no newline at end of fileIn file included from item.cpp:23:../../common/VnumHelper.h:59:32: warning: no newline at end of fileitem.cpp:2087:2: warning: no newline at end of fileinput_main.cpp: In member function 'int CInputMain::Chat(CHARACTER*, const char*, size_t)':input_main.cpp:752: error: 'chatbuf_global' was not declared in this scopeinput_main.cpp:746: warning: unused variable 'len'compile locale_service.cppcompile log.cppgmake: *** [OBJDIR/input_main.o] Error 1gmake: *** Waiting for unfinished jobs....item_manager.cpp: In member function 'TItemTable* ITEM_MANAGER::GetTable(DWORD)':item_manager.cpp:604: warning: comparison between signed and unsigned integer expressionsIn file included from item.cpp:22:belt_inventory_helper.h: In static member function 'static BYTE CBeltInventoryHelper::GetBeltGradeByRefineLevel(int)':belt_inventory_helper.h:28: warning: comparison between signed and unsigned integer expressionsitem.h: In constructor 'CItem::CItem(DWORD)':item.h:286: warning: 'CItem::m_pkRealTimeExpireEvent' will be initialized afteritem.h:283: warning: 'LPEVENT CItem::m_pkExpireEvent'item.cpp:25: warning: when initialized hereitem.cpp: In function 'const bool CanPutIntoRing(CItem*, CItem*)':item.cpp:1728: warning: unused variable 'vnum'item.cpp: In member function 'bool CItem::CanPutInto(CItem*)':item.cpp:1761: warning: comparison between signed and unsigned integer expressionsitem.cpp: In member function 'int CItem::GiveMoreTime_Per(float)':item.cpp:2017: warning: comparison between signed and unsigned integer expressionsitem.cpp:2019: warning: comparison between signed and unsigned integer expressionsitem.cpp: In member function 'int CItem::GiveMoreTime_Fix(DWORD)':item.cpp:2041: warning: comparison between signed and unsigned integer expressionsitem.cpp: In member function 'int CItem::GetDuration()':item.cpp:2072: warning: array subscript has type 'char'root@BddAdsa:/usr/src/mainline/Srcs/Server/game/src # -
static const char* colorbuf[]={"|cFFffa200|H|h[Team-Member]|h|r", "|cFFff0000|H|h[Shinsoo]|h|r", "|cFFffc700|H|h[Chunjo]|h|r", "|cFF000bff|H|h[Jinno]|h|r"}; int len = snprintf(chatbuf, sizeof(chatbuf), "%s %s : %s", (ch->IsGM()?colorbuf[0]:colorbuf[MINMAX(0, ch->GetEmpire(), 3)]), ch->GetName(), buf);
they it
change global chat code for your?
me function change for this function?
-
me code:
const char* kingdoms[4] = {"|cFF47DA00|H|h[admin]|cFFA7FFD4|H|h","|cFFff0000|H|h[Shinsoo]|cFFA7FFD4|H|h","|cFFFFFF00|H|h[Chunjo]|cFFA7FFD4|H|h","|cFF0080FF|H|h[Jinno]|cFFA7FFD4|H|h"}; char chatbuf_global[CHAT_MAX_LEN + 1]; int my_level = ch->GetLevel(); if (gSpecialShout == 1) { if (ch->GetGMLevel() != GM_PLAYER) { if (MasterGhostChat == 1) { int len_global = snprintf(chatbuf_global, sizeof(chatbuf_global), "%s : %s",kingdoms[0], buf); } else { if ((MasterColorEmpire == 1) and (MasterLevelChat == 0)) { int len_global = snprintf(chatbuf_global, sizeof(chatbuf_global), "%s %s : %s",ch->GetName(), kingdoms[ch->GetEmpire()], buf); } else if ((MasterColorEmpire == 1) and (MasterLevelChat == 1)) { int len_global = snprintf(chatbuf_global, sizeof(chatbuf_global), "%s %s [%d] : %s",ch->GetName(), kingdoms[ch->GetEmpire()], my_level, buf); } else if ((MasterColorEmpire == 0) and (MasterLevelChat == 1)) { int len_global = snprintf(chatbuf_global, sizeof(chatbuf_global), "%s [%d] : %s",ch->GetName(), my_level, buf); } else { int len_global = snprintf(chatbuf_global, sizeof(chatbuf_global), "%s : %s",ch->GetName(), buf); } } } else { if ((PlayerColorEmpire == 1) and (PlayerLevelChat == 0)) { int len_global = snprintf(chatbuf_global, sizeof(chatbuf_global), "%s %s : %s",ch->GetName(), kingdoms[ch->GetEmpire()], buf); } else if ((PlayerColorEmpire == 1) and (PlayerLevelChat == 1)) { int len_global = snprintf(chatbuf_global, sizeof(chatbuf_global), "%s %s [%d] : %s",ch->GetName(), kingdoms[ch->GetEmpire()], my_level, buf); } else if ((PlayerColorEmpire == 0) and (PlayerLevelChat == 1)) { int len_global = snprintf(chatbuf_global, sizeof(chatbuf_global), "%s [%d] : %s",ch->GetName(), my_level, buf); } else { int len_global = snprintf(chatbuf_global, sizeof(chatbuf_global), "%s : %s",ch->GetName(), buf); } } } else { int len_global = snprintf(chatbuf_global, sizeof(chatbuf_global), "%s : %s",ch->GetName(), buf); }
-
-
static const char* colorbuf[]={"|cFFffa200|H|h[Team-Member]|h|r", "|cFFff0000|H|h[Shinsoo]|h|r", "|cFFffc700|H|h[Chunjo]|h|r", "|cFF000bff|H|h[Jinno]|h|r"}; int len = snprintf(chatbuf, sizeof(chatbuf), "%s %s : %s", (ch->IsGM()?colorbuf[0]:colorbuf[MINMAX(0, ch->GetEmpire(), 3)]), ch->GetName(), buf);
they it
change global chat code for your?
-
Just use the Code which is been released here in the Forum, this is working for me. If you have any further questions feel free to add me in Skype: pascal24426
Regards
i use this code what on forum.. but maybe i think codect need other?
-
-
-
0302 20:16:06292 :: CPythonSkill::RegisterSkillTable(locale/pl/SkillTable.txt) - NOT EXIST SkillDesc [Vnum:158 Line:56]0302 20:16:06292 :: CPythonSkill::RegisterSkillTable(locale/pl/SkillTable.txt) - NOT EXIST SkillDesc [Vnum:159 Line:57]0302 20:16:06293 :: CPythonSkill::RegisterSkillTable(locale/pl/SkillTable.txt) - NOT EXIST SkillDesc [Vnum:160 Line:58]0302 20:16:06293 :: CPythonSkill::RegisterSkillTable(locale/pl/SkillTable.txt) - NOT EXIST SkillDesc [Vnum:161 Line:59]0302 20:16:06293 :: CPythonSkill::RegisterSkillTable(locale/pl/SkillTable.txt) - NOT EXIST SkillDesc [Vnum:162 Line:60]0302 20:16:06293 :: CPythonSkill::RegisterSkillTable(locale/pl/SkillTable.txt) - NOT EXIST SkillDesc [Vnum:256 Line:61]0302 20:16:06293 :: CPythonSkill::RegisterSkillTable(locale/pl/SkillTable.txt) - NOT EXIST SkillDesc [Vnum:257 Line:62]0302 20:16:06293 :: CPythonSkill::RegisterSkillTable(locale/pl/SkillTable.txt) - NOT EXIST SkillDesc [Vnum:258 Line:63]0302 20:16:06293 :: CPythonSkill::RegisterSkillTable(locale/pl/SkillTable.txt) - NOT EXIST SkillDesc [Vnum:259 Line:64]0302 20:16:06293 :: CPythonSkill::RegisterSkillTable(locale/pl/SkillTable.txt) - NOT EXIST SkillDesc [Vnum:260 Line:65]0302 20:16:06294 :: CPythonSkill::RegisterSkillTable(locale/pl/SkillTable.txt) - NOT EXIST SkillDesc [Vnum:261 Line:66]0302 20:16:06294 :: CPythonSkill::RegisterSkillTable(locale/pl/SkillTable.txt) - NOT EXIST SkillDesc [Vnum:262 Line:67]0302 20:16:06294 :: CPythonSkill::RegisterSkillTable(locale/pl/SkillTable.txt) - NOT EXIST SkillDesc [Vnum:6 Line:77]0302 20:16:06294 :: CPythonSkill::RegisterSkillTable(locale/pl/SkillTable.txt) - NOT EXIST SkillDesc [Vnum:21 Line:78]replace skilldescskilltable.txtand for other error.. check your pcpc2effect maybe replace with other
- 1
-
You use this?
This is bugged on stack item
yes this.. but how fix stack?
bool CClientManager::InitializeItemTable() { char query[4096]; snprintf(query, sizeof(query), "SELECT vnum, vnum_range, name, %s, type, subtype, gold, shop_buy_price, weight, size, flag, wearflag, " "antiflag, immuneflag+0, refined_vnum, refine_set, magic_pct, socket_pct, addon_type, " "limittype0, limitvalue0, limittype1, limitvalue1, " "applytype0, applyvalue0, applytype1, applyvalue1, applytype2, applyvalue2, " "value0, value1, value2, value3, value4, value5 " "FROM item_proto%s ORDER BY vnum", g_stLocaleNameColumn.c_str(), GetTablePostfix()); std::auto_ptr<SQLMsg> pkMsg(CDBManager::instance().DirectQuery(query)); SQLResult * pRes = pkMsg->Get(); if (!pRes->uiNumRows) { sys_err("Could not load item_proto. No results!"); return false; } sys_log(0, "ITEM_PROTO loading..."); if (!m_vec_itemTable.empty()) { sys_log(0, "RELOAD: item_proto"); m_vec_itemTable.clear(); m_map_itemTableByVnum.clear(); } m_vec_itemTable.resize(pRes->uiNumRows); memset(&m_vec_itemTable[0], 0, sizeof(TItemTable) * m_vec_itemTable.size()); TItemTable * item_table = &m_vec_itemTable[0]; MYSQL_ROW data; int col; while ((data = mysql_fetch_row(pRes->pSQLResult))) { col = 0; str_to_number(item_table->dwVnum, data[col++]); str_to_number(item_table->dwVnumRange, data[col++]); strlcpy(item_table->szName, data[col++], sizeof(item_table->szName)); strlcpy(item_table->szLocaleName, data[col++], sizeof(item_table->szLocaleName)); str_to_number(item_table->bType, data[col++]); str_to_number(item_table->bSubType, data[col++]); str_to_number(item_table->dwGold, data[col++]); str_to_number(item_table->dwShopBuyPrice, data[col++]); str_to_number(item_table->bWeight, data[col++]); str_to_number(item_table->bSize, data[col++]); str_to_number(item_table->dwFlags, data[col++]); str_to_number(item_table->dwWearFlags, data[col++]); str_to_number(item_table->dwAntiFlags, data[col++]); str_to_number(item_table->dwImmuneFlag, data[col++]); str_to_number(item_table->dwRefinedVnum, data[col++]); str_to_number(item_table->wRefineSet, data[col++]); str_to_number(item_table->bAlterToMagicItemPct, data[col++]); str_to_number(item_table->bGainSocketPct, data[col++]); str_to_number(item_table->sAddonType, data[col++]); item_table->cLimitRealTimeFirstUseIndex = -1; item_table->cLimitTimerBasedOnWearIndex = -1; int i; for (i = 0; i < ITEM_LIMIT_MAX_NUM; ++i) { str_to_number(item_table->aLimits[i].bType, data[col++]); str_to_number(item_table->aLimits[i].lValue, data[col++]); if (LIMIT_REAL_TIME_START_FIRST_USE == item_table->aLimits[i].bType) item_table->cLimitRealTimeFirstUseIndex = (char)i; if (LIMIT_TIMER_BASED_ON_WEAR == item_table->aLimits[i].bType) item_table->cLimitTimerBasedOnWearIndex = (char)i; } for (i = 0; i < ITEM_APPLY_MAX_NUM; ++i) { str_to_number(item_table->aApplies[i].bType, data[col++]); str_to_number(item_table->aApplies[i].lValue, data[col++]); } for (i = 0; i < ITEM_VALUES_MAX_NUM; ++i) str_to_number(item_table->alValues[i], data[col++]); sys_log(1, "ITEM: #%-5lu %-24s %-24s VAL: %ld %ld %ld %ld %ld %ld WEAR %lu ANTI %lu IMMUNE %lu REFINE %lu REFINE_SET %u MAGIC_PCT %u", item_table->dwVnum,item_table->szName,item_table->szLocaleName, item_table->alValues[0],item_table->alValues[1],item_table->alValues[2], item_table->alValues[3],item_table->alValues[4],item_table->alValues[5], item_table->dwWearFlags,item_table->dwAntiFlags,item_table->dwImmuneFlag, item_table->dwRefinedVnum,item_table->wRefineSet,item_table->bAlterToMagicItemPct); m_map_itemTableByVnum.insert(std::map<DWORD, TItemTable *>::value_type(item_table->dwVnum, item_table)); ++item_table; } sort(m_vec_itemTable.begin(), m_vec_itemTable.end(), FCompareVnum()); sys_log(0, "CClientManager::InitializeMobTable:: %d items loaded.n", m_vec_itemTable.size()); return true; }
with your code i haven`t connect with server..item proto don`t load
-
you can fix it on me function?
bool CClientManager::InitializeItemTable()
{
/* I needed to make 2 mysql queries because with only 1 there was always a stackoverflow....
* However^^ It works so idc
*/
const char * c_ist_doof = "SELECT refined_vnum, refine_set, magic_pct FROM item_proto ORDER BY vnum";
SQLMsg* sqlMsg1 = CDBManager::instance().DirectQuery(c_ist_doof);
const char * query = "SELECT vnum, name, locale_name, type, subtype, weight, size, antiflag+0,"
"flag+0, wearflag+0, immuneflag+0, gold, shop_buy_price, refined_vnum,"
"refine_set, magic_pct, limittype0, limitvalue0, limittype1, limitvalue1,"
"applytype0, applyvalue0, applytype1, applyvalue1, applytype2, applyvalue2,"
"value0, value1, value2, value3, value4, value5, socket0, socket1, socket2,"
"socket3, socket4, socket5, specular, socket_pct, addon_type FROM item_proto ORDER BY vnum";
SQLMsg* sqlMsg = CDBManager::instance().DirectQuery(query);
MYSQL_RES* pRes1 = sqlMsg1->vec_pkResult[0]->pSQLResult;
MYSQL_RES* pRes = sqlMsg->vec_pkResult[0]->pSQLResult;
if (sizeof(pRes) <= 1 || sizeof(pRes1) <= 1)
{
sys_err("Kein Ergebnis aus Item_Proto!");
return false;
}
if (!m_vec_itemTable.empty()) {
sys_log(0, "Reloading Item_Proto");
m_vec_itemTable.clear();
}
MYSQL_ROW data;
MYSQL_ROW data1;
while ((data = mysql_fetch_row(pRes)) && (data1 = mysql_fetch_row(pRes1)))
{
TItemTable t;
TItemTable baum;
str_to_number(baum.dwRefinedVnum, data1[0]);
str_to_number(baum.wRefineSet, data1[1]);
str_to_number(baum.bAlterToMagicItemPct, data1[2]);
str_to_number(t.dwVnum, data[0]);
strlcpy(t.szName, data[1], sizeof(t.szName));
strlcpy(t.szLocaleName, data[2], sizeof(t.szLocaleName));
str_to_number(t.bType, data[3]);
str_to_number(t.bSubType, data[4]);
str_to_number(t.bWeight, data[5]);
str_to_number(t.bSize, data[6]);
str_to_number(t.dwAntiFlags, data[7]);
str_to_number(t.dwFlags, data[8]);
str_to_number(t.dwWearFlags, data[9]);
str_to_number(t.dwImmuneFlag, data[10]);
str_to_number(t.dwGold, data[11]);
str_to_number(t.dwShopBuyPrice,data[12]);
str_to_number(t.aLimits[0].bType, data[16]);
str_to_number(t.aLimits[0].lValue, data[17]);
str_to_number(t.aLimits[1].bType, data[18]);
str_to_number(t.aLimits[1].lValue, data[19]);
str_to_number(t.aApplies[0].bType, data[20]);
str_to_number(t.aApplies[0].lValue, data[21]);
str_to_number(t.aApplies[1].bType, data[22]);
str_to_number(t.aApplies[1].lValue, data[23]);
str_to_number(t.aApplies[2].bType, data[24]);
str_to_number(t.aApplies[2].lValue, data[25]);
str_to_number(t.alValues[0], data[26]);
str_to_number(t.alValues[1], data[27]);
str_to_number(t.alValues[2], data[28]);
str_to_number(t.alValues[3], data[29]);
str_to_number(t.alValues[4], data[30]);
str_to_number(t.alValues[5], data[31]);
str_to_number(t.alSockets[0], data[32]);
str_to_number(t.alSockets[1], data[33]);
str_to_number(t.alSockets[2], data[34]);
str_to_number(t.alSockets[3], data[35]);
str_to_number(t.alSockets[4], data[36]);
str_to_number(t.alSockets[5], data[37]);
str_to_number(t.bSpecular, data[38]);
str_to_number(t.bGainSocketPct, data[39]);
str_to_number(t.sAddonType, data[40]);
t.cLimitRealTimeFirstUseIndex = -1;
t.cLimitTimerBasedOnWearIndex = -1;
for (int i = 0; i < ITEM_LIMIT_MAX_NUM; ++i) {
if (LIMIT_REAL_TIME_START_FIRST_USE == t.aLimits.bType)
t.cLimitRealTimeFirstUseIndex = (char) i;
if (LIMIT_TIMER_BASED_ON_WEAR == t.aLimits.bType)
t.cLimitTimerBasedOnWearIndex = (char) i;
}
// Conversion
t.dwRefinedVnum = baum.dwRefinedVnum;
t.wRefineSet = baum.wRefineSet;
t.bAlterToMagicItemPct = baum.bAlterToMagicItemPct;
//Debug
//sys_log(0,"%d %d %d",t.dwRefinedVnum, t.wRefineSet, t.bAlterToMagicItemPct);
//sys_log(0,"%d %d %d",baum.dwRefinedVnum, baum.wRefineSet, baum.bAlterToMagicItemPct);
m_vec_itemTable.push_back(t);
}
m_map_itemTableByVnum.clear();
__gnu_cxx::__normal_iterator<SItemTable*, std::vector<SItemTable, std::allocator<SItemTable> > > it = m_vec_itemTable.begin();
while (it != m_vec_itemTable.end())
{
TItemTable * item_table = &(*(it++));
sys_log(0,"Item %s geladen", item_table->szLocaleName);
m_map_itemTableByVnum.insert(std::map<DWORD, TItemTable *>::value_type(item_table->dwVnum, item_table));
}
sort(m_vec_itemTable.begin(), m_vec_itemTable.end(), FCompareVnum());
return true;
}
-
You use this?
This is bugged on stack item
yes this.. but how fix stack?
bool CClientManager::InitializeItemTable() { char query[4096]; snprintf(query, sizeof(query), "SELECT vnum, vnum_range, name, %s, type, subtype, gold, shop_buy_price, weight, size, flag, wearflag, " "antiflag, immuneflag+0, refined_vnum, refine_set, magic_pct, socket_pct, addon_type, " "limittype0, limitvalue0, limittype1, limitvalue1, " "applytype0, applyvalue0, applytype1, applyvalue1, applytype2, applyvalue2, " "value0, value1, value2, value3, value4, value5 " "FROM item_proto%s ORDER BY vnum", g_stLocaleNameColumn.c_str(), GetTablePostfix()); std::auto_ptr<SQLMsg> pkMsg(CDBManager::instance().DirectQuery(query)); SQLResult * pRes = pkMsg->Get(); if (!pRes->uiNumRows) { sys_err("Could not load item_proto. No results!"); return false; } sys_log(0, "ITEM_PROTO loading..."); if (!m_vec_itemTable.empty()) { sys_log(0, "RELOAD: item_proto"); m_vec_itemTable.clear(); m_map_itemTableByVnum.clear(); } m_vec_itemTable.resize(pRes->uiNumRows); memset(&m_vec_itemTable[0], 0, sizeof(TItemTable) * m_vec_itemTable.size()); TItemTable * item_table = &m_vec_itemTable[0]; MYSQL_ROW data; int col; while ((data = mysql_fetch_row(pRes->pSQLResult))) { col = 0; str_to_number(item_table->dwVnum, data[col++]); str_to_number(item_table->dwVnumRange, data[col++]); strlcpy(item_table->szName, data[col++], sizeof(item_table->szName)); strlcpy(item_table->szLocaleName, data[col++], sizeof(item_table->szLocaleName)); str_to_number(item_table->bType, data[col++]); str_to_number(item_table->bSubType, data[col++]); str_to_number(item_table->dwGold, data[col++]); str_to_number(item_table->dwShopBuyPrice, data[col++]); str_to_number(item_table->bWeight, data[col++]); str_to_number(item_table->bSize, data[col++]); str_to_number(item_table->dwFlags, data[col++]); str_to_number(item_table->dwWearFlags, data[col++]); str_to_number(item_table->dwAntiFlags, data[col++]); str_to_number(item_table->dwImmuneFlag, data[col++]); str_to_number(item_table->dwRefinedVnum, data[col++]); str_to_number(item_table->wRefineSet, data[col++]); str_to_number(item_table->bAlterToMagicItemPct, data[col++]); str_to_number(item_table->bGainSocketPct, data[col++]); str_to_number(item_table->sAddonType, data[col++]); item_table->cLimitRealTimeFirstUseIndex = -1; item_table->cLimitTimerBasedOnWearIndex = -1; int i; for (i = 0; i < ITEM_LIMIT_MAX_NUM; ++i) { str_to_number(item_table->aLimits[i].bType, data[col++]); str_to_number(item_table->aLimits[i].lValue, data[col++]); if (LIMIT_REAL_TIME_START_FIRST_USE == item_table->aLimits[i].bType) item_table->cLimitRealTimeFirstUseIndex = (char)i; if (LIMIT_TIMER_BASED_ON_WEAR == item_table->aLimits[i].bType) item_table->cLimitTimerBasedOnWearIndex = (char)i; } for (i = 0; i < ITEM_APPLY_MAX_NUM; ++i) { str_to_number(item_table->aApplies[i].bType, data[col++]); str_to_number(item_table->aApplies[i].lValue, data[col++]); } for (i = 0; i < ITEM_VALUES_MAX_NUM; ++i) str_to_number(item_table->alValues[i], data[col++]); sys_log(1, "ITEM: #%-5lu %-24s %-24s VAL: %ld %ld %ld %ld %ld %ld WEAR %lu ANTI %lu IMMUNE %lu REFINE %lu REFINE_SET %u MAGIC_PCT %u", item_table->dwVnum,item_table->szName,item_table->szLocaleName, item_table->alValues[0],item_table->alValues[1],item_table->alValues[2], item_table->alValues[3],item_table->alValues[4],item_table->alValues[5], item_table->dwWearFlags,item_table->dwAntiFlags,item_table->dwImmuneFlag, item_table->dwRefinedVnum,item_table->wRefineSet,item_table->bAlterToMagicItemPct); m_map_itemTableByVnum.insert(std::map<DWORD, TItemTable *>::value_type(item_table->dwVnum, item_table)); ++item_table; } sort(m_vec_itemTable.begin(), m_vec_itemTable.end(), FCompareVnum()); sys_log(0, "CClientManager::InitializeMobTable:: %d items loaded.n", m_vec_itemTable.size()); return true; }
this without txt db?
-
item don`t stack.. how to fix?
-
You use this?
This is bugged on stack item
yes this.. but how fix stack?
-
anybody know how to fix?
-
-
filezilla : db / item_proto.txt
search 71094 add item_stack
me db from Navicat..no txt
[ Dead Download Link ] [C++]No txt on 40k [ We Need You ]
in Temporary
Posted
up