Skip to content

Instantly share code, notes, and snippets.

View Naios's full-sized avatar

Denis Blank Naios

  • Germany
View GitHub Profile
@Naios
Naios / test.cpp
Created September 19, 2015 21:31
(npc1->move(point1) && npc2->move(point2) && npc3->move(point3) && npc4->move(point4))
.then([]
{
// ... do something
});
diff --git a/cmake/compiler/msvc/settings.cmake b/cmake/compiler/msvc/settings.cmake
index be8028d..b9de31e 100644
--- a/cmake/compiler/msvc/settings.cmake
+++ b/cmake/compiler/msvc/settings.cmake
@@ -84,3 +84,11 @@ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /Zm500")
# 'function' : member function does not override any base class virtual member function
# 'virtual_function' : no override available for virtual member function from base 'class'; function is hidden
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /we4263 /we4264")
+
+# TODO add message

h1. Introduction

TrinityCore is a rather complex and demanding software, and as such, it may seem quite daunting to install and maintain. This guide will attempt to describe and also practically show in details how to setup your server environment.\ Every step of the guide is divided in three tabs (probably more will follow) regarding different operating systems (mainly divided into LinuxOS X and Windows).

The guide has been divided into 5 steps, to make it more readable:

[Requirements]

[Core Installation]

[Databases Installation]

diff --git a/src/server/game/CMakeLists.txt b/src/server/game/CMakeLists.txt
index 60e8609..239e59d 100644
--- a/src/server/game/CMakeLists.txt
+++ b/src/server/game/CMakeLists.txt
@@ -23,27 +23,36 @@ GroupSources(${CMAKE_CURRENT_SOURCE_DIR})
add_definitions(-DTRINITY_API_EXPORT_GAME)
-add_library(game
- ${PRIVATE_PCH_SOURCE}
diff --git a/dep/protobuf/CMakeLists.txt b/dep/protobuf/CMakeLists.txt
index 5ea6a4e..3b2a7e1 100644
--- a/dep/protobuf/CMakeLists.txt
+++ b/dep/protobuf/CMakeLists.txt
@@ -57,7 +57,7 @@ else()
)
endif()
-add_library(protobuf STATIC ${protobuf_STAT_SRCS})
+add_library(protobuf ${protobuf_STAT_SRCS})
#include "TaskScheduler.h"
#include "Duration.h"
template<typename T, typename P>
std::function<void(TaskContext)> ExecuteWhen(T&& task, P&& predicate) {
return [=](TaskContext context) {
if (predicate())
task(std::move(context));
else
context.Repeat(Milliseconds(10));
@Naios
Naios / Expected.cpp
Last active July 10, 2016 12:57
My implementation of Expected/ErrorOr
/**
* Copyright 2016 Denis Blank <[email protected]>
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
00007ffb3e9da079() Unknown
000000eaf40e2970() Unknown
cccccccccccccccc() Unknown
cccccccccccccccc() Unknown
cccccccccccccccc() Unknown
000000ea90dcee10() Unknown
00007ffb3e9db90c() Unknown
000000eaf40e2970() Unknown
cccccccccccccccc() Unknown
cccccccccccccccc() Unknown
$ bloaty -n 200 -d symbols worldserver
VM SIZE FILE SIZE
-------------- --------------
55.6% 37.5Mi [Unmapped] 532Mi 94.8%
39.1% 26.3Mi [Other] 26.2Mi 4.7%
0.4% 256Ki opcodeTable 0 0.0%
0.2% 135Ki World::LoadConfigSettings 135Ki 0.0%
0.2% 132Ki World::SetInitialWorldSettings 132Ki 0.0%
0.1% 101Ki SmartScript::ProcessAction 101Ki 0.0%
0.1% 80.0Ki ObjectMgr::LoadQuests
@Naios
Naios / antlr4leak.log
Created January 9, 2017 00:02
Antlr4 memory leak
==5093== Memcheck, a memory error detector
==5093== Copyright (C) 2002-2015, and GNU GPL'd, by Julian Seward et al.
==5093== Using Valgrind-3.11.0 and LibVEX; rerun with -h for copyright info
==5093== Command: ./src/compiler
==5093==
==5093==
==5093== HEAP SUMMARY:
==5093== in use at exit: 87,136 bytes in 69 blocks
==5093== total heap usage: 32,825 allocs, 32,756 frees, 2,682,473 bytes allocated
==5093==