Skip to content

Commit 27350e7

Browse files
author
Aitor Moreno
committed
Remove Quit Game and fix build process
1 parent 8956e01 commit 27350e7

15 files changed

+1219
-88
lines changed

.editorconfig

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
root = true
2+
3+
[*.js,*.html,*.css]
4+
charset = utf-8
5+
6+
indent_size = 2
7+
indent_style = space
8+
9+
end_of_line = lf
10+
11+
trim_trailing_whitespace = true
12+
13+
insert_final_newline = true

.gitignore

+277-55
Original file line numberDiff line numberDiff line change
@@ -1,57 +1,279 @@
1-
CMDLINE
2-
INSTALL
3-
Makefile
4-
Makefile.in
5-
TAGS
6-
aclocal.m4
7-
autom4te.cache
8-
autotools
9-
bin
10-
config.hin
11-
config.log
12-
config.status
13-
configure
14-
lib
15-
obj
16-
rpm.spec
17-
stamp-h
18-
stamp-h.in
19-
stamp-h1
20-
tags
21-
\#*\#
22-
DOOM*.png
23-
HTIC*.png
24-
HEXEN*.png
25-
STRIFE*.png
26-
DOOM*.pcx
27-
HTIC*.pcx
28-
HEXEN*.pcx
29-
STRIFE*.pcx
30-
31-
# These are the default patterns globally ignored by Subversion:
32-
*.o
33-
*.lo
34-
*.la
35-
*.al
36-
.libs
37-
*.so
38-
*.so.[0-9]*
39-
*.a
40-
*.pyc
41-
*.pyo
42-
*.rej
1+
2+
# Created by https://www.gitignore.io/api/linux,osx,windows,vim,emacs,sublimetext,visualstudiocode,node
3+
# Edit at https://www.gitignore.io/?templates=linux,osx,windows,vim,emacs,sublimetext,visualstudiocode,node
4+
5+
### Emacs ###
6+
# -*- mode: gitignore; -*-
437
*~
44-
.#*
45-
.*.swp
46-
.DS_store
47-
48-
build
49-
*.bc
50-
*.wasm
51-
doom.*
52-
index.*
8+
\#*\#
9+
/.emacs.desktop
10+
/.emacs.desktop.lock
11+
*.elc
12+
auto-save-list
13+
tramp
14+
.\#*
15+
16+
# Org-mode
17+
.org-id-locations
18+
*_archive
19+
20+
# flymake-mode
21+
*_flymake.*
22+
23+
# eshell files
24+
/eshell/history
25+
/eshell/lastdir
26+
27+
# elpa packages
28+
/elpa/
29+
30+
# reftex files
31+
*.rel
32+
33+
# AUCTeX auto folder
34+
/auto/
35+
36+
# cask packages
37+
.cask/
38+
dist/
39+
40+
# Flycheck
41+
flycheck_*.el
42+
43+
# server auth directory
44+
/server/
45+
46+
# projectiles files
47+
.projectile
48+
49+
# directory configuration
50+
.dir-locals.el
51+
52+
# network security
53+
/network-security.data
54+
55+
56+
### Linux ###
57+
58+
# temporary files which can be created if a process still has a handle open of a deleted file
59+
.fuse_hidden*
60+
61+
# KDE directory preferences
62+
.directory
63+
64+
# Linux trash folder which might appear on any partition or disk
65+
.Trash-*
66+
67+
# .nfs files are created when an open file is removed but is still being accessed
68+
.nfs*
69+
70+
### Node ###
71+
# Logs
72+
logs
5373
*.log
54-
*.wad
55-
*.flac
56-
*.ogg
57-
*.mp3
74+
npm-debug.log*
75+
yarn-debug.log*
76+
yarn-error.log*
77+
lerna-debug.log*
78+
79+
# Diagnostic reports (https://nodejs.org/api/report.html)
80+
report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json
81+
82+
# Runtime data
83+
pids
84+
*.pid
85+
*.seed
86+
*.pid.lock
87+
88+
# Directory for instrumented libs generated by jscoverage/JSCover
89+
lib-cov
90+
91+
# Coverage directory used by tools like istanbul
92+
coverage
93+
*.lcov
94+
95+
# nyc test coverage
96+
.nyc_output
97+
98+
# Grunt intermediate storage (https://gruntjs.com/creating-plugins#storing-task-files)
99+
.grunt
100+
101+
# Bower dependency directory (https://bower.io/)
102+
bower_components
103+
104+
# node-waf configuration
105+
.lock-wscript
106+
107+
# Compiled binary addons (https://nodejs.org/api/addons.html)
108+
build/Release
109+
110+
# Dependency directories
111+
node_modules/
112+
jspm_packages/
113+
114+
# TypeScript v1 declaration files
115+
typings/
116+
117+
# TypeScript cache
118+
*.tsbuildinfo
119+
120+
# Optional npm cache directory
121+
.npm
122+
123+
# Optional eslint cache
124+
.eslintcache
125+
126+
# Optional REPL history
127+
.node_repl_history
128+
129+
# Output of 'npm pack'
130+
*.tgz
131+
132+
# Yarn Integrity file
133+
.yarn-integrity
134+
135+
# dotenv environment variables file
136+
.env
137+
.env.test
138+
139+
# parcel-bundler cache (https://parceljs.org/)
140+
.cache
141+
142+
# next.js build output
143+
.next
144+
145+
# nuxt.js build output
146+
.nuxt
147+
148+
# react / gatsby
149+
public/
150+
151+
# vuepress build output
152+
.vuepress/dist
153+
154+
# Serverless directories
155+
.serverless/
156+
157+
# FuseBox cache
158+
.fusebox/
159+
160+
# DynamoDB Local files
161+
.dynamodb/
162+
163+
### OSX ###
164+
# General
165+
.DS_Store
166+
.AppleDouble
167+
.LSOverride
168+
169+
# Icon must end with two \r
170+
Icon
171+
172+
# Thumbnails
173+
._*
174+
175+
# Files that might appear in the root of a volume
176+
.DocumentRevisions-V100
177+
.fseventsd
178+
.Spotlight-V100
179+
.TemporaryItems
180+
.Trashes
181+
.VolumeIcon.icns
182+
.com.apple.timemachine.donotpresent
183+
184+
# Directories potentially created on remote AFP share
185+
.AppleDB
186+
.AppleDesktop
187+
Network Trash Folder
188+
Temporary Items
189+
.apdisk
190+
191+
### SublimeText ###
192+
# Cache files for Sublime Text
193+
*.tmlanguage.cache
194+
*.tmPreferences.cache
195+
*.stTheme.cache
196+
197+
# Workspace files are user-specific
198+
*.sublime-workspace
199+
200+
# Project files should be checked into the repository, unless a significant
201+
# proportion of contributors will probably not be using Sublime Text
202+
# *.sublime-project
203+
204+
# SFTP configuration file
205+
sftp-config.json
206+
207+
# Package control specific files
208+
Package Control.last-run
209+
Package Control.ca-list
210+
Package Control.ca-bundle
211+
Package Control.system-ca-bundle
212+
Package Control.cache/
213+
Package Control.ca-certs/
214+
Package Control.merged-ca-bundle
215+
Package Control.user-ca-bundle
216+
oscrypto-ca-bundle.crt
217+
bh_unicode_properties.cache
218+
219+
# Sublime-github package stores a github token in this file
220+
# https://packagecontrol.io/packages/sublime-github
221+
GitHub.sublime-settings
222+
223+
### Vim ###
224+
# Swap
225+
[._]*.s[a-v][a-z]
226+
[._]*.sw[a-p]
227+
[._]s[a-rt-v][a-z]
228+
[._]ss[a-gi-z]
229+
[._]sw[a-p]
230+
231+
# Session
232+
Session.vim
233+
Sessionx.vim
234+
235+
# Temporary
236+
.netrwhist
237+
# Auto-generated tag files
238+
tags
239+
# Persistent undo
240+
[._]*.un~
241+
242+
### VisualStudioCode ###
243+
.vscode/*
244+
!.vscode/settings.json
245+
!.vscode/tasks.json
246+
!.vscode/launch.json
247+
!.vscode/extensions.json
248+
249+
### VisualStudioCode Patch ###
250+
# Ignore all local history of files
251+
.history
252+
253+
### Windows ###
254+
# Windows thumbnail cache files
255+
Thumbs.db
256+
Thumbs.db:encryptable
257+
ehthumbs.db
258+
ehthumbs_vista.db
259+
260+
# Dump file
261+
*.stackdump
262+
263+
# Folder config file
264+
[Dd]esktop.ini
265+
266+
# Recycle Bin used on file shares
267+
$RECYCLE.BIN/
268+
269+
# Windows Installer files
270+
*.cab
271+
*.msi
272+
*.msix
273+
*.msm
274+
*.msp
275+
276+
# Windows shortcuts
277+
*.lnk
278+
279+
# End of https://www.gitignore.io/api/linux,osx,windows,vim,emacs,sublimetext,visualstudiocode,node

CMakeLists.txt

+6-6
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Oz -Wall \
2121
-s USE_LIBPNG=1 \
2222
-s ALLOW_MEMORY_GROWTH=1 \
2323
-s NO_EXIT_RUNTIME=1 \
24-
-s EXTRA_EXPORTED_RUNTIME_METHODS=['FS'] \
24+
-s EXTRA_EXPORTED_RUNTIME_METHODS=['FS','UTF8ToString'] \
2525
--no-heap-copy")
2626

2727
if (CMAKE_BUILD_TYPE MATCHES Debug)
@@ -31,11 +31,11 @@ if (CMAKE_BUILD_TYPE MATCHES Debug)
3131

3232
set(CMAKE_C_FLAGS_DEBUG "-s ASSERTIONS=2 --source-map-base http://localhost:8000/ -g4 --preload-file ${CMAKE_CURRENT_LIST_DIR}/../[email protected]")
3333

34-
add_custom_command(TARGET index POST_BUILD
35-
WORKING_DIRECTORY ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}
36-
COMMAND sed -i index.wasm.map 's|${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/||g' index.wasm.map
37-
COMMENT "Fix WebAssembly source map root"
38-
)
34+
#add_custom_command(TARGET index POST_BUILD
35+
# WORKING_DIRECTORY ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}
36+
# COMMAND sed -i index.wasm.map 's|${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/||g' index.wasm.map
37+
# COMMENT "Fix WebAssembly source map root"
38+
#)
3939

4040
em_link_js_library(index ${libraryJsFiles})
4141
else()

README.md

+9
Original file line numberDiff line numberDiff line change
@@ -24,3 +24,12 @@ Libpng is © 1998-2014 Glenn Randers-Pehrson, © 1996-1997 Andreas Dilger, ©
2424
Gailly and Mark Adler.
2525

2626
Emscripten is © 2010-2018 Emscripten authors, see [AUTHORS](https://raw.githubusercontent.com/emscripten-core/emscripten/incoming/AUTHORS) file.
27+
28+
# How to compile this
29+
30+
```sh
31+
# If you want to compile it in "Debug" mode
32+
emcmake cmake -DCMAKE_BUILD_TYPE=Debug
33+
emmake make -j12
34+
```
35+

0 commit comments

Comments
 (0)