Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/master' into community-editors
Browse files Browse the repository at this point in the history
  • Loading branch information
jkulawik committed Oct 2, 2020
2 parents 506937d + ca6b4ac commit a6c35ac
Show file tree
Hide file tree
Showing 22 changed files with 191 additions and 338 deletions.
13 changes: 13 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,22 @@ bld/
[Ll]og/
[Ll]ogs/
amnesia/_temp/
amnesia/src/*.bin*
amnesia/src/core2

# CMake build files
CMakeFiles/
Makefile
CMakeCache.txt
cmake_install.cmake

# Visual Studio 2015/2017 cache/options directory
.vs/

# VS Code project
.vscode/
build/

# Uncomment if you have tasks that create the project's static files in wwwroot
#wwwroot/

Expand Down
9 changes: 5 additions & 4 deletions HPL2/core/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -244,6 +244,8 @@ FindPrebuiltLibrary(GLEW_LIBRARY GLEW)
FindPrebuiltLibrary(THEORA_LIBRARY theora)
FindPrebuiltLibrary(DEVIL_LIBRARY IL)

set(OpenGL_GL_PREFERENCE LEGACY)

find_package(OpenGL)
mark_as_advanced(NEWTON_LIBRARY ANGELSCRIPT_LIBRARY FBX_LIBRARY GLEW_LIBRARY THEORA_LIBRARY DEVIL_LIBRARY)

Expand Down Expand Up @@ -294,10 +296,10 @@ target_link_libraries(HPL2
)


if(APPLE)
if(APPLE)
# helper function to copy the needed frameworks in at build time
SET(HPL2_FRAMEWORKS ${HPL2_FRAMEWORKS} CACHE STRING "HPL2 copy frameworks")
SET(HPL2_LIBRARIES libSDL2.dylib libIL.1.dylib)
SET(HPL2_LIBRARIES libSDL2.dylib libIL.1.dylib)
SET(HPL2_LIBRARIES ${HPL2_LIBRARIES} CACHE STRING "HPL2 copy libs")
mark_as_advanced(HPL2_FRAMEWORKS HPL2_LIBRARIES)

Expand Down Expand Up @@ -344,7 +346,6 @@ FUNCTION(AddTestTarget target_name)
)
ENDFUNCTION()

add_subdirectory(../tests tests)
add_subdirectory(../tools tools)


set(CMAKE_CXX_FLAGS "-fpermissive -no-pie")
Original file line number Diff line number Diff line change
Expand Up @@ -17,3 +17,16 @@
* along with Amnesia: The Dark Descent. If not, see <https://www.gnu.org/licenses/>.
*/

//////////////////////////////////////////////////
// File autogenerated by buildcounter
// Do not hand edit! (preferably)
//////////////////////////////////////////////////
#include "./BuildID_HPL2_0.h"

static char gsBuildID[16] = "20160407093727";

const char* GetBuildID_HPL2_0()
{
return gsBuildID;
}

8 changes: 0 additions & 8 deletions HPL2/core/sources/_add_license.bat

This file was deleted.

Binary file modified HPL2/dependencies.zip
Binary file not shown.
1 change: 1 addition & 0 deletions HPL2/tools/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -68,3 +68,4 @@ add_executable(MshConverter
)
target_link_libraries(MshConverter HPL2)

