Log In  

Just a quick little demo room to test out physics for my new favorite astronaut, Willie. I'll upload and update here as the game comes along. Currently "x" starts and "z" turns on debug mode. Arrow keys to move and jump.

Cart #smallbackpackbeta0-1 | 2020-07-28 | Code ▽ | Embed ▽ | No License
1

P#80043 2020-07-28 18:41

1

i highly recommend

fget(mget(x/8,y/8),solid flag)

just so building levels is faster. lovely character design though, and i love crouch mechanics in games even when they aren't used in game. overall a great start. have fun with programming. I also recommend keeping all the rect collisions, but putting them in a table, so you can use

function sol(p)
 for r in all(rects) do
  if col(p,r) return true
 end
 return false
end

to detect if somthing is colliding with any rectangle in list(r) do

 if sol(ob) then --[[some code]] end

looking forward to the finished thing!

please note that i may or may not have any idea what i am doing, but this is faster to use and expand upon,
and will probably skip the dark era of not using the miracle of

arrays

[0x0]

P#80100 2020-07-29 19:16
1

Thank you so much for the advice! I wrote the collision function in there myself and I was just really excited to use it, haha. I'll definitely give this a try!

P#80138 2020-07-30 20:06

[Please log in to post a comment]