diff --git a/code/nel/src/gui/group_html.cpp b/code/nel/src/gui/group_html.cpp index 6274d67e5..cd2da9502 100644 --- a/code/nel/src/gui/group_html.cpp +++ b/code/nel/src/gui/group_html.cpp @@ -5566,7 +5566,7 @@ namespace NLGUI string suri = elm.getAttribute("href"); if(suri.find("ah:") == 0) { - if (_TrustedDomain) + if (_TrustedDomain || suri.find("ah:script:") == 0) _Link.back() = suri; } else @@ -6423,11 +6423,13 @@ namespace NLGUI void CGroupHTML::htmlOBJECTend(const CHtmlElement &elm) { - if (!_TrustedDomain) - return; + if (_ObjectType=="application/ryzom-data") { + if (!_TrustedDomain) + return; + if (!_ObjectData.empty()) { if (addBnpDownload(_ObjectData, _ObjectAction, _ObjectScript, _ObjectMD5Sum)) @@ -6437,6 +6439,20 @@ namespace NLGUI _ObjectScript.clear(); } } + else if (_ObjectType=="application/ryzom-tutorial") + { + while(strFindReplace(_ObjectScript, "[", "〈")); + while(strFindReplace(_ObjectScript, "]", "〉")); + CLuaManager::getInstance().executeLuaScript("\ngame:executeTutorial([["+_ObjectScript+"]])\n", true); + _ObjectScript.clear(); + } + else if (_ObjectType=="application/ryzom-script") + { + while(strFindReplace(_ObjectScript, "[", "〈")); + while(strFindReplace(_ObjectScript, "]", "〉")); + CLuaManager::getInstance().executeLuaScript("\ngame:executeRyzomScript([["+_ObjectScript+"]])\n", true); + _ObjectScript.clear(); + } _Object = false; } diff --git a/code/ryzom/client/src/client.cpp b/code/ryzom/client/src/client.cpp index e824f6529..4e933b6da 100644 --- a/code/ryzom/client/src/client.cpp +++ b/code/ryzom/client/src/client.cpp @@ -180,6 +180,7 @@ int main(int argc, char **argv) Args.setVersion(getDisplayVersion()); Args.setDescription("Ryzom client"); + Args.addArg("n", "nopatch", "value", "Use this to not use patch system"); Args.addArg("p", "profile", "id", "Use this profile to determine what directory to use by default"); Args.addAdditionalArg("login", "Login to use", true, false); Args.addAdditionalArg("password", "Password to use", true, false); diff --git a/code/ryzom/client/src/client_cfg.cpp b/code/ryzom/client/src/client_cfg.cpp index df1debee2..6758d440a 100644 --- a/code/ryzom/client/src/client_cfg.cpp +++ b/code/ryzom/client/src/client_cfg.cpp @@ -326,8 +326,8 @@ CClientConfig::CClientConfig() Local = false; // Default is Net Mode. FSHost = ""; // Default Host. - TexturesInterface.push_back("texture_interfaces_v3"); - TexturesInterfaceDXTC.push_back("texture_interfaces_dxtc"); + TexturesInterface.push_back("texture_interfaces_v3_2x"); + TexturesInterfaceDXTC.push_back("texture_interfaces_dxtc_2x"); TexturesOutGameInterface.push_back("texture_interfaces_v3_outgame_ui"); @@ -782,8 +782,8 @@ void CClientConfig::setValues() READ_STRINGVECTOR_FV(TexturesOutGameInterfaceDXTC); // interface textures ingame and r2 - READ_STRINGVECTOR_FV(TexturesInterface); - READ_STRINGVECTOR_FV(TexturesInterfaceDXTC); + //READ_STRINGVECTOR_FV(TexturesInterface); + //READ_STRINGVECTOR_FV(TexturesInterfaceDXTC); // interface files login menus READ_STRINGVECTOR_FV(XMLLoginInterfaceFiles); diff --git a/code/ryzom/client/src/client_sheets/sbrick_sheet.cpp b/code/ryzom/client/src/client_sheets/sbrick_sheet.cpp index 6eae652df..81bd338fa 100644 --- a/code/ryzom/client/src/client_sheets/sbrick_sheet.cpp +++ b/code/ryzom/client/src/client_sheets/sbrick_sheet.cpp @@ -549,6 +549,6 @@ bool CSBrickSheet::mustDisplayLevel() const // NB: Yoyo Hack. special interface with indexInFamily==63 means "want to display the level" return !( isMandatory() || isRoot() || - (BrickFamily>= BRICK_FAMILIES::BeginInterface && BrickFamily<= BRICK_FAMILIES::EndInterface && IndexInFamily!=63) || + //(BrickFamily>= BRICK_FAMILIES::BeginInterface && BrickFamily<= BRICK_FAMILIES::EndInterface && IndexInFamily!=63) || Level==0 ); } diff --git a/code/ryzom/client/src/connection.cpp b/code/ryzom/client/src/connection.cpp index 82564354e..b4d7b5296 100644 --- a/code/ryzom/client/src/connection.cpp +++ b/code/ryzom/client/src/connection.cpp @@ -193,6 +193,7 @@ bool hasPrivilegeG() { return (UserPrivileges.find(":G:") != std::string::npos); bool hasPrivilegeEM() { return (UserPrivileges.find(":EM:") != std::string::npos); } bool hasPrivilegeEG() { return (UserPrivileges.find(":EG:") != std::string::npos); } bool hasPrivilegeOBSERVER() { return (UserPrivileges.find(":OBSERVER:") != std::string::npos); } +bool hasPrivilegeTESTER() { return (UserPrivileges.find(":TESTER:") != std::string::npos); } // Restore the video mode (fullscreen for example) after the connection (done in a window) diff --git a/code/ryzom/client/src/connection.h b/code/ryzom/client/src/connection.h index 79a72fb0e..72a44d31c 100644 --- a/code/ryzom/client/src/connection.h +++ b/code/ryzom/client/src/connection.h @@ -52,6 +52,7 @@ bool hasPrivilegeEM(); bool hasPrivilegeEG(); bool hasPrivilegeVG(); bool hasPrivilegeOBSERVER(); +bool hasPrivilegeTESTER(); // connection with the server. (login, shard list, etc.). diff --git a/code/ryzom/client/src/far_tp.cpp b/code/ryzom/client/src/far_tp.cpp index 0a594e540..1c2a6e612 100644 --- a/code/ryzom/client/src/far_tp.cpp +++ b/code/ryzom/client/src/far_tp.cpp @@ -49,12 +49,12 @@ #include "login_progress_post_thread.h" #include "interface_v3/action_handler_base.h" #include "item_group_manager.h" +#include "nel/misc/cmd_args.h" #ifdef DEBUG_NEW #define new DEBUG_NEW #endif - using namespace NLMISC; using namespace NLNET; using namespace NL3D; @@ -210,6 +210,7 @@ extern bool IsInRingSession; extern void selectTipsOfTheDay (uint tips); #define BAR_STEP_TP 2 +extern NLMISC::CCmdArgs Args; CLoginStateMachine::TEvent CLoginStateMachine::waitEvent() { @@ -462,12 +463,14 @@ void CLoginStateMachine::run() case st_check_patch: /// check the data to check if patch needed CLoginProgressPostThread::getInstance().step(CLoginStep(LoginStep_PostLogin, "login_step_post_login")); - if (!ClientCfg.PatchWanted) + + if (!ClientCfg.PatchWanted || (Args.haveArg("n") && Args.getLongArg("nopatch").front() == "1")) { // client don't want to be patched ! _CurrentState = st_display_eula; break; } + initPatchCheck(); SM_BEGIN_EVENT_TABLE if (isBGDownloadEnabled()) @@ -1517,4 +1520,3 @@ void CFarTP::farTPmainLoop() if(welcomeWindow) initWelcomeWindow(); } - diff --git a/code/ryzom/client/src/game_context_menu.cpp b/code/ryzom/client/src/game_context_menu.cpp index 78e58c4b5..1306c0704 100644 --- a/code/ryzom/client/src/game_context_menu.cpp +++ b/code/ryzom/client/src/game_context_menu.cpp @@ -267,7 +267,7 @@ void CGameContextMenu::update() setupContextMenuCantTalk(); // can't talk by default - bool showGMOptions = (hasPrivilegeDEV() || hasPrivilegeSGM() || hasPrivilegeGM() || hasPrivilegeVG() || hasPrivilegeSG() || hasPrivilegeEM() || hasPrivilegeEG() || hasPrivilegeOBSERVER()); + bool showGMOptions = (hasPrivilegeDEV() || hasPrivilegeSGM() || hasPrivilegeGM() || hasPrivilegeVG() || hasPrivilegeSG() || hasPrivilegeEM() || hasPrivilegeEG() || hasPrivilegeOBSERVER() || hasPrivilegeTESTER()); if (_TextInvisible) _TextInvisible->setActive(showGMOptions); diff --git a/code/ryzom/client/src/interface_v3/dbctrl_sheet.cpp b/code/ryzom/client/src/interface_v3/dbctrl_sheet.cpp index 7b188742c..603d0aec6 100644 --- a/code/ryzom/client/src/interface_v3/dbctrl_sheet.cpp +++ b/code/ryzom/client/src/interface_v3/dbctrl_sheet.cpp @@ -1086,6 +1086,7 @@ void CDBCtrlSheet::clearIconBuffs() { _EnchantIcons.clear(); _BuffIcons.clear(); + _BoostIcons.clear(); } // *************************************************************************** @@ -1118,8 +1119,15 @@ void CDBCtrlSheet::infoReceived() if (brick) { if (!brick->isRoot() && !brick->isCredit() && !brick->isParameter()) + if (brick->BrickFamily == BRICK_FAMILIES::BSGMCB) // Boost of Allegories, use it as boost icon { if (!haveRoot) + _BoostIcons.push_back(SBuffIcon(rVR.getTextureIdFromName(brick->getIcon()), brick->IconColor)); + rVR.getTextureSizeFromId(_BoostIcons.back().TextureId, _BoostIcons.back().IconW, _BoostIcons.back().IconH); + } + else if (!brick->isRoot() && !brick->isCredit() && !brick->isParameter()) + { + if (!haveRoot && !brick->getIconBack().empty()) { _EnchantIcons.push_back(SBuffIcon(rVR.getTextureIdFromName(brick->getIconBack()), brick->IconBackColor)); rVR.getTextureSizeFromId(_EnchantIcons.back().TextureId, _EnchantIcons.back().IconW, _EnchantIcons.back().IconH); @@ -2444,10 +2452,17 @@ void CDBCtrlSheet::drawSheet (sint32 x, sint32 y, bool draging, bool showSelecti } yIcon -= hIcon; rVR.drawRotFlipBitmap(_RenderLayer + 1, xIcon, yIcon, wIcon, hIcon, 0, false, _EnchantIcons[0].TextureId, fastMulRGB(curSheetColor, _EnchantIcons[0].Color)); - rVR.drawRotFlipBitmap(_RenderLayer+1, xIcon, yIcon, wIcon, hIcon, 0, false, _EnchantIcons[i].TextureId, fastMulRGB(curSheetColor, _EnchantIcons[i].Color)); + rVR.drawRotFlipBitmap(_RenderLayer + 1, xIcon, yIcon, wIcon, hIcon, 0, false, _EnchantIcons[i].TextureId, fastMulRGB(curSheetColor, _EnchantIcons[i].Color)); + + + if ((i - 1) < _BoostIcons.size()) { + rVR.drawRotFlipBitmap(_RenderLayer + 2, xIcon+wIcon-_BoostIcons[i-1].IconW, yIcon, _BoostIcons[i-1].IconW, _BoostIcons[i-1].IconH, 0, false, _BoostIcons[i-1].TextureId, fastMulRGB(curSheetColor, _BoostIcons[i-1].Color)); + } } } + + // Draw Quality. -1 for lookandfeel. Draw it with global color if (_DispQuality != -1) { @@ -3804,6 +3819,7 @@ void CDBCtrlSheet::resetAllTexIDs() _ItemInfoChanged = true; _EnchantIcons.clear(); _BuffIcons.clear(); + _BoostIcons.clear(); } diff --git a/code/ryzom/client/src/interface_v3/dbctrl_sheet.h b/code/ryzom/client/src/interface_v3/dbctrl_sheet.h index f9a85dd05..0052335fb 100644 --- a/code/ryzom/client/src/interface_v3/dbctrl_sheet.h +++ b/code/ryzom/client/src/interface_v3/dbctrl_sheet.h @@ -682,6 +682,7 @@ protected: }; std::vector _BuffIcons; std::vector _EnchantIcons; + std::vector _BoostIcons; // Level Brick or Quality union diff --git a/code/ryzom/client/src/interface_v3/group_in_scene_bubble.cpp b/code/ryzom/client/src/interface_v3/group_in_scene_bubble.cpp index 2276eb506..015800173 100644 --- a/code/ryzom/client/src/interface_v3/group_in_scene_bubble.cpp +++ b/code/ryzom/client/src/interface_v3/group_in_scene_bubble.cpp @@ -28,6 +28,7 @@ #include "nel/gui/action_handler.h" #include "../entities.h" #include "nel/gui/group_paragraph.h" // For CCtrlLink +#include "nel/gui/view_bitmap.h" #include "../net_manager.h" #include "../string_manager_client.h" #include "../login.h" @@ -644,14 +645,42 @@ void CGroupInSceneBubbleManager::addMessagePopupCenter (const ucstring &message, "ui:interface", templateParams.empty()?NULL:&(templateParams[0]), (uint)templateParams.size()); if (group) { + ucstring finalMessage = message; + + ucstring::size_type pos = message.find(ucstring("|")); + if (pos != std::string::npos) + { + CViewBitmap *pViewIcon = dynamic_cast(group->getView("iconA")); + if (pViewIcon != NULL) + { + string texture = message.substr(0, pos).toString(); + pViewIcon->setTexture(texture); + } + + ucstring::size_type end = message.find(ucstring("|"), pos+1); + if (end != std::string::npos) + { + CViewBitmap *pViewIcon = dynamic_cast(group->getView("iconZ")); + if (pViewIcon != NULL) + { + string texture = message.substr(end+1).toString(); + pViewIcon->setTexture(texture); + } + finalMessage = message.substr(pos+1, end-pos-1); + } + else + finalMessage = message.substr(pos+1); + } + // Skill name CViewText *pViewName = dynamic_cast(group->getView("name")); if (pViewName != NULL) { - pViewName->setTextFormatTaged(message); + pViewName->setTextFormatTaged(finalMessage); pViewName->setColor (color); } + // Link to the interface CWidgetManager::getInstance()->addWindowToMasterGroup("ui:interface", group); CInterfaceGroup *pRoot = dynamic_cast(CWidgetManager::getInstance()->getElementFromId("ui:interface")); @@ -865,7 +894,7 @@ void CGroupInSceneBubbleManager::chatOpen (uint32 nUID, const ucstring &ucsText, textSize = endOfOriginal; } } - + // Output the message in a bubble bool show = false; diff --git a/code/ryzom/client/src/interface_v3/group_map.cpp b/code/ryzom/client/src/interface_v3/group_map.cpp index 9bae00d6c..35a1fc4e6 100644 --- a/code/ryzom/client/src/interface_v3/group_map.cpp +++ b/code/ryzom/client/src/interface_v3/group_map.cpp @@ -2654,7 +2654,7 @@ void CGroupMap::createContinentLandMarks() static void hideTeleportButtonsInPopupMenuIfNotEnoughPriv() { - bool showTeleport = (hasPrivilegeDEV() || hasPrivilegeSGM() || hasPrivilegeGM() || hasPrivilegeVG() || hasPrivilegeSG() || hasPrivilegeEM() || hasPrivilegeEG() || hasPrivilegeOBSERVER()); + bool showTeleport = (hasPrivilegeDEV() || hasPrivilegeSGM() || hasPrivilegeGM() || hasPrivilegeVG() || hasPrivilegeSG() || hasPrivilegeEM() || hasPrivilegeEG() || hasPrivilegeOBSERVER()|| hasPrivilegeTESTER()); CInterfaceManager *im = CInterfaceManager::getInstance(); CInterfaceElement *ie = CWidgetManager::getInstance()->getElementFromId("ui:interface:map_menu:teleport"); diff --git a/code/ryzom/client/src/interface_v3/group_quick_help.cpp b/code/ryzom/client/src/interface_v3/group_quick_help.cpp index 0b789fccf..e89967193 100644 --- a/code/ryzom/client/src/interface_v3/group_quick_help.cpp +++ b/code/ryzom/client/src/interface_v3/group_quick_help.cpp @@ -74,6 +74,8 @@ bool CGroupQuickHelp::submitEvent (const char *event) // Update the text updateParagraph (); + + CLuaManager::getInstance().executeLuaScript(toString("\ngame:processTutorialEvent(\"%s\")\n", event), true); } } return false; diff --git a/code/ryzom/client/src/interface_v3/interface_manager.cpp b/code/ryzom/client/src/interface_v3/interface_manager.cpp index e81785ea8..5231dc19a 100644 --- a/code/ryzom/client/src/interface_v3/interface_manager.cpp +++ b/code/ryzom/client/src/interface_v3/interface_manager.cpp @@ -2523,6 +2523,17 @@ void CInterfaceManager::displaySystemInfo(const ucstring &str, const string &cat CClientConfig::SSysInfoParam::TMode mode = CClientConfig::SSysInfoParam::Normal; CRGBA color = CRGBA::White; + ucstring cleanStr = str; + ucstring::size_type pos = str.find(ucstring("|")); + if (pos != std::string::npos) + { + ucstring::size_type end = str.find(ucstring("|"), pos+1); + if (end != std::string::npos) + cleanStr = str.substr(pos+1, end-pos-1); + else + cleanStr = str.substr(pos+1); + } + // If broadcast, parse lua code if (toLower(cat) == "bc" && str.size() > 3 && str[0]=='@' && str[1]=='L' && str[2]=='U' && str[3]=='A') { @@ -2542,11 +2553,11 @@ void CInterfaceManager::displaySystemInfo(const ucstring &str, const string &cat if (mode != CClientConfig::SSysInfoParam::OverOnly && mode != CClientConfig::SSysInfoParam::Around) { if (PeopleInterraction.SystemInfo) - PeopleInterraction.ChatInput.SystemInfo.displayMessage(str, color, 2); + PeopleInterraction.ChatInput.SystemInfo.displayMessage(cleanStr, color, 2); else { CPeopleInterraction::CSysMsg sysMsg; - sysMsg.Str = str; + sysMsg.Str = cleanStr; sysMsg.Cat = cat; PeopleInterraction.SystemMessageBuffer.push_back( sysMsg ); } @@ -2557,10 +2568,10 @@ void CInterfaceManager::displaySystemInfo(const ucstring &str, const string &cat // If over popup a string at the bottom of the screen if ((mode == CClientConfig::SSysInfoParam::Over) || (mode == CClientConfig::SSysInfoParam::OverOnly)) - InSceneBubbleManager.addMessagePopup(str, color); + InSceneBubbleManager.addMessagePopup(cleanStr, color); else if ( (mode == CClientConfig::SSysInfoParam::Around || mode == CClientConfig::SSysInfoParam::CenterAround) && PeopleInterraction.AroundMe.Window) - PeopleInterraction.ChatInput.AroundMe.displayMessage(str, color, 2); + PeopleInterraction.ChatInput.AroundMe.displayMessage(cleanStr, color, 2); } diff --git a/code/ryzom/client/src/interface_v3/lua_ihm_ryzom.cpp b/code/ryzom/client/src/interface_v3/lua_ihm_ryzom.cpp index 75b588ce0..ca5de98c8 100644 --- a/code/ryzom/client/src/interface_v3/lua_ihm_ryzom.cpp +++ b/code/ryzom/client/src/interface_v3/lua_ihm_ryzom.cpp @@ -184,6 +184,21 @@ private: REGISTER_ACTION_HANDLER(CHandlerLUA, "lua"); std::deque > CHandlerLUA::_UICallerStack; +// *************************************************************************** +class CHandlerSCRIPT : public IActionHandler +{ +public: + void execute(CCtrlBase *pCaller, const std::string &sParams) + { + string script = sParams; + while(strFindReplace(script, "[", "〈")); + while(strFindReplace(script, "]", "〉")); + strFindReplace(script, "|", "\n"); + CLuaManager::getInstance().executeLuaScript("\ngame:executeRyzomScript([["+script+"]])\n", true); + } +}; +REGISTER_ACTION_HANDLER(CHandlerSCRIPT, "script"); + // *************************************************************************** // Allow also to call script from expression static DECLARE_INTERFACE_USER_FCT(lua) @@ -566,6 +581,7 @@ void CLuaIHMRyzom::RegisterRyzomFunctions(NLGUI::CLuaState &ls) LUABIND_FUNC(isFullyPatched), LUABIND_FUNC(getSheetType), LUABIND_FUNC(getSheetShape), + LUABIND_FUNC(getCharacterSheetScale), LUABIND_FUNC(getSheetFamily), LUABIND_FUNC(getSheetName), LUABIND_FUNC(getFameIndex), @@ -3493,7 +3509,15 @@ std::string CLuaIHMRyzom::getSheetShape(const std::string &sheet) return ""; } +// *************************************************************************** +float CLuaIHMRyzom::getCharacterSheetScale(const std::string &sheet) +{ + const CEntitySheet *sheetPtr = SheetMngr.get(CSheetId(sheet)); + const CCharacterSheet *charSheet = dynamic_cast(sheetPtr); + if (charSheet) return charSheet->Scale; + return 1; +} // *************************************************************************** std::string CLuaIHMRyzom::getSheetFamily(const std::string &sheet) diff --git a/code/ryzom/client/src/interface_v3/lua_ihm_ryzom.h b/code/ryzom/client/src/interface_v3/lua_ihm_ryzom.h index f8db32363..d574efb68 100644 --- a/code/ryzom/client/src/interface_v3/lua_ihm_ryzom.h +++ b/code/ryzom/client/src/interface_v3/lua_ihm_ryzom.h @@ -205,6 +205,7 @@ private: static bool isFullyPatched(); static std::string getSheetType(const std::string &sheet); static std::string getSheetShape(const std::string &sheet); + static float getCharacterSheetScale(const std::string &sheet); static std::string getSheetFamily(const std::string &sheet); static std::string getSheetName(uint32 sheetId); static sint32 getFameIndex(const std::string &factionName); diff --git a/code/ryzom/client/src/net_manager.cpp b/code/ryzom/client/src/net_manager.cpp index 60a996954..ada437ec7 100644 --- a/code/ryzom/client/src/net_manager.cpp +++ b/code/ryzom/client/src/net_manager.cpp @@ -33,6 +33,7 @@ #include "game_share/chat_group.h" #include "game_share/character_summary.h" #include "game_share/sphrase_com.h" +#include "game_share/outpost.h" #include "game_share/msg_client_server.h" #include "game_share/ryzom_database_banks.h" #include "game_share/msg_encyclopedia.h" @@ -3205,9 +3206,11 @@ void impulseUserBars(NLMISC::CBitMemStream &impulse) void impulseOutpostChooseSide(NLMISC::CBitMemStream &impulse) { // read message + uint8 type; bool outpostInFire; bool playerGuildInConflict; bool playerGuildIsAttacker; + impulse.serial(type); impulse.serial(outpostInFire); impulse.serial(playerGuildInConflict); impulse.serial(playerGuildIsAttacker); @@ -3219,7 +3222,7 @@ void impulseOutpostChooseSide(NLMISC::CBitMemStream &impulse) impulse.serial( declTimer ); // start - OutpostManager.startPvpJoinProposal(outpostInFire, playerGuildInConflict, playerGuildIsAttacker, + OutpostManager.startPvpJoinProposal((OUTPOSTENUMS::TPVPType)type, outpostInFire, playerGuildInConflict, playerGuildIsAttacker, ownerGuildNameId, attackerGuildNameId, declTimer); } diff --git a/code/ryzom/client/src/outpost_manager.cpp b/code/ryzom/client/src/outpost_manager.cpp index 305cba650..12d0d545f 100644 --- a/code/ryzom/client/src/outpost_manager.cpp +++ b/code/ryzom/client/src/outpost_manager.cpp @@ -40,7 +40,7 @@ COutpostManager::COutpostManager() // *************************************************************************** -void COutpostManager::startPvpJoinProposal(bool outpostInFire, bool playerGuildInConflict, bool playerGuildIsAttacker, +void COutpostManager::startPvpJoinProposal(OUTPOSTENUMS::TPVPType type, bool outpostInFire, bool playerGuildInConflict, bool playerGuildIsAttacker, uint32 ownerGuildNameId, uint32 attackerGuildNameId, uint32 declTimer) { // reset counter that force player to be neutral (eg: 10 seconds) @@ -58,16 +58,28 @@ void COutpostManager::startPvpJoinProposal(bool outpostInFire, bool playerGuildI node= NLGUI::CDBManager::getInstance()->getDbProp("UI:TEMP:OUTPOST:PVP_PROPOSAL_DEFENDER"); if(node) node->setValue32(ownerGuildNameId); node= NLGUI::CDBManager::getInstance()->getDbProp("UI:TEMP:OUTPOST:PVP_PROPOSAL_TICK_END"); - if(node) node->setValue32(_EndTickForPvpJoinProposal); + if(node) node->setValue32(_EndTickForPvpJoinProposal); // open Popup CCtrlBase *ctrl = dynamic_cast(CWidgetManager::getInstance()->getElementFromId("ui:interface:join_pvp_outpost_proposal:content:random")); if (ctrl) - ctrl->setActive(outpostInFire); + ctrl->setActive(type != OUTPOSTENUMS::GVE && outpostInFire); + ctrl = dynamic_cast(CWidgetManager::getInstance()->getElementFromId("ui:interface:join_pvp_outpost_proposal:content:neutral")); if (ctrl) - ctrl->setActive(!outpostInFire); + ctrl->setActive(type == OUTPOSTENUMS::GVE || !outpostInFire); + + // GvE: only attacker guild can have the option + ctrl = dynamic_cast(CWidgetManager::getInstance()->getElementFromId("ui:interface:join_pvp_outpost_proposal:content:attack")); + if (ctrl && type == OUTPOSTENUMS::GVE) + ctrl->setActive(playerGuildIsAttacker); + + // GvE : No defend option + ctrl = dynamic_cast(CWidgetManager::getInstance()->getElementFromId("ui:interface:join_pvp_outpost_proposal:content:defend")); + if (ctrl && type == OUTPOSTENUMS::GVE) + ctrl->setActive(false); + CGroupContainer *pGC = dynamic_cast(CWidgetManager::getInstance()->getElementFromId("ui:interface:join_pvp_outpost_proposal")); if (pGC) diff --git a/code/ryzom/client/src/outpost_manager.h b/code/ryzom/client/src/outpost_manager.h index 3a1b59673..009a1221e 100644 --- a/code/ryzom/client/src/outpost_manager.h +++ b/code/ryzom/client/src/outpost_manager.h @@ -40,7 +40,7 @@ public: COutpostManager(); /// Called when the server ask to join for PVP in a Outpost Zone - void startPvpJoinProposal(bool outpostInFire, bool playerGuildInConflict, bool playerGuildIsAttacker, + void startPvpJoinProposal(OUTPOSTENUMS::TPVPType type, bool outpostInFire, bool playerGuildInConflict, bool playerGuildIsAttacker, uint32 ownerGuildNameId, uint32 attackerGuildNameId, uint32 declTimer); /// Called when the client answer to the join for PVP in a Outpost Zone diff --git a/code/ryzom/common/src/game_share/brick_families.cpp b/code/ryzom/common/src/game_share/brick_families.cpp index 684eb0d25..796a2f590 100644 --- a/code/ryzom/common/src/game_share/brick_families.cpp +++ b/code/ryzom/common/src/game_share/brick_families.cpp @@ -264,6 +264,19 @@ namespace BRICK_FAMILIES NL_STRING_CONVERSION_TABLE_ENTRY(BCOKARM02) NL_STRING_CONVERSION_TABLE_ENTRY(BCOKARR02) NL_STRING_CONVERSION_TABLE_ENTRY(BCOKART02) + NL_STRING_CONVERSION_TABLE_ENTRY(BCOMARM01) + NL_STRING_CONVERSION_TABLE_ENTRY(BCOMARR01) + NL_STRING_CONVERSION_TABLE_ENTRY(BCOMART01) + NL_STRING_CONVERSION_TABLE_ENTRY(BCOMARM02) + NL_STRING_CONVERSION_TABLE_ENTRY(BCOMARR02) + NL_STRING_CONVERSION_TABLE_ENTRY(BCOMART02) + NL_STRING_CONVERSION_TABLE_ENTRY(BCOGENM01) + NL_STRING_CONVERSION_TABLE_ENTRY(BCOGENR01) + NL_STRING_CONVERSION_TABLE_ENTRY(BCOGENT01) + NL_STRING_CONVERSION_TABLE_ENTRY(BCOGENM02) + NL_STRING_CONVERSION_TABLE_ENTRY(BCOGENR02) + NL_STRING_CONVERSION_TABLE_ENTRY(BCOGENT02) + // Faber options NL_STRING_CONVERSION_TABLE_ENTRY(BCOA) @@ -558,6 +571,7 @@ namespace BRICK_FAMILIES NL_STRING_CONVERSION_TABLE_ENTRY(BSCMC) NL_STRING_CONVERSION_TABLE_ENTRY(BSCMD) NL_STRING_CONVERSION_TABLE_ENTRY(BSGMC) + NL_STRING_CONVERSION_TABLE_ENTRY(BSGMCB) NL_STRING_CONVERSION_TABLE_ENTRY(BSXCA) diff --git a/code/ryzom/common/src/game_share/brick_families.h b/code/ryzom/common/src/game_share/brick_families.h index 49a73fbaa..be5f521d4 100644 --- a/code/ryzom/common/src/game_share/brick_families.h +++ b/code/ryzom/common/src/game_share/brick_families.h @@ -297,7 +297,20 @@ namespace BRICK_FAMILIES BCOKARM02, BCOKARR02, BCOKART02, - EndFaberMandatory = BCOKART02, + BCOMARM01, + BCOMARR01, + BCOMART01, + BCOMARM02, + BCOMARR02, + BCOMART02, + BCOGENM01, + BCOGENR01, + BCOGENT01, + BCOGENM02, + BCOGENR02, + BCOGENT02, + + EndFaberMandatory = BCOGENT02, // OPTION FABER BeginFaberOption, @@ -675,7 +688,8 @@ namespace BRICK_FAMILIES BSCMD, // heal Focus EndPowerParameter = BSCMD, - BSGMC, // jewels s2e0 + BSGMC, // allegories + BSGMCB, // boost allegories BeginMagicPowerCredit, BSXCA = BeginMagicPowerCredit, // recast time diff --git a/code/ryzom/common/src/game_share/fame.cpp b/code/ryzom/common/src/game_share/fame.cpp index 19c3cbb80..03bf10e45 100644 --- a/code/ryzom/common/src/game_share/fame.cpp +++ b/code/ryzom/common/src/game_share/fame.cpp @@ -633,7 +633,7 @@ sint32 CStaticFames::getStaticFameIndexed(uint factionIndex1, uint factionIndex2 if (factionIndex1 >= _FameTableSize || factionIndex2 >= _FameTableSize) { - nlwarning("FAME: CStaticFames::getStaticFame invalid faction, return 0"); + //nlwarning("FAME: CStaticFames::getStaticFame invalid faction, return 0"); return 0; } diff --git a/code/ryzom/common/src/game_share/magic_fx.h b/code/ryzom/common/src/game_share/magic_fx.h index 2a46475e8..414a6586a 100644 --- a/code/ryzom/common/src/game_share/magic_fx.h +++ b/code/ryzom/common/src/game_share/magic_fx.h @@ -136,6 +136,7 @@ namespace MAGICFX OtherFireWall = 14, TeleportKami = 15, // No effect aura TeleportKara = 16, // No effect aura + TeleportMarauder = 17, // No effect aura }; } diff --git a/code/ryzom/common/src/game_share/outpost.cpp b/code/ryzom/common/src/game_share/outpost.cpp index b2cbde97f..db7425c57 100644 --- a/code/ryzom/common/src/game_share/outpost.cpp +++ b/code/ryzom/common/src/game_share/outpost.cpp @@ -32,6 +32,8 @@ namespace OUTPOSTENUMS NL_STRING_CONVERSION_TABLE_ENTRY(PVP) NL_STRING_CONVERSION_TABLE_ENTRY(RVR) NL_STRING_CONVERSION_TABLE_ENTRY(Full) + NL_STRING_CONVERSION_TABLE_ENTRY(GVE) + NL_STRING_CONVERSION_TABLE_ENTRY(GVG) NL_STRING_CONVERSION_TABLE_ENTRY(UnknownPVPType) NL_END_STRING_CONVERSION_TABLE(TPVPType, StaticCOutpostTPVPTypeConversion, UnknownPVPType) diff --git a/code/ryzom/common/src/game_share/outpost.h b/code/ryzom/common/src/game_share/outpost.h index a951d1afb..391779ad0 100644 --- a/code/ryzom/common/src/game_share/outpost.h +++ b/code/ryzom/common/src/game_share/outpost.h @@ -50,7 +50,9 @@ namespace OUTPOSTENUMS PVE, // can only be attacked if the outpost is held by a tribe and if the attacking guild comes from the same continent as the outpost PVP, // can only be attacked if the attacking guild comes from the same continent as the outpost RVR, // can only be attacked if the attacking guild comes from another continent as the outpost - Full // same as RVR but cant be set by the high council + Full, // same as RVR but cant be set by the high council + GVE, // Only one guild vs tribes + GVG, // Only one guild vs another guild }; enum TPVPSide diff --git a/code/ryzom/common/src/game_share/player_visual_properties.h b/code/ryzom/common/src/game_share/player_visual_properties.h index e6fa05762..14f245d97 100644 --- a/code/ryzom/common/src/game_share/player_visual_properties.h +++ b/code/ryzom/common/src/game_share/player_visual_properties.h @@ -37,7 +37,7 @@ struct SPropVisualA uint64 JacketColor : 3; // max: 8 current: 8 uint64 TrouserModel : 8; // max: 256 current: 104 uint64 TrouserColor : 3; // max: 8 current: 8 - uint64 WeaponRightHand : 10; // max: 1024 current: 457 + uint64 WeaponRightHand : 10; // max: 1024 current: 625 uint64 WeaponLeftHand : 8; // max: 256 current: 63 uint64 ArmModel : 8; // max: 256 current: 94 uint64 ArmColor : 3; // max: 8 current: 8