Welcome, Guest. Please login or register.

Login with username, password and session length

 
Advanced search

1411477 Posts in 69369 Topics- by 58424 Members - Latest Member: FlyingFreeStudios

April 23, 2024, 05:35:43 PM

Need hosting? Check out Digital Ocean
(more details in this thread)
TIGSource ForumsCommunityDevLogsApple and Worm: Patching Holes In Spacetime
Pages: 1 ... 23 24 [25] 26 27 ... 33
Print
Author Topic: Apple and Worm: Patching Holes In Spacetime  (Read 69260 times)
Daid
Level 3
***



View Profile
« Reply #480 on: October 30, 2019, 01:33:57 AM »

I don't know which collision system you are using, and I think you where using Unity. However, this might help:
https://github.com/daid/SeriousProton2/blob/master/src/collision/2d/box2dBackend.cpp#L117
It's 1 sided collision for one-sided platforms with box2d. (Or more specificly, in my engine, any "2d chain shape" is one sided)

It's always a joy to see your apple jumping around in your devlog, so keep up the good work!
Logged

Software engineer by trade. Game development by hobby.
The Tribute Of Legends Devlog Co-op zelda.
EmptyEpsilon Free Co-op multiplayer spaceship simulator
JobLeonard
Level 10
*****



View Profile
« Reply #481 on: October 30, 2019, 01:54:46 AM »

EDIT: quoted for pagination
Made a quick mockup of the logic trapdoor. It's not actually coded in, I'm hitting a key to change the state and activate the collider, and took me a few tries to synchronize with the movement. I think this is better than that drawing on the white board I did. Still, kinda hard to see. Maybe it should be wider.

Also, doing this has the same challenges as the one-sided platform, which I wasn't looking forward to working on, but now there are two things that would benefit from it, so I guess I have to now...



EDIT: the illusion would work better if the apple sprite were actually in front of the trapdoor. I re-recorded it Tongue

Quote
Made a quick mockup of the logic trapdoor.
Well, guess it's only a matter of time before Apple and Worm becomes Turing Complete now :p

Looks like it opens up (hah) a lot of fun puzzle options! But yeah, the graphics are probably a bit too subtle at the moment - I saw the gif first and now knowing what I was looking for at first I missed it, until I read the rest of the post.
« Last Edit: October 30, 2019, 02:47:25 AM by JobLeonard » Logged
oahda
Level 10
*****



View Profile
« Reply #482 on: October 30, 2019, 02:35:51 AM »

Bit hard to read but then again a regular one-sided platform usually doesn't change at all so maybe it doesn't matter. I'm not familiar with those wooden hinges IRL tho so maybe seeing one would help.
Logged

diegzumillo
Level 10
*****


This avatar is so old I still have a some hair


View Profile WWW
« Reply #483 on: October 30, 2019, 04:08:30 AM »

I don't know which collision system you are using, and I think you where using Unity. However, this might help:
https://github.com/daid/SeriousProton2/blob/master/src/collision/2d/box2dBackend.cpp#L117
It's 1 sided collision for one-sided platforms with box2d. (Or more specificly, in my engine, any "2d chain shape" is one sided)

It's always a joy to see your apple jumping around in your devlog, so keep up the good work!

Thanks Smiley I'm using my own physics implementation. The advantage is that I wrote it so I get to add all the special cases I need. The disadvantage is that I wrote it and I have to write all the special cases I need. And boy does my code suck. I had to because I couldn't make the physics engine behave like I wanted to do the curved space thing.

Well, guess it's only a matter of time before Apple and Worm becomes Turing Complete now :p

Looks like it opens up (hah) a lot of fun puzzle options! But yeah, the graphics are probably a bit too subtle at the moment - I saw the gif first and now knowing what I was looking for at first I missed it, until I read the rest of the post.

Cheesy You're inspired today.

Bit hard to read but then again a regular one-sided platform usually doesn't change at all so maybe it doesn't matter. I'm not familiar with those wooden hinges IRL tho so maybe seeing one would help.

I hope better art can make it more readable.

Or maybe make it sideways. That is, make it an L shaped platform, with the vertical leg mysteriously non colliding or else you'd be able to toggle the platform without falling through it, which is the whole point... nah, I don't like that.


EDIT: I kept thinking about how to implement this and writing usually helps but I don't want to spam more devlog even more. So an edit it is.
It seems it can be done without adding special types of colliders, but it would require a clever combination of triggers and colliders. It would also require setting two objects to not interact. I could just add a physicsbody DisregardThis to the physicsbody class; that would be the ugly and easy way out. But I have been considering adding layers to the physics simulation. This is such a common place feature in physics engines. The question is, do I need this feature again or just this instance? If it's just for this than I would rather do the ugly easy solution.

