Merge branch 'master' into develop
This commit is contained in:
@@ -6,7 +6,8 @@ This game is inspired by classic 2D RPGs (Final Fantasy, The Legend of Zelda), a
|
||||
|
||||
## Releases
|
||||
|
||||
The most recent stable build for Windows can be found [here](https://dl.dropboxusercontent.com/u/46669050/Tortuga.rar).
|
||||
* The most recent stable build for Windows can be found [here](https://dl.dropboxusercontent.com/u/46669050/Tortuga-win.rar).
|
||||
* The most recent stable build for Linux can be found [here](https://dl.dropboxusercontent.com/u/46669050/Tortuga-linux.tar).
|
||||
|
||||
## Documentation
|
||||
|
||||
@@ -16,13 +17,14 @@ The most recent stable build for Windows can be found [here](https://dl.dropboxu
|
||||
## External Dependencies
|
||||
|
||||
* [SDL 1.2](http://www.libsdl.org/) - Simple DirectMedia Layer API
|
||||
* [SDL_net 1.2](http://www.libsdl.org/projects/SDL_net/) - SDL's networking extension
|
||||
* [SDL_net 2.0](http://www.libsdl.org/projects/SDL_net/) - SDL's networking extension
|
||||
* [lua 5.2](http://www.lua.org/) - The lua programming language
|
||||
* [SQLite3](http://www.sqlite.org/) - A lightweight SQL database engine
|
||||
|
||||
## Tools
|
||||
|
||||
* [WinRAR](http://www.rarlab.com/) - The best compression tool available IMO; only needed for distribution
|
||||
* [WinRAR](http://www.rarlab.com/) - The best compression tool available IMO; only needed for Windows distribution
|
||||
* [Dropbox](https://www.dropbox.com/) - For hosting and distribution
|
||||
|
||||
## Copyright
|
||||
|
||||
|
||||
@@ -27,6 +27,7 @@
|
||||
#include <stdexcept>
|
||||
#include <chrono>
|
||||
#include <iostream>
|
||||
#include <sstream>
|
||||
|
||||
//-------------------------
|
||||
//Scene headers
|
||||
@@ -57,7 +58,9 @@ void ClientApplication::Init(int argc, char* argv[]) {
|
||||
|
||||
//initialize SDL
|
||||
if (SDL_Init(SDL_INIT_VIDEO)) {
|
||||
throw(std::runtime_error("Failed to initialize SDL"));
|
||||
std::ostringstream os;
|
||||
os << "Failed to initialize SDL: " << SDL_GetError();
|
||||
throw(std::runtime_error(os.str()));
|
||||
}
|
||||
std::cout << "Initialized SDL" << std::endl;
|
||||
|
||||
|
||||
@@ -30,8 +30,3 @@ $(OUTDIR):
|
||||
|
||||
$(OBJDIR)/%.o: %.cpp
|
||||
$(CXX) $(CXXFLAGS) -c -o $@ $<
|
||||
|
||||
clean:
|
||||
$(RM) *.o *.a *.exe
|
||||
|
||||
rebuild: clean all
|
||||
|
||||
@@ -30,8 +30,3 @@ $(OUTDIR):
|
||||
|
||||
$(OBJDIR)/%.o: %.cpp
|
||||
$(CXX) $(CXXFLAGS) -c -o $@ $<
|
||||
|
||||
clean:
|
||||
$(RM) *.o *.a *.exe
|
||||
|
||||
rebuild: clean all
|
||||
|
||||
@@ -30,8 +30,3 @@ $(OUTDIR):
|
||||
|
||||
$(OBJDIR)/%.o: %.cpp
|
||||
$(CXX) $(CXXFLAGS) -c -o $@ $<
|
||||
|
||||
clean:
|
||||
$(RM) *.o *.a *.exe
|
||||
|
||||
rebuild: clean all
|
||||
|
||||
@@ -23,6 +23,7 @@
|
||||
|
||||
#include "channels.hpp"
|
||||
|
||||
#include <cstring>
|
||||
#include <iostream>
|
||||
#include <sstream>
|
||||
#include <stdexcept>
|
||||
|
||||
@@ -22,11 +22,12 @@
|
||||
#include "world.hpp"
|
||||
|
||||
#include "channels.hpp"
|
||||
|
||||
#include "terminal_error.hpp"
|
||||
|
||||
#include <stdexcept>
|
||||
#include <algorithm>
|
||||
#include <cmath>
|
||||
#include <cstring>
|
||||
#include <iostream>
|
||||
#include <sstream>
|
||||
|
||||
|
||||
+7
-1
@@ -1,5 +1,5 @@
|
||||
#include directories
|
||||
INCLUDES+=. client_utilities entities gameplay_scenes menu_scenes ../common/debugging ../common/gameplay ../common/graphics ../common/map ../common/network ../common/network/packet_types ../common/ui ../common/utilities
|
||||
INCLUDES+=SDL . client_utilities entities gameplay_scenes menu_scenes ../common/debugging ../common/gameplay ../common/graphics ../common/map ../common/network ../common/network/packet_types ../common/ui ../common/utilities
|
||||
|
||||
#libraries
|
||||
#the order of the $(LIBS) is important, at least for MinGW
|
||||
@@ -45,6 +45,12 @@ $(OBJDIR)/%.o: %.cpp
|
||||
$(CXX) $(CXXFLAGS) -c -o $@ $<
|
||||
|
||||
clean:
|
||||
ifeq ($(OS),Windows_NT)
|
||||
$(RM) *.o *.a *.exe
|
||||
else ifeq ($(shell uname), Linux)
|
||||
find . -type f -name *.o -exec rm -f -r -v {} \;
|
||||
find . -type f -name *.a -exec rm -f -r -v {} \;
|
||||
rm -f -v out/client out/server
|
||||
endif
|
||||
|
||||
rebuild: clean all
|
||||
|
||||
@@ -30,8 +30,3 @@ $(OUTDIR):
|
||||
|
||||
$(OBJDIR)/%.o: %.cpp
|
||||
$(CXX) $(CXXFLAGS) -c -o $@ $<
|
||||
|
||||
clean:
|
||||
$(RM) *.o *.a *.exe
|
||||
|
||||
rebuild: clean all
|
||||
|
||||
@@ -30,8 +30,3 @@ $(OUTDIR):
|
||||
|
||||
$(OBJDIR)/%.o: %.cpp
|
||||
$(CXX) $(CXXFLAGS) -c -o $@ $<
|
||||
|
||||
clean:
|
||||
$(RM) *.o *.a *.exe
|
||||
|
||||
rebuild: clean all
|
||||
|
||||
@@ -30,8 +30,3 @@ $(OUTDIR):
|
||||
|
||||
$(OBJDIR)/%.o: %.cpp
|
||||
$(CXX) $(CXXFLAGS) -c -o $@ $<
|
||||
|
||||
clean:
|
||||
$(RM) *.o *.a *.exe
|
||||
|
||||
rebuild: clean all
|
||||
|
||||
@@ -30,8 +30,3 @@ $(OUTDIR):
|
||||
|
||||
$(OBJDIR)/%.o: %.cpp
|
||||
$(CXX) $(CXXFLAGS) -c -o $@ $<
|
||||
|
||||
clean:
|
||||
$(RM) *.o *.a *.exe
|
||||
|
||||
rebuild: clean all
|
||||
|
||||
@@ -6,8 +6,3 @@ all:
|
||||
$(MAKE) -C network
|
||||
$(MAKE) -C ui
|
||||
$(MAKE) -C utilities
|
||||
|
||||
clean:
|
||||
$(RM) *.o *.a *.exe
|
||||
|
||||
rebuild: clean all
|
||||
|
||||
@@ -30,8 +30,3 @@ $(OUTDIR):
|
||||
|
||||
$(OBJDIR)/%.o: %.cpp
|
||||
$(CXX) $(CXXFLAGS) -c -o $@ $<
|
||||
|
||||
clean:
|
||||
$(RM) *.o *.a *.exe
|
||||
|
||||
rebuild: clean all
|
||||
|
||||
@@ -31,8 +31,3 @@ $(OUTDIR):
|
||||
|
||||
$(OBJDIR)/%.o: %.cpp
|
||||
$(CXX) $(CXXFLAGS) -c -o $@ $<
|
||||
|
||||
clean:
|
||||
$(RM) *.o *.a *.exe
|
||||
|
||||
rebuild: clean all
|
||||
|
||||
@@ -30,8 +30,3 @@ $(OUTDIR):
|
||||
|
||||
$(OBJDIR)/%.o: %.cpp
|
||||
$(CXX) $(CXXFLAGS) -c -o $@ $<
|
||||
|
||||
clean:
|
||||
$(RM) *.o *.a *.exe
|
||||
|
||||
rebuild: clean all
|
||||
|
||||
@@ -24,7 +24,7 @@
|
||||
|
||||
#include "serial_packet_type.hpp"
|
||||
|
||||
#include "SDL/SDL_net.h"
|
||||
#include "SDL_net.h"
|
||||
|
||||
constexpr int PACKET_STRING_SIZE = 100;
|
||||
|
||||
|
||||
@@ -27,7 +27,7 @@
|
||||
#include "singleton.hpp"
|
||||
|
||||
//APIs
|
||||
#include "SDL/SDL_net.h"
|
||||
#include "SDL_net.h"
|
||||
|
||||
class UDPNetworkUtility : public Singleton<UDPNetworkUtility> {
|
||||
public:
|
||||
|
||||
@@ -30,8 +30,3 @@ $(OUTDIR):
|
||||
|
||||
$(OBJDIR)/%.o: %.cpp
|
||||
$(CXX) $(CXXFLAGS) -c -o $@ $<
|
||||
|
||||
clean:
|
||||
$(RM) *.o *.a *.exe
|
||||
|
||||
rebuild: clean all
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
#ifndef IPOPERATORS_HPP_
|
||||
#define IPOPERATORS_HPP_
|
||||
|
||||
#include "SDL/SDL_net.h"
|
||||
#include "SDL_net.h"
|
||||
|
||||
//these should've come standard
|
||||
bool operator==(IPaddress lhs, IPaddress rhs);
|
||||
|
||||
@@ -30,8 +30,3 @@ $(OUTDIR):
|
||||
|
||||
$(OBJDIR)/%.o: %.cpp
|
||||
$(CXX) $(CXXFLAGS) -c -o $@ $<
|
||||
|
||||
clean:
|
||||
$(RM) *.o *.a *.exe
|
||||
|
||||
rebuild: clean all
|
||||
|
||||
@@ -19,13 +19,23 @@ release: clean all package
|
||||
|
||||
#For use on my machine ONLY
|
||||
package:
|
||||
rar a -r -ep Tortuga.rar $(OUTDIR)/*.exe $(OUTDIR)/*.dll
|
||||
rar a -r Tortuga.rar rsc/* copyright.txt instructions.txt
|
||||
ifeq ($(OS),Windows_NT)
|
||||
rar a -r -ep Tortuga-win.rar $(OUTDIR)/*.exe $(OUTDIR)/*.dll
|
||||
rar a -r Tortuga-win.rar rsc/* copyright.txt instructions.txt
|
||||
else ifeq ($(shell uname), Linux)
|
||||
tar -C $(OUTDIR) -zcvf Tortuga-linux.tar client server ../rsc ../copyright.txt ../instructions.txt
|
||||
endif
|
||||
|
||||
$(OUTDIR):
|
||||
mkdir $(OUTDIR)
|
||||
|
||||
clean:
|
||||
ifeq ($(OS),Windows_NT)
|
||||
$(RM) *.o *.a *.exe
|
||||
else ifeq ($(shell uname), Linux)
|
||||
find . -type f -name *.o -exec rm -f -r -v {} \;
|
||||
find . -type f -name *.a -exec rm -f -r -v {} \;
|
||||
rm -f -v out/client out/server
|
||||
endif
|
||||
|
||||
rebuild: clean all
|
||||
|
||||
@@ -30,8 +30,3 @@ $(OUTDIR):
|
||||
|
||||
$(OBJDIR)/%.o: %.cpp
|
||||
$(CXX) $(CXXFLAGS) -c -o $@ $<
|
||||
|
||||
clean:
|
||||
$(RM) *.o *.a *.exe
|
||||
|
||||
rebuild: clean all
|
||||
|
||||
@@ -26,6 +26,7 @@
|
||||
#include "character_defines.hpp"
|
||||
|
||||
#include <algorithm>
|
||||
#include <cstring>
|
||||
#include <stdexcept>
|
||||
|
||||
//-------------------------
|
||||
|
||||
@@ -30,8 +30,3 @@ $(OUTDIR):
|
||||
|
||||
$(OBJDIR)/%.o: %.cpp
|
||||
$(CXX) $(CXXFLAGS) -c -o $@ $<
|
||||
|
||||
clean:
|
||||
$(RM) *.o *.a *.exe
|
||||
|
||||
rebuild: clean all
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
#ifndef CLIENTDATA_HPP_
|
||||
#define CLIENTDATA_HPP_
|
||||
|
||||
#include "SDL/SDL_net.h"
|
||||
#include "SDL_net.h"
|
||||
|
||||
#include <chrono>
|
||||
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
#include "server_packet.hpp"
|
||||
#include "singleton.hpp"
|
||||
|
||||
#include "SDL/SDL_net.h"
|
||||
#include "SDL_net.h"
|
||||
|
||||
#include <functional>
|
||||
#include <list>
|
||||
|
||||
@@ -30,8 +30,3 @@ $(OUTDIR):
|
||||
|
||||
$(OBJDIR)/%.o: %.cpp
|
||||
$(CXX) $(CXXFLAGS) -c -o $@ $<
|
||||
|
||||
clean:
|
||||
$(RM) *.o *.a *.exe
|
||||
|
||||
rebuild: clean all
|
||||
|
||||
@@ -30,8 +30,3 @@ $(OUTDIR):
|
||||
|
||||
$(OBJDIR)/%.o: %.cpp
|
||||
$(CXX) $(CXXFLAGS) -c -o $@ $<
|
||||
|
||||
clean:
|
||||
$(RM) *.o *.a *.exe
|
||||
|
||||
rebuild: clean all
|
||||
|
||||
+11
-1
@@ -1,5 +1,5 @@
|
||||
#include directories
|
||||
INCLUDES+=. accounts characters clients entities monsters rooms server_utilities triggers ../common/debugging ../common/gameplay ../common/map ../common/network ../common/network/packet_types ../common/utilities
|
||||
INCLUDES+=SDL . accounts characters clients entities monsters rooms server_utilities triggers ../common/debugging ../common/gameplay ../common/map ../common/network ../common/network/packet_types ../common/utilities
|
||||
|
||||
#libraries
|
||||
#the order of the $(LIBS) is important, at least for MinGW
|
||||
@@ -8,6 +8,10 @@ ifeq ($(OS),Windows_NT)
|
||||
LIBS+=-lwsock32 -liphlpapi -lmingw32
|
||||
endif
|
||||
LIBS+=-lSDLmain -lSDL -llua -lsqlite3
|
||||
ifeq ($(shell uname), Linux)
|
||||
#I don't know what this does, but Ubuntu needs it
|
||||
LIBS+=-ldl
|
||||
endif
|
||||
|
||||
#flags
|
||||
CXXFLAGS+=-std=c++11 $(addprefix -I,$(INCLUDES))
|
||||
@@ -49,6 +53,12 @@ $(OBJDIR)/%.o: %.cpp
|
||||
$(CXX) $(CXXFLAGS) -c -o $@ $<
|
||||
|
||||
clean:
|
||||
ifeq ($(OS),Windows_NT)
|
||||
$(RM) *.o *.a *.exe
|
||||
else ifeq ($(shell uname), Linux)
|
||||
find . -type f -name *.o -exec rm -f -r -v {} \;
|
||||
find . -type f -name *.a -exec rm -f -r -v {} \;
|
||||
rm -f -v out/client out/server
|
||||
endif
|
||||
|
||||
rebuild: clean all
|
||||
|
||||
@@ -30,8 +30,3 @@ $(OUTDIR):
|
||||
|
||||
$(OBJDIR)/%.o: %.cpp
|
||||
$(CXX) $(CXXFLAGS) -c -o $@ $<
|
||||
|
||||
clean:
|
||||
$(RM) *.o *.a *.exe
|
||||
|
||||
rebuild: clean all
|
||||
|
||||
@@ -30,8 +30,3 @@ $(OUTDIR):
|
||||
|
||||
$(OBJDIR)/%.o: %.cpp
|
||||
$(CXX) $(CXXFLAGS) -c -o $@ $<
|
||||
|
||||
clean:
|
||||
$(RM) *.o *.a *.exe
|
||||
|
||||
rebuild: clean all
|
||||
|
||||
@@ -21,6 +21,7 @@
|
||||
*/
|
||||
#include "server_application.hpp"
|
||||
|
||||
#include <cstring>
|
||||
#include <iostream>
|
||||
#include <sstream>
|
||||
|
||||
|
||||
@@ -21,6 +21,7 @@
|
||||
*/
|
||||
#include "server_application.hpp"
|
||||
|
||||
#include <cstring>
|
||||
#include <iostream>
|
||||
#include <sstream>
|
||||
|
||||
|
||||
@@ -21,6 +21,7 @@
|
||||
*/
|
||||
#include "server_application.hpp"
|
||||
|
||||
#include <cstring>
|
||||
#include <iostream>
|
||||
#include <sstream>
|
||||
|
||||
|
||||
@@ -27,6 +27,7 @@
|
||||
//std & STL
|
||||
#include <stdexcept>
|
||||
#include <chrono>
|
||||
#include <cstring>
|
||||
#include <iostream>
|
||||
#include <list>
|
||||
#include <sstream>
|
||||
@@ -51,7 +52,9 @@ void ServerApplication::Init(int argc, char* argv[]) {
|
||||
|
||||
//Init SDL
|
||||
if (SDL_Init(0)) {
|
||||
throw(std::runtime_error("Failed to initialize SDL"));
|
||||
std::ostringstream os;
|
||||
os << "Failed to initialize SDL: " << SDL_GetError();
|
||||
throw(std::runtime_error(os.str()));
|
||||
}
|
||||
std::cout << "Initialized SDL" << std::endl;
|
||||
|
||||
|
||||
@@ -22,6 +22,7 @@
|
||||
#include "server_application.hpp"
|
||||
|
||||
#include <chrono>
|
||||
#include <cstring>
|
||||
#include <iostream>
|
||||
#include <sstream>
|
||||
|
||||
|
||||
@@ -30,8 +30,3 @@ $(OUTDIR):
|
||||
|
||||
$(OBJDIR)/%.o: %.cpp
|
||||
$(CXX) $(CXXFLAGS) -c -o $@ $<
|
||||
|
||||
clean:
|
||||
$(RM) *.o *.a *.exe
|
||||
|
||||
rebuild: clean all
|
||||
|
||||
@@ -25,6 +25,8 @@
|
||||
#include "character_manager.hpp"
|
||||
#include "server_utilities.hpp"
|
||||
|
||||
#include <cstring>
|
||||
|
||||
static int pumpCharacterUpdate(lua_State* L) {
|
||||
CharacterData* characterData = static_cast<CharacterData*>(lua_touserdata(L, 1));
|
||||
|
||||
|
||||
@@ -27,6 +27,8 @@
|
||||
#include "room_manager.hpp"
|
||||
#include "udp_network_utility.hpp"
|
||||
|
||||
#include <cstring>
|
||||
|
||||
//-------------------------
|
||||
//manager unload functions
|
||||
//-------------------------
|
||||
|
||||
@@ -30,8 +30,3 @@ $(OUTDIR):
|
||||
|
||||
$(OBJDIR)/%.o: %.cpp
|
||||
$(CXX) $(CXXFLAGS) -c -o $@ $<
|
||||
|
||||
clean:
|
||||
$(RM) *.o *.a *.exe
|
||||
|
||||
rebuild: clean all
|
||||
|
||||
Reference in New Issue
Block a user