diff --git a/code/CMakeModules/FindDInput.cmake b/code/CMakeModules/FindDInput.cmake deleted file mode 100644 index 100650652..000000000 --- a/code/CMakeModules/FindDInput.cmake +++ /dev/null @@ -1,38 +0,0 @@ -# - Find DirectInput -# Find the DirectSound includes and libraries -# -# DINPUT_INCLUDE_DIR - where to find dinput.h -# DINPUT_LIBRARIES - List of libraries when using DirectInput. -# DINPUT_FOUND - True if DirectInput found. - -if(DINPUT_INCLUDE_DIR) - # Already in cache, be silent - set(DINPUT_FIND_QUIETLY TRUE) -endif(DINPUT_INCLUDE_DIR) - -find_path(DINPUT_INCLUDE_DIR dinput.h - "$ENV{DXSDK_DIR}" - "$ENV{DXSDK_DIR}/Include" -) - -find_library(DINPUT_LIBRARY - NAMES dinput dinput8 - PATHS - "$ENV{DXSDK_DIR}" - "$ENV{DXSDK_DIR}/Lib" - "$ENV{DXSDK_DIR}/Lib/x86" -) - -# Handle the QUIETLY and REQUIRED arguments and set DINPUT_FOUND to TRUE if -# all listed variables are TRUE. -include(FindPackageHandleStandardArgs) -find_package_handle_standard_args(DINPUT DEFAULT_MSG - DINPUT_INCLUDE_DIR DINPUT_LIBRARY) - -if(DINPUT_FOUND) - set(DINPUT_LIBRARIES ${DINPUT_LIBRARY}) -else(DINPUT_FOUND) - set(DINPUT_LIBRARIES) -endif(DINPUT_FOUND) - -mark_as_advanced(DINPUT_INCLUDE_DIR DINPUT_LIBRARY) diff --git a/code/CMakeModules/FindWindowsSDK.cmake b/code/CMakeModules/FindWindowsSDK.cmake index 8f6ed5772..1b2affb99 100644 --- a/code/CMakeModules/FindWindowsSDK.cmake +++ b/code/CMakeModules/FindWindowsSDK.cmake @@ -43,10 +43,13 @@ FOREACH(_VERSION ${WINSDK_VERSIONS}) DETECT_WINSDK_VERSION(${_VERSION}) ENDFOREACH(_VERSION) +SET(WINSDK_SUFFIX) + IF(TARGET_ARM) SET(WINSDK8_SUFFIX "arm") ELSEIF(TARGET_X64) SET(WINSDK8_SUFFIX "x64") + SET(WINSDK_SUFFIX "x64") ELSEIF(TARGET_X86) SET(WINSDK8_SUFFIX "x86") ENDIF(TARGET_ARM) @@ -133,7 +136,7 @@ FIND_PATH(WINSDK_SHARED_INCLUDE_DIR d3d9.h FIND_PATH(WINSDK_LIBRARY_DIR ComCtl32.lib HINTS ${WINSDK_DIR}/Lib/win8/um/${WINSDK8_SUFFIX} - ${WINSDK_DIR}/Lib + ${WINSDK_DIR}/Lib/${WINSDK_SUFFIX} ) # signtool is used to sign executables diff --git a/code/nel/samples/3d/nel_qt/nel_qt.cfg b/code/nel/samples/3d/nel_qt/nel_qt.cfg index b2c141f89..b87b4767a 100644 --- a/code/nel/samples/3d/nel_qt/nel_qt.cfg +++ b/code/nel/samples/3d/nel_qt/nel_qt.cfg @@ -6,7 +6,7 @@ GraphicsDriver = "OpenGL"; SoundDriver = "OpenAL"; SoundDevice = ""; LanguageCode = "en"; -QtStyle = "Cleanlooks"; +QtStyle = ""; FontName = "andbasr.ttf"; FontShadow = 1; BackgroundColor = { diff --git a/code/nel/src/misc/sstring.cpp b/code/nel/src/misc/sstring.cpp index 492a00db1..fe9332328 100644 --- a/code/nel/src/misc/sstring.cpp +++ b/code/nel/src/misc/sstring.cpp @@ -37,14 +37,13 @@ namespace NLMISC return token; } - uint i; + uint i, j; CSString result; // skip leading junk for (i=0;i #include #include @@ -44,16 +42,7 @@ #include #include -#include "nel/misc/debug.h" -#include "nel/misc/common.h" -#include "nel/misc/fast_mem.h" -#include "nel/misc/system_info.h" -#include "nel/misc/mem_displayer.h" -#include "nel/misc/stream.h" -#include "nel/misc/path.h" -#include "nel/misc/string_common.h" - -#ifdef NL_OS_WINDOWS +#ifdef _WIN32 #define NOMINMAX #include #include diff --git a/code/nel/tools/3d/plugin_max/nel_vertex_tree_paint/vertex_tree_paint.cpp b/code/nel/tools/3d/plugin_max/nel_vertex_tree_paint/vertex_tree_paint.cpp index 9c82f5421..a2465ba4c 100644 --- a/code/nel/tools/3d/plugin_max/nel_vertex_tree_paint/vertex_tree_paint.cpp +++ b/code/nel/tools/3d/plugin_max/nel_vertex_tree_paint/vertex_tree_paint.cpp @@ -217,7 +217,7 @@ LRESULT APIENTRY colorSwatchSubclassWndProc( case WM_LBUTTONUP: case WM_LBUTTONDBLCLK: { HWND hPanel = GetParent(hwnd); - LONG mod = GetWindowLongPtr(hPanel,GWLP_USERDATA); + LONG_PTR mod = GetWindowLongPtr(hPanel,GWLP_USERDATA); if (mod) { ((VertexPaint*)mod)->PaletteButton(hwnd); } @@ -424,9 +424,10 @@ void VertexPaint::BeginEditParams( IObjParam *ip, ULONG flags,Animatable *prev ) SendMessage(hParams, WM_POSTINIT, 0, 0); } - else { + else + { SetWindowLongPtr(hParams,GWLP_USERDATA,(LONG_PTR)this); - } + } iTint = SetupIntSpinner (hParams, IDC_TINT_SPIN, IDC_TINT, 0, 100, (int) (fTint*100.0f)); @@ -440,7 +441,7 @@ void VertexPaint::BeginEditParams( IObjParam *ip, ULONG flags,Animatable *prev ) // Force an eval to update caches. NotifyDependents(FOREVER, PART_VERTCOLOR, REFMSG_CHANGE); - } +} void VertexPaint::EndEditParams( IObjParam *ip, ULONG flags,Animatable *next) { diff --git a/code/ryzom/client/data/gamedev/interfaces_v3/player.lua b/code/ryzom/client/data/gamedev/interfaces_v3/player.lua index 062f09690..3827593b1 100644 --- a/code/ryzom/client/data/gamedev/interfaces_v3/player.lua +++ b/code/ryzom/client/data/gamedev/interfaces_v3/player.lua @@ -8,6 +8,12 @@ function getDbPropU(dbEntry) return value end +if string.find(_VERSION, "Lua 5.0") then + function math.fmod(a, b) + return math.mod(a, b) + end +end + ------------------------------------------------------------------------------------------------------------ -- create the game namespace without reseting if already created in an other file. if (game==nil) then diff --git a/code/ryzom/client/src/interface_v3/chat_window.cpp b/code/ryzom/client/src/interface_v3/chat_window.cpp index 24b1e15c6..e74392432 100644 --- a/code/ryzom/client/src/interface_v3/chat_window.cpp +++ b/code/ryzom/client/src/interface_v3/chat_window.cpp @@ -924,33 +924,28 @@ void CChatGroupWindow::removeAllFreeTellers() void CChatGroupWindow::saveFreeTeller(NLMISC::IStream &f) { f.serialVersion(2); - - uint32 nNbFreeTellerSaved = 0; - - f.serial(nNbFreeTellerSaved); - - // Don't save the free tellers - //// Save the free teller only if it is present in the friend list to avoid the only-growing situation - //// because free tellers are never deleted in game if we save/load all the free tellers, we just create more - //// and more container. - - //uint32 i, nNbFreeTellerSaved = 0; - //for (i = 0; i < _FreeTellers.size(); ++i) - // if (PeopleInterraction.FriendList.getIndexFromName(_FreeTellers[i]->getUCTitle()) != -1) - // nNbFreeTellerSaved++; - - //f.serial(nNbFreeTellerSaved); - - //for (i = 0; i < _FreeTellers.size(); ++i) - //{ - // CGroupContainer *pGC = _FreeTellers[i]; - // if (PeopleInterraction.FriendList.getIndexFromName(pGC->getUCTitle()) != -1) - // { - // ucstring sTitle = pGC->getUCTitle(); - // f.serial(sTitle); - // } - //} + // Save the free teller only if it is present in the friend list to avoid the only-growing situation + // because free tellers are never deleted in game if we save/load all the free tellers, we just create more + // and more container. + + uint32 i, nNbFreeTellerSaved = 0; + for (i = 0; i < _FreeTellers.size(); ++i) + if (PeopleInterraction.FriendList.getIndexFromName(_FreeTellers[i]->getUCTitle()) != -1) + nNbFreeTellerSaved++; + + f.serial(nNbFreeTellerSaved); + + for (i = 0; i < _FreeTellers.size(); ++i) + { + CGroupContainer *pGC = _FreeTellers[i]; + + if (PeopleInterraction.FriendList.getIndexFromName(pGC->getUCTitle()) != -1) + { + ucstring sTitle = pGC->getUCTitle(); + f.serial(sTitle); + } + } } //================================================================================= @@ -979,12 +974,11 @@ void CChatGroupWindow::loadFreeTeller(NLMISC::IStream &f) ucstring sTitle; f.serial(sTitle); - // Don't actually create the free teller - //CGroupContainer *pGC = createFreeTeller(sTitle, ""); + CGroupContainer *pGC = createFreeTeller(sTitle, ""); - //// With version 1 all tells are active because windows information have "title based" ids and no "sID based". - //if ((ver == 1) && (pGC != NULL)) - // pGC->setActive(false); + // With version 1 all tells are active because windows information have "title based" ids and no "sID based". + if ((ver == 1) && (pGC != NULL)) + pGC->setActive(false); } } diff --git a/code/ryzom/server/src/input_output_service/chat_manager.cpp b/code/ryzom/server/src/input_output_service/chat_manager.cpp index a4765c300..50c58fce6 100644 --- a/code/ryzom/server/src/input_output_service/chat_manager.cpp +++ b/code/ryzom/server/src/input_output_service/chat_manager.cpp @@ -636,6 +636,18 @@ void CChatManager::chat( const TDataSetRow& sender, const ucstring& ucstr ) { if (session->WriteRight) // player must have the right to speak in the channel { + // If universal channel check if player muted + if (session->getChan()->UniversalChannel) + { + if(_MutedUsers.find( eid ) != _MutedUsers.end()) + { + nldebug("IOSCM: chat The player %s:%x is muted", + TheDataset.getEntityId(sender).toString().c_str(), + sender.getIndex()); + return; + } + } + if (!session->getChan()->getDontBroadcastPlayerInputs()) { // add msg to the historic diff --git a/code/ryzom/tools/client/client_config/display_dlg.cpp b/code/ryzom/tools/client/client_config/display_dlg.cpp index 0c9c98a92..71faa2a58 100644 --- a/code/ryzom/tools/client/client_config/display_dlg.cpp +++ b/code/ryzom/tools/client/client_config/display_dlg.cpp @@ -47,14 +47,14 @@ uint CPUFrequency; bool GetGLInformation () { // *** INIT VARIABLES - + GLExtensions.clear (); GLRenderer = ""; GLVendor = ""; GLVersion = ""; // *** INIT OPENGL - + // Register a window class WNDCLASS wc; memset(&wc,0,sizeof(wc)); @@ -79,14 +79,14 @@ bool GetGLInformation () WndRect.right=100; WndRect.bottom=100; HWND hWnd = CreateWindow ( "RyzomGetGlInformation", - "", - WndFlags, - CW_USEDEFAULT,CW_USEDEFAULT, - WndRect.right,WndRect.bottom, - NULL, - NULL, - GetModuleHandle(NULL), - NULL); + "", + WndFlags, + CW_USEDEFAULT,CW_USEDEFAULT, + WndRect.right,WndRect.bottom, + NULL, + NULL, + GetModuleHandle(NULL), + NULL); if (!hWnd) return false; @@ -384,7 +384,7 @@ void CDisplayDlg::updateState () TextWnd1.EnableWindow (Windowed == 1); TextWnd2.EnableWindow (Windowed == 1); TextWnd3.EnableWindow (Windowed == 1); - + // Fill the combobox values ModeCtrl.ResetContent (); uint i; @@ -411,11 +411,11 @@ void CDisplayDlg::updateState () BOOL CDisplayDlg::OnInitDialog() { CDialog::OnInitDialog(); - + updateState (); - + return TRUE; // return TRUE unless you set the focus to a control - // EXCEPTION: OCX Property Pages should return FALSE + // EXCEPTION: OCX Property Pages should return FALSE } // *************************************************************************** diff --git a/code/ryzom/tools/server/brick_param_extractor/brick_param_extractor.cpp b/code/ryzom/tools/server/brick_param_extractor/brick_param_extractor.cpp index 0ff24e0f9..1a4257a99 100644 --- a/code/ryzom/tools/server/brick_param_extractor/brick_param_extractor.cpp +++ b/code/ryzom/tools/server/brick_param_extractor/brick_param_extractor.cpp @@ -490,6 +490,8 @@ void COutputFile::generateOutput() const outbuff+="/*\n"; outbuff+="\tFILE: "; outbuff+=_FileName+"\n\n"; + outbuff+="#ifndef RY_EGS_STATIC_BRICK_CPP_H\n"; + outbuff+="#define RY_EGS_STATIC_BRICK_CPP_H\n\n"; outbuff+="\tWARNING: This file is autogenerated - any modifications will be lost at next regeneration\n\n"; outbuff+="*/\n\n"; @@ -505,6 +507,8 @@ void COutputFile::generateOutput() const _Structures[i].generateOutput(outbuff); } + outbuff+="#endif\n\n"; + // read in the previous version of the output file char *inbuff=NULL; FILE *inf=fopen(_FileName.c_str(),"rb"); @@ -631,17 +635,11 @@ void COutputFile::CStruct::generateOutput(std::string &outbuff) const for (i=0;i<_Params.size();++i) { outbuff+="\t\t"; - outbuff+=_Params[i]._Name+"="; - if (_Params[i]._Type==COutputFile::INT) outbuff+="atoi("; - if (_Params[i]._Type==COutputFile::FLOAT) outbuff+="(float)atof("; - outbuff+="args["; + outbuff+="NLMISC::fromString(args["; if (i>100) outbuff+=('0'+((i/100)%10)); if (i>10) outbuff+=('0'+((i/10)%10)); outbuff+=('0'+(i%10)); - if (_Params[i]._Type==COutputFile::INT || _Params[i]._Type==COutputFile::FLOAT) - outbuff+="].c_str());\n"; - else - outbuff+="].c_str();\n"; + outbuff+="], "+_Params[i]._Name+");\n"; } outbuff+="\n"; outbuff+="\t\treturn *this;\n"; diff --git a/code/ryzom/tools/sheets_packer/stdpch.h b/code/ryzom/tools/sheets_packer/stdpch.h index 0ff801f72..df8f1370f 100644 --- a/code/ryzom/tools/sheets_packer/stdpch.h +++ b/code/ryzom/tools/sheets_packer/stdpch.h @@ -32,8 +32,6 @@ #include #include -//#include - #ifdef NL_OS_WINDOWS #define NOMINMAX #include