I'm going to do the ugly easy solution. Seems like if layers are ever implemented in the future this would be easy to convert to that system anyway.
« Last Edit: October 30, 2019, 04:45:07 AM by diegzumillo » Logged

oahda
Level 10
*****



View Profile
« Reply #484 on: October 30, 2019, 05:39:59 AM »

That's basically how I dev. Cheesy Quick and dirty first to get it working and see what needs to go in there and what problems arise, then rewrite it all nice and pretty when it gets unmanageable!
Logged

diegzumillo
Level 10
*****


This avatar is so old I still have a some hair


View Profile WWW
« Reply #485 on: October 31, 2019, 02:01:10 PM »

So I was working on one-sided platform and the hinged trapdoor thing, trying to keep the coded exceptions to the physics engine to a minimum and instead working with what I have. For example, instead of coding a different kind of physicsbody that behaves differently, I have a normal collider surrounded with a trigger collider and go from there.

While I was doing that I found some bugs that... I am absolutely mind boggled (that sounds weird, am I saying it right?). I fixed an absurd number of SEVERE bugs on the physics code. Like, how is it even working at all?? The friction thing I mentioned in the earlier post is nothing compared to this. I found the main Overlap() function that is at the heart of the collision detection was just plain wrong. A lot of collision processing was being done on bodies that didn't overlap at all. Then I found another function that was collecting indices of objects and arranging them in an array, and it was completely wrong as well! Passing all the wrong indices. How is the game even running? It's like the car was missing a wheel and it still worked without anyone noticing.

Makes me wonder what other bug gems are still hidden in there.

Oh well, it seems to run a little smoother now lol. And the one-sided platform is working. I'll do a write up of how it's coded later. Right now it's a little flimsy. Hence why there is only one in this gif as it doesn't like being near portals yet.

Logged

JobLeonard
Level 10
*****



View Profile
« Reply #486 on: October 31, 2019, 02:20:45 PM »

Patching bugs in spacetime
Logged
oahda
Level 10
*****



View Profile
« Reply #487 on: October 31, 2019, 02:30:40 PM »

I'm familiar with those… I remain constantly paranoid that my own game is still full of them somewhere. Who, Me?

Looks good! Great to keep seeing updates. Kiss
Logged

nova++
Level 4
****


Real life space alien (not fake)


View Profile
« Reply #488 on: October 31, 2019, 08:58:42 PM »

Like turning on the light in your kitchen in the middle of the night and discovering an army of 10,000 cockroaches
Logged

Ishi
Pixelhead
Level 10
******


coffee&coding


View Profile WWW
« Reply #489 on: November 01, 2019, 09:54:44 AM »

Kind of a reply to your post on the Leilani devlog - I also had missed this devlog before! I browse the devlog forum fairly often but somehow never opened this thread. I've seen gifs before though (on other threads) and the general concept of this is great. I can see it resulting in some really unique and mind bending puzzles!



Once you've turned sideways, it feels to me that the one-way platform should also act as a one-way wall (and also a one-way ceiling if it was facing downwards above you). Do you have any thoughts about that? Though it could offer interesting puzzles if you are able to walk past the wall like you do in this gif.
Logged

diegzumillo
Level 10
*****


This avatar is so old I still have a some hair


View Profile WWW
« Reply #490 on: November 01, 2019, 12:47:51 PM »

Hey Ishi! o/

Quote
Once you've turned sideways, it feels to me that the one-way platform should also act as a one-way wall (and also a one-way ceiling if it was facing downwards above you). Do you have any thoughts about that? Though it could offer interesting puzzles if you are able to walk past the wall like you do in this gif.

Well, I didn't but I do now. I think it might work as a one-way wall as well (say "one way wall as well" very fast). What does your intuition tells you? Both can be used for puzzles, the more intuitive behavior is preferred.
Logged

Ishi
Pixelhead
Level 10
******


coffee&coding


View Profile WWW
« Reply #491 on: November 01, 2019, 01:01:37 PM »

Intuitively I think it should be a universal one-way barrier regardless of orientation, it would feel more physically consistent. The grassy top of the platform looks solid and impassable regardless of which orientation it's in.

Thinking about it, there are already ways to use the core mechanics of the game to create barriers that are only passable in a certain orientation - e.g. a tunnel that's too long to jump up through, but can be easily walked through if you turn it sideways. Whereas it's harder to build a universal one way barrier using the core mechanics. So using jump-through platforms to also fill that universal barrier niche seems like it would expand your level design options.
Logged

diegzumillo
Level 10
*****


This avatar is so old I still have a some hair


View Profile WWW
« Reply #492 on: November 01, 2019, 01:12:00 PM »

One-way barriers are indeed achievable with just proper level layout, and the main reason to do this one-way platform was to improve vertical movement. Like that tunnel with tiny platforms, jumping on them isn't fun and it's easy to miss one and fall.

