Jump to content

Foereaper

getMaNGOS Developer
  • Posts

    599
  • Joined

  • Last visited

  • Days Won

    1
  • Donations

    0.00 GBP 

Foereaper last won the day on May 14 2018

Foereaper had the most liked content!

About Foereaper

  • Birthday 01/01/1940

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

Foereaper's Achievements

Advanced Member

Advanced Member (3/3)

6

Reputation

1

Community Answers

  1. Since there's currently no tutorial in full for compiling and setting up a MaNGOS server on Windows, I'm brushing off the old dev21 build guide and updating it to be relatively current. If something needs to be changed, let me know and I'll do so. 1. INSTALLING DEPENDENCIES NOTE : Always use 64-bit version of dependencies where possible. There is no reason to compile and run the server in 32-bit mode unless you are restricted by OS or hardware. Install MySQL Community Server : MySQL :: Download MySQL Installer Install GitExtensions : Download Git Extensions from SourceForge.net Install OpenSSL : http://slproweb.com/products/Win32OpenSSL.html Download and install the FULL SSL version (not the one tagged Light) I would recommend installing both 32 and 64 bit OpenSSL libraries, this prevents future issues if you want to compile either 32 or 64 bit. If either of these say you are missing C++ redistributable packages, follow the prompts and install accordingly. Install CMake : https://cmake.org/download/ Get the latest Binary distribution for your platform 2. DOWNLOADING THE SOURCES For the sake of this tutorial we will be using Mangos Zero, but the same steps apply for One and Two. Change the GitHub links below accordingly. Create a folder named "Source" anywhere on your computer. This is the folder we will use to download the server and the database. Right click on the "Source" folder and click "Git Bash Here". Once the command prompt window opens, type in the following command and hit enter : git clone https://github.com/mangoszero/server --recursive -depth=1 This clones t he source as well as the submodules into the folder "Source/server". Once this is done, keep the command line window open and type the below command and hit enter : git clone https://github.com/mangoszero/database --recursive -depth=1 You should now have the database cloned to "Source/database", and you can close the command line window. 3. GENERATING THE BUILD FILES To generate the build files, which is what we will use to compile the server itself, open the CMake software you have previously installed on step 1. You now have two fields you need to fill in. Specifically : "Where is the source code : " In this field, you point to the "Source/server" folder you created earlier. (See below for example). "Where to build the binaries : " For this tutorial, we will use the same "Source" folder, however specify a new folder within "Source" and call it "build". (See below for example). http://i.imgur.com/4uRZCo5.png After you have filled in both of these fields, hit "Configure". This will also prompt you which compiler to use! Make sure you select the correct compiler ! If you for some reason change any of the default values after configuration, you need to click "Configure" again BEFORE going to the next step. Once configuration is done, hit "Generate". If this finished without any errors, proceed to the next step. If you did however receive any errors, most likely you are missing one of the dependencies, have pointed to the wrong folders or selected the wrong compiler. Usually the error message you receive will make enough sense for you to isolate the issue. If not, make a new thread and provide the full output showing the error. 4. BUILDING THE CORE Once the build files are generated, either click the Open Project button next to Generate, or go to your "Source/build" folder and open the file MaNGOS.sln. This will open Visual Studio and you build your server like normal. I would recommend to compile the core in Debug mode (default) as that will provide you with crash dumps should the core crash for whatever reason, making it easier for us to help you debug. Once the core is done compiling, the server binaries, tools etc is located inside the "Source/build/bin/" folder, under either Debug or Release, depending on your choice. Copy the following files to wherever you want to run the server from. For the sake of this tutorial, make a new folder somewhere on your computer and call it "Server". lua_scripts folder ace.dll ahbot.conf.dist libmysql.dll mangosd.conf.dist mangosd.exe realmd.conf.dist realmd.exe If you compiled in Debug mode, also copy the following files to the "Server" folder. ace.pdb mangosd.pdb realmd.pdb If the core built successfully, move to the next step. If you have any compile errors, please post a full log displaying the error messages. Warnings can be ignored for now. 4. EXTRACTING GAME DATA NOTE: Tools should ALWAYS be compiled under Release mode, unless you are told otherwise during support. Debug tools will take A LONG TIME. You have been warned. Inside the "Source/build/bin/" and either Release or Debug folder there will be a folder named "Tools". Enter this folder and copy the following files: ExtractResources.sh make_vmaps.bat map-extractor.exe mmap_exclude.txt MoveMapGen.sh movemap-generator.exe offemsh.txt vmap-assembler.exe vmap-extractor.exe Paste these into your WoW directory and run ExtractResources.sh. Follow the prompts to extract. This can take a LONG time depending on your computer. Once this is complete, copy the following folders to your "Server" folder. dbc maps mmaps vmaps 6. INSTALLING THE DATABASE Enter the database folder located at "Source/database" Run InstallDatabases.bat and follow the on screen prompts to install the base database. Do mind, this database is the base database and will require you to run updates accordingly. The updates can be found in the separate folders inside "Source/database", specifically "Character", "Realm" and "World". The server will always notify you when you run the server files from the "Server" folder whether your database is up to date or not. If updates are required, apply them using your preferred SQL tool, like sqlyog, heidisql etc. NOTE : It is not a problem if runnign server with a higher DB content version. 7. INSTALLING THE SERVER Once all the above steps are complete, you are ready to configure your server and start playing ! Go to your "Server" folder copy and and rename the following files : ahbot.conf.dist -> ahbot.conf (This file is optional, depending if you want to use the AH bot or not!) mangosd.conf.dist -> mangosd.conf realmd.conf.dist -> realmd.conf Open mangosd.conf and edit lines 66, 67 and 68 to reflect your database information. Open realmd.conf and edit line 110 to reflect your database information. All other edits to the config files are completely optional. At this point your server should be completely operational for a local test. If you have any other questions or require further support, please feel free to create a new thread for your specific issues on teh appropriate section (not on commenting this post).
  2. Save it to a Lua file, put it in your scripts folder, change local NpcId = 123 to whatever entry ID you want to use for your npc
  3. You can do this through a gossip script local NpcId = 123 -- Entry ID of your gossip creature local MenuId = 123 -- Unique ID to recognice player gossip menu among others local function OnGossipHello(event, player, object) player:GossipClearMenu() player:GossipMenuAddItem(0, "Level me to 70", 1, 1) player:GossipMenuAddItem(0, "Nevermind", 1, 0) player:GossipSendMenu(1, object, MenuId) end local function OnGossipSelect(event, player, object, sender, intid, code, menuid) if (intid == 1) then player:SetLevel(70) end player:GossipComplete() end RegisterCreatureGossipEvent(NpcId, 1, OnGossipHello) RegisterCreatureGossipEvent(NpcId, 2, OnGossipSelect) Very rudimentary script, you probably want to add some more checks like whether the player is already 70 etc, but I'll leave that up to you
  4. http://www.elunaengine.com/Global/PerformIngameSpawn.html PerformIngameSpawn has an optional variable after orientation you can use to save the creature to the database :)
  5. Xardion, I primarily do windows development, and I have that working properly, would you be interested in helping me out with the Linux side of things? Primarily testing, as I don't have a Linux test environment set up atm
  6. This might be a bit late, but I am currently working on implementing LuaSocket and LuaSec as officially supported modules for Eluna
  7. Like the error says, you are trying to compare a string to a number, change either of your variables to the desired type.
  8. Yes, what you did below would also work, the original example however stores the data specifically to a Lua table so the information can be used/re-used at a later time without having to query the database again. Instead of printing "datee" directly like you tried to, you would use the table DatabaseCache with the account ID as a key to call the specific information, like shown below: local DatabaseCache = {} local function LoadDatabase(event, player) local ExampleQuery = CharDBQuery("SELECT active, date FROM premium WHERE AccountId = "..player:GetAccountId()); if(ExampleQuery)then repeat DatabaseCache[player:GetAccountId()] = { active = ExampleQuery:GetUInt32(0), datee = ExampleQuery:GetUInt32(1) }; until not ExampleQuery:NextRow() end print(DatabaseCache[player:GetAccountId()].datee) end RegisterPlayerEvent(18, LoadDatabase) If you just want a single one-time use query, then you should do this: local function LoadDatabase(event, player) local resultado = CharDBQuery("SELECT active, date FROM premium WHERE AccountId = "..player:GetAccountId()) if(resultado) then local active, date = resultado:GetString(0), resultado:GetUInt32(1); end print (datee) end RegisterPlayerEvent(18, LoadDatabase)
  9. You need to update your query to select all the necessary information that you need, you're currently only selecting date, not everything else you need as well local DatabaseCache = {} local function LoadDatabase(event, player) local ExampleQuery = CharDBQuery("SELECT active, date FROM premium WHERE AccountId = "..player:GetAccountId()); if(ExampleQuery)then repeat DatabaseCache[player:GetAccountId()] = { active = ExampleQuery:GetUInt32(0), datee = ExampleQuery:GetUInt32(1) }; until not ExampleQuery:NextRow() end end RegisterPlayerEvent(18, LoadDatabase)
  10. Grumbo's VIP chat script isn't stand-alone, check the original repo for more information: https://github.com/BlackWolfsDen/Eluna-Grumboz_VIP_System-Complete
  11. As a side note, this will prevent EVERY error box from showing for any other program as well, as well for debug builds. Use at your own risk
  12. Glad to hear you got it working, and yeah, the service part is a bit iffy, I never actually bothered to try setting it up properly hehe.
  13. Yes, depending on your current database version and the expected database version, as seen in the world log during startup. It will tell you the structure you have and what is expected, and you run any updates from the update folder in correct order between those two points.
  14. You either have to connect to the database and execute the update sql files via a client like heidisql or sqlyog, or through the MySQL command line tool. Either works, though I prefer to use a client.
  15. It should be called world-server.log, log directory can be set in the configs
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. Privacy Policy Terms of Use