@sed -e 's/.*://' -e 's/\\$$//' < $(OUTDIR)/$*.$(DEPEXT).tmp | fmt -1 | sed -e 's/^ *//' -e 's/$$/:/' >> $(OUTDIR)/$*.$(DEPEXT)
@rm -f $(OUTDIR)/$*.$(DEPEXT).tmp
- mem: $(EXEC)
- valgrind --leak-check=full --show-leak-kinds=all --track-origins=yes ./$(EXEC)
+ lib/libentityx.a:
+ @cmake -S lib/entityx -B lib/entityx -DENTITYX_BUILD_SHARED=FALSE
+ @make -Clib/entityx -j4 entityx
+ @cp lib/entityx/libentityx.a lib/libentityx.a
+
+ lib/libluajit.a:
+ @make -Clib/luajit -j4
+ @cp lib/luajit/src/libluajit.a lib/libluajit.a
+
+ lib/libsoil.a:
+ @make -Clib/soil -j4
+ @cp lib/soil/libsoil.a lib/libsoil.a
+
+ .PHONY: all remake clean cleaner cleanall resources
+.PHONY: all remake clean cleaner resources mem
x = 0.0,
y = 0.0
},
- Physics = 0,
+ Physics = {
+ hitbox = {
+ ll = {x = -0.5, y = -0.8},
+ lr = {x = 0.5, y = -0.8},
+ ul = {x = -0.5, y = 0.8},
+ ur = {x = 0.5, y = 0.8},
+ }
+ },
Name = "bord",
+ Audio = {
+ file = "Assets/jump.wav"
+ },
+ hellotrue = true,
+ hellofalse = false,
Render = {
texture = "Assets/player.png",
- visible = true
+ visible = true,
+ offset = {
+ ll = {x = -0.5, y = -0.8},
+ lr = {x = 0.5, y = -0.8},
+ ul = {x = -0.5, y = 0.8},
+ ur = {x = 0.5, y = 0.8},
+ }
},
Light = {
r = 1.0,
lua.new_usertype<Physics>("Physics",
sol::constructors<Physics(void), Physics()>(),
- "standing", &Physics::standing);
+ "standing", &Physics::standing,
+ "gravity", &Physics::gravity);
+ lua.new_usertype<Audio>("Audio",
+ sol::constructors<Audio(std::string)>(),
+ "file", &Audio::fileName);
+
lua.new_usertype<World>("World",
sol::constructors<World(sol::object), World(void)>(),
"Generate", &World::generate,