This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <cstdint> | |
#include <algorithm> | |
#include <iostream> | |
#include <limits> | |
namespace anh { | |
namespace detail { | |
/// @TODO Remove quotes from around constexpr when visual studio begins | |
/// supporting that c++0x feature. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
This file is part of MMOServer. For more information, visit http://swganh.com | |
Copyright (c) 2006 - 2010 The SWG:ANH Team | |
MMOServer is free software: you can redistribute it and/or modify | |
it under the terms of the GNU General Public License as published by | |
the Free Software Foundation, either version 3 of the License, or | |
(at your option) any later version. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@echo off | |
SETLOCAL EnableDelayedExpansion | |
set "DEPS_BASE=%~dp0" | |
set "DEPS_DRIVE=%~d0" | |
%PROJECT_DRIVE% | |
cd %DEPS_BASE% | |
rem Build the environment and bail out if it fails |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/// When creating an instance of ServerDirectory with an invalid cluster name | |
/// an InvalidCluster exception is thrown. | |
TEST_F(ServerDirectoryTest, JoiningInvalidClusterThrowsException) { | |
auto datastore = make_shared<MockDatastore>(); | |
EXPECT_CALL(*datastore, findClusterByName("bad_cluster")) | |
.WillOnce(Return(nullptr)); | |
try { | |
ServerDirectory server_directory(datastore, "bad_cluster", "20050408-18:00"); | |
FAIL() << "An exception should be thrown when given an invalid cluster name"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
This file is part of SWGANH. For more information, visit http://swganh.com | |
Copyright (c) 2011 ANH Studios | |
SWGANH is free software: you can redistribute it and/or modify | |
it under the terms of the GNU General Public License as published by | |
the Free Software Foundation, either version 3 of the License, or | |
(at your option) any later version. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@echo off | |
:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: | |
:: build_server.bat | |
:: | |
:: Build's the project and produces a directory of all necesary executables and | |
:: dll's needed to run an instance of the server. | |
:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: | |
:: initialize build variables |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace Sub6\PilotNocBundle\Entity; | |
use Doctrine\Common\Collections\ArrayCollection; | |
/** | |
* @orm:Entity | |
* @orm:Table(name="server") | |
*/ | |
class Server |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
This file is part of ANHServer. For more information, visit http://swganh.com | |
Copyright (c) 2010 - 2011 ANH Studios | |
ANHServer is free software: you can redistribute it and/or modify | |
it under the terms of the GNU General Public License as published by | |
the Free Software Foundation, either version 3 of the License, or | |
(at your option) any later version. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Get the directory this file is in (the project base) | |
basedir=$(cd $(dirname $0) && pwd) | |
mysql=mysql # mysql executable | |
username= # mysql user | |
passwd= # mysql password | |
# parse the command line parameters |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
bool LoginManager::authenticateClient_( | |
LoginClient* client, | |
const std::string& username, | |
const std::string& password) const | |
{ | |
shared_ptr<sql::Connection> conn = database_manager_->getConnection("default"); | |
shared_ptr<sql::PreparedStatement> stmt( | |
conn->prepareStatement("CALL sp_ReturnUserAccount(?, ?)") | |
); |