But you make a good point for universal one-way barrier. That can't be achieved with clever layout alone.
Logged

nova++
Level 4
****


Real life space alien (not fake)


View Profile
« Reply #493 on: November 01, 2019, 10:45:51 PM »

I definitely like the idea of universal one-way walls and the puzzle possibilities thereof. I wonder if some sort of spring-loaded hatch sprite could work for it. When you go through the correct direction, in any orientation, it pops open and lets you through, then snaps shut. And when you try to go through it the other way, it won't budge (or play some sort of shake animation to help convey it). Just as an animation, though, the physics would be just an ordinary one-way wall/platform.



edit: I have noticed that this image is 6.66 kb in size, which isn't a bad omen at all
Logged

JobLeonard
Level 10
*****



View Profile
« Reply #494 on: November 02, 2019, 12:03:54 AM »

This is the most glorious fan art ever
Logged
diegzumillo
Level 10
*****


This avatar is so old I still have a some hair


View Profile WWW
« Reply #495 on: November 02, 2019, 09:01:41 AM »

I definitely like the idea of universal one-way walls and the puzzle possibilities thereof. I wonder if some sort of spring-loaded hatch sprite could work for it. When you go through the correct direction, in any orientation, it pops open and lets you through, then snaps shut. And when you try to go through it the other way, it won't budge (or play some sort of shake animation to help convey it). Just as an animation, though, the physics would be just an ordinary one-way wall/platform.

https://i.imgur.com/ltRA6uj.png

edit: I have noticed that this image is 6.66 kb in size, which isn't a bad omen at all

(removed image tag for quoting purposes, even though that is a glorious art)

You know, that would be the most intuitive version of a universal one-sided wall. Ishi made a good point for universal one-way wall, but the visual design of a normal one-sided platform (grassy top with background body) is very dubious when you can reach it at different orientations. Maybe I should ditch that design completely. It's not unexpected most of the traditional platformer tropes won't translate well to this game anyway. And your idea completely removes any alternative interpretations. The only tricky bit is the art. Just like the logic trapdoor, if I make it sideways, like your image, it will have a pre-determined size, if I make the hinge axis parallel to the screen, like my trapdoor design, it will be hard to read.

Those are problems for future me! right now the gameplay demo needs more levels and less thinking.

Some updates on the demo and physics:

Remember my complaints about the game being all wonky and felt like it was going to implode at any second? I think those fixed bugs were the culprit. Look at this unnecessary gif:



It's unnecessarily a gif for a very happy reason: it is not moving! a stack of crates is just there being a stack of crates. That tiny jiggle is nothing compared to the popcorn rave it was before!

Also added a really crazy curvy corridor to the first level. Princessa was right, I need to rub the main thing of the game on the player's face as fast as possible, even if it is just cosmetic.



I'm finding the control points for the mesh annoyingly weak. I have to drag them to the other side of the planet to nudge the mesh a little. It's a traditional bezier surface, maybe I can tweak it or add weights.

I did notice there is nothing that dictates the mesh needs to be on a 2D plane. I haven't made use of it yet but it could be fun to have overlaps, as long as nothing important from the level is blocked. Two corridors braided with eachother seem like a nice visual thing but, beyond that, sometimes it's also hard to accommodate all the twists and turns of a level on the plane.
Logged

oahda
Level 10
*****



View Profile
« Reply #496 on: November 02, 2019, 09:15:21 AM »

 Kiss Kiss Kiss Kiss



Also Silisko's drawing is amazing.
Logged

diegzumillo
Level 10
*****


This avatar is so old I still have a some hair


View Profile WWW
« Reply #497 on: November 02, 2019, 01:55:01 PM »

Kiss Kiss Kiss Kiss



Also Silisko's drawing is amazing.

Where is this from?

For the first scale-changing level I wanted something a little more elaborate. Instead I have the simplest level ever. I might swap it for something more interesting, but right now I needed a little sandbox to also work on the player's parameter change when changing scale. All parameters need to be scaled with... scale. Otherwise apple will run faster and jump higher.

Logged

oahda
Level 10
*****



View Profile
« Reply #498 on: November 02, 2019, 03:26:21 PM »

Ohhh, I'm so hyped to shrink down and enter the tiny world!!!

Where is this from?
Majora's Mask (3DS version)!
Logged

nova++
Level 4
****


Real life space alien (not fake)


View Profile
« Reply #499 on: November 02, 2019, 04:30:20 PM »

I love this tech so much. I really want to try my hand at making levels with it someday... not to add pressure on you to make end-user editor tools  Tongue
Logged

Pages: 1 ... 23 24 [25] 26 27 ... 33
Print
Jump to:  

Theme orange-lt created by panic