set(CMAKE_CXX_FLAGS "-fpermissive -no-pie")
1 change: 1 addition & 0 deletions HPL2/tools/editors/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -384,3 +384,4 @@ AddToolTarget(MaterialEditor

# vim: noet ts=4:

set(CMAKE_CXX_FLAGS "-fpermissive -no-pie")
32 changes: 32 additions & 0 deletions HPL2/tools/editors/leveleditor/BuildID_LevelEditor_Linux.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
/*
* Copyright © 2009-2020 Frictional Games
*
* This file is part of Amnesia: The Dark Descent.
*
* Amnesia: The Dark Descent 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.
* Amnesia: The Dark Descent is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with Amnesia: The Dark Descent. If not, see <https://www.gnu.org/licenses/>.
*/

//////////////////////////////////////////////////
// File autogenerated by buildcounter
// Do not hand edit! (preferably)
//////////////////////////////////////////////////
#include "./BuildID_LevelEditor.h"

static char gsBuildID[16] = "20101027185544";

const char* GetBuildID_LevelEditor()
{
return gsBuildID;
}

32 changes: 32 additions & 0 deletions HPL2/tools/editors/materialeditor/BuildID_MaterialEditor_Linux.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
/*
* Copyright © 2009-2020 Frictional Games
*
* This file is part of Amnesia: The Dark Descent.
*
* Amnesia: The Dark Descent 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.
* Amnesia: The Dark Descent is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with Amnesia: The Dark Descent. If not, see <https://www.gnu.org/licenses/>.
*/

//////////////////////////////////////////////////
// File autogenerated by buildcounter
// Do not hand edit! (preferably)
//////////////////////////////////////////////////
#include "./BuildID_MaterialEditor.h"

static char gsBuildID[16] = "20100917115138";

const char* GetBuildID_MaterialEditor()
{
return gsBuildID;
}

32 changes: 32 additions & 0 deletions HPL2/tools/editors/modeleditor/BuildID_ModelEditor_Linux.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
/*
* Copyright © 2009-2020 Frictional Games
*
* This file is part of Amnesia: The Dark Descent.
*
* Amnesia: The Dark Descent 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.
* Amnesia: The Dark Descent is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with Amnesia: The Dark Descent. If not, see <https://www.gnu.org/licenses/>.
*/

//////////////////////////////////////////////////
// File autogenerated by buildcounter
// Do not hand edit! (preferably)
//////////////////////////////////////////////////
#include "./BuildID_ModelEditor.h"

static char gsBuildID[16] = "20100917115135";

const char* GetBuildID_ModelEditor()
{
return gsBuildID;
}

32 changes: 32 additions & 0 deletions HPL2/tools/editors/particleeditor/BuildID_ParticleEditor_Linux.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
/*
* Copyright © 2009-2020 Frictional Games
*
* This file is part of Amnesia: The Dark Descent.
*
* Amnesia: The Dark Descent 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.
* Amnesia: The Dark Descent is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with Amnesia: The Dark Descent. If not, see <https://www.gnu.org/licenses/>.
*/

//////////////////////////////////////////////////
// File autogenerated by buildcounter
// Do not hand edit! (preferably)
//////////////////////////////////////////////////
#include "./BuildID_ParticleEditor.h"

static char gsBuildID[16] = "20100917115133";

const char* GetBuildID_ParticleEditor()
{
return gsBuildID;
}

38 changes: 25 additions & 13 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,18 +1,22 @@
# Amnesia: The Dark Descent Source Code - HPL Chad Gang Fork
# Amnesia: The Dark Descent - HPL Chad Gang Fork

This is a fork of the Amnesia the Dark Descent repository from FrictionalGames. We will mostly play with different parts of the engine and perhaps even fix some bugs :)

## Project Overview
The game is built from two separate solutions: The HPL2 Engine and the game itself.
Currently also working on improving the engine tools - check the appropriate branch.

## Index

* [Windows](#project-overview-windows) - Compiling instructions for Windows.
* [Linux](#building--playing-linux) - Compiling instructions for Linux.

## Prerequisites

- A copy of Amnesia: the Dark Descent (For playing the game)
- Visual Studio 2010 (For compiling the engine)
- Visual Studio 2017 (For compiling the game)
- CMake
- Visual Studio 2010 (Windows, for compiling the engine)
- Visual Studio 2017 (Windows, for compiling the game)
- CMake, Make (Linux, for compiling)

## Project Overview
## Project Overview (Windows)
The game is built from two separate solutions: The engine solution named `HPL2_2010` and the main game solution named `Lux`.
The project also includes all the different editors and additional tools, such as the Level Editor and the Model Editor.

Expand All @@ -25,7 +29,7 @@ Todo: Add some descriptions about what kind of files we have in the game solutio
## Building & Playing (Windows)
In order to build the game on Windows, you will first need to compile and build the HPL2 Engine.

### Building the Engine
### Building the Engine
1. Clone the project
2. Go to the `HPL2/` folder and extract `dependencies.zip`.
3. Open `_HPL2_2010.sln` with Visual Studio 2010.
Expand All @@ -47,7 +51,7 @@ Copy `Amnesia.exe` into your Amnesia game folder and launch it. The main menu sh

## Building & Playing (Mac)

### Building the Engine
### Building the Engine

### Building the Game

Expand All @@ -57,15 +61,23 @@ Copy `Amnesia.exe` into your Amnesia game folder and launch it. The main menu sh

## Building & Playing (Linux)

### Building the Engine
There are a few extra steps required to be able to successfully build everything on Linux compared to Windows.

### Building the Game
### Building the Engine, Game & Editors

1. Ensure you have `make` and `cmake` installed.
2. Clone the project and enter the folder
3. Extract `./HPL2/dependencies.zip` to the same folder it's in
4. Run the script file at `./HPL2/dependencies/lib/linux/lib64/fix_symlinks.sh` to fix broken symlinks from the .zip file
5. Open a terminal in `./amnesia/src` and run `cmake .`
6. With a terminal in `./amnesia/src` do `make` (or use `make -jX` where X is the number of jobs you want to run to speed things up, based on your CPU threads)
7. The build should compile and the resulting binaries will be found in `./amnesia/src`

### Playing the Game

### Building the Editors
To run the compiled binary, copy it to your Amnesia installation folder. For example copy the `Amnesia.bin.x86_64` to your game folder. Run it, and the game should start directly.

## Toubleshooting
## Troubleshooting
* **"When I compile `Lux`, I get an error message "fatal error RC1015: cannot open include file 'afxres.h'".**"
* You need to install the `Microsoft Foundation Classes for C++`. If it still doesn't work, change `afxres.h` to `windows.h`. It should compile then.

Expand Down
69 changes: 0 additions & 69 deletions amnesia/src/BuildScripts/README.txt

This file was deleted.

Loading

0 comments on commit a6c35ac

Please sign in to comment.