summaryrefslogtreecommitdiffhomepage
path: root/games
diff options
context:
space:
mode:
authorRay <[email protected]>2017-04-28 00:29:23 +0200
committerRay <[email protected]>2017-04-28 00:29:23 +0200
commit66320582a36d6c0b5ebd063bfbe4c04cb4424b8f (patch)
tree7dcc1bb283176859be86b1cd9ec0ec781a01ffa9 /games
parentbe40d979545031f030abd8077112d03421db4053 (diff)
downloadraylib-66320582a36d6c0b5ebd063bfbe4c04cb4424b8f.tar.gz
raylib-66320582a36d6c0b5ebd063bfbe4c04cb4424b8f.zip
Some work on example games
Diffstat (limited to 'games')
-rw-r--r--games/drturtle/makefile2
-rw-r--r--games/just_do/makefile2
-rw-r--r--games/just_do/screens/screen_level02.c13
-rw-r--r--games/koala_seasons/Makefile2
-rw-r--r--games/koala_seasons/resources/shaders/glsl100/blend_color.fs4
-rw-r--r--games/koala_seasons/screens/screen_gameplay.c2
-rw-r--r--games/skully_escape/makefile2
-rw-r--r--games/wave_collector/Makefile2
8 files changed, 8 insertions, 21 deletions
diff --git a/games/drturtle/makefile b/games/drturtle/makefile
index 5657deaa..89821929 100644
--- a/games/drturtle/makefile
+++ b/games/drturtle/makefile
@@ -94,7 +94,7 @@ ifeq ($(PLATFORM),PLATFORM_DESKTOP)
endif
endif
ifeq ($(PLATFORM),PLATFORM_WEB)
- CFLAGS = -O1 -Wall -std=c99 -D_DEFAULT_SOURCE -s USE_GLFW=3 -s ASSERTIONS=1 -s ALLOW_MEMORY_GROWTH=1 --profiling --preload-file resources
+ CFLAGS = -O1 -Wall -std=c99 -D_DEFAULT_SOURCE -s USE_GLFW=3 -s ASSERTIONS=1 -s TOTAL_MEMORY=33554432 --profiling --preload-file resources
# -O2 # if used, also set --memory-init-file 0
# --memory-init-file 0 # to avoid an external memory initialization code file (.mem)
# -s ALLOW_MEMORY_GROWTH=1 # to allow memory resizing
diff --git a/games/just_do/makefile b/games/just_do/makefile
index f86ed2c7..6dc096fb 100644
--- a/games/just_do/makefile
+++ b/games/just_do/makefile
@@ -94,7 +94,7 @@ ifeq ($(PLATFORM),PLATFORM_DESKTOP)
endif
endif
ifeq ($(PLATFORM),PLATFORM_WEB)
- CFLAGS = -O1 -Wall -std=c99 -D_DEFAULT_SOURCE -s USE_GLFW=3 -s ASSERTIONS=1 -s --profiling --preload-file resources
+ CFLAGS = -O1 -Wall -std=c99 -D_DEFAULT_SOURCE -s USE_GLFW=3 -s ASSERTIONS=1 --profiling --preload-file resources
# -O2 # if used, also set --memory-init-file 0
# --memory-init-file 0 # to avoid an external memory initialization code file (.mem)
# -s ALLOW_MEMORY_GROWTH=1 # to allow memory resizing
diff --git a/games/just_do/screens/screen_level02.c b/games/just_do/screens/screen_level02.c
index a2d5e562..584edcef 100644
--- a/games/just_do/screens/screen_level02.c
+++ b/games/just_do/screens/screen_level02.c
@@ -154,17 +154,4 @@ void UnloadLevel02Screen(void)
int FinishLevel02Screen(void)
{
return finishScreen;
-}
-
-// Calculate distance between two points
-float Vector2Distance(Vector2 v1, Vector2 v2)
-{
- float result;
-
- float dx = v2.x - v1.x;
- float dy = v2.y - v1.y;
-
- result = sqrt(dx*dx + dy*dy);
-
- return result;
} \ No newline at end of file
diff --git a/games/koala_seasons/Makefile b/games/koala_seasons/Makefile
index 0928d3ad..c9eee6ff 100644
--- a/games/koala_seasons/Makefile
+++ b/games/koala_seasons/Makefile
@@ -94,7 +94,7 @@ ifeq ($(PLATFORM),PLATFORM_DESKTOP)
endif
endif
ifeq ($(PLATFORM),PLATFORM_WEB)
- CFLAGS = -O1 -Wall -std=c99 -D_DEFAULT_SOURCE -s USE_GLFW=3 -s ASSERTIONS=1 --profiling --preload-file resources -s ALLOW_MEMORY_GROWTH=1
+ CFLAGS = -O1 -Wall -std=c99 -DPLATFORM_WEB -D_DEFAULT_SOURCE -s USE_GLFW=3 -s ASSERTIONS=1 -s TOTAL_MEMORY=67108864 --profiling --preload-file resources
# -O2 # if used, also set --memory-init-file 0
# --memory-init-file 0 # to avoid an external memory initialization code file (.mem)
# -s ALLOW_MEMORY_GROWTH=1 # to allow memory resizing
diff --git a/games/koala_seasons/resources/shaders/glsl100/blend_color.fs b/games/koala_seasons/resources/shaders/glsl100/blend_color.fs
index eceb16be..ae23f941 100644
--- a/games/koala_seasons/resources/shaders/glsl100/blend_color.fs
+++ b/games/koala_seasons/resources/shaders/glsl100/blend_color.fs
@@ -3,8 +3,8 @@
precision mediump float;
// Input vertex attributes (from vertex shader)
-in vec2 fragTexCoord;
-in vec4 fragColor;
+varying vec2 fragTexCoord;
+varying vec4 fragColor;
// Input uniform values
uniform sampler2D texture0;
diff --git a/games/koala_seasons/screens/screen_gameplay.c b/games/koala_seasons/screens/screen_gameplay.c
index de698df6..6bbcfaaf 100644
--- a/games/koala_seasons/screens/screen_gameplay.c
+++ b/games/koala_seasons/screens/screen_gameplay.c
@@ -490,7 +490,7 @@ void UpdateGameplayScreen(void)
if (monthTimer >= monthChange)
{
- if ((currentMonth == 10))
+ if (currentMonth == 10)
{
clockInitRotation = 225;
clockFinalRotation = clockInitRotation + 90;
diff --git a/games/skully_escape/makefile b/games/skully_escape/makefile
index 4e5ef8da..70f7f5a3 100644
--- a/games/skully_escape/makefile
+++ b/games/skully_escape/makefile
@@ -94,7 +94,7 @@ ifeq ($(PLATFORM),PLATFORM_DESKTOP)
endif
endif
ifeq ($(PLATFORM),PLATFORM_WEB)
- CFLAGS = -O1 -Wall -std=c99 -D_DEFAULT_SOURCE -s USE_GLFW=3 -s ASSERTIONS=1 --profiling --preload-file resources -s ALLOW_MEMORY_GROWTH=1
+ CFLAGS = -O1 -Wall -std=c99 -D_DEFAULT_SOURCE -s USE_GLFW=3 -s ASSERTIONS=1 -s TOTAL_MEMORY=67108864 --profiling --preload-file resources
# -O2 # if used, also set --memory-init-file 0
# --memory-init-file 0 # to avoid an external memory initialization code file (.mem)
# -s ALLOW_MEMORY_GROWTH=1 # to allow memory resizing
diff --git a/games/wave_collector/Makefile b/games/wave_collector/Makefile
index dee622ca..618ef22b 100644
--- a/games/wave_collector/Makefile
+++ b/games/wave_collector/Makefile
@@ -94,7 +94,7 @@ ifeq ($(PLATFORM),PLATFORM_DESKTOP)
endif
endif
ifeq ($(PLATFORM),PLATFORM_WEB)
- CFLAGS = -O1 -Wall -std=c99 -D_DEFAULT_SOURCE -s USE_GLFW=3 -s ASSERTIONS=1 -s ALLOW_MEMORY_GROWTH=1 --profiling --preload-file resources
+ CFLAGS = -O1 -Wall -std=c99 -D_DEFAULT_SOURCE -s USE_GLFW=3 -s ASSERTIONS=1 -s TOTAL_MEMORY=67108864 --profiling --preload-file resources
# -O2 # if used, also set --memory-init-file 0
# --memory-init-file 0 # to avoid an external memory initialization code file (.mem)
# -s ALLOW_MEMORY_GROWTH=1 # to allow memory resizing