Home Artists Posts Import Register
The Offical Matrix Groupchat is online! >>CLICK HERE<<

Content

Whew! I pulled it off but it's a doozy at 51 minutes.

Don't be too intimidated by its length, the system is actually relatively straightforward it just has a few gotchas and moving parts that have to be explained so that it is used correctly as it's very easy to mess up on this one! For advanced programmers I'd like to put together a gif or short <1 minute video that just explains the _concept_ so that people don't have to sit through the longer explanations.

It'd be a shame to keep the source code locked up for this one so I want to share it outside of just here. But I also put a ton of time and energy into this project, so while all my $5+ supporters will get hold of the source files for free as usual I'm going to put the final source files behind a $1 minimum PWYW on itch.io. The base project will be available to everyone so that you can follow this video without necessarily having done the tile collision video and turned it into a full platformer.

To stop any sneaky fake-patrons I'll be handing out access via a bulk message so expect that tomorrow.

I'd release all this tonight but I've already sort of overworked today and there's a lot of set up to do. It's 8pm my time and I'm still turning cogs which aint healthy =( But I'll get it out as soon as I can tomorrow! After it's all released I'll likely stream some Tribal Tension dev work so feel free to join me at twitch.tv/shaunjs!

Then on Monday we can launch the next Topic Poll and see where we go from here! Sorry this one has taken so long but I'm pretty happy with the resulting system. Only sad I couldn't get the video length down any further, but I like to err on the side of thoroughness and quality. I want to produce for YOU guys rather than produce for "What works on YouTube" which is short, snappy and attention grabbing. But if you think I'm leaving in too much fat and you'd prefer to see me trim this stuff down more, let me know!

Thanks again so much for all of your support. =)

Files

Comments

Anonymous

Glad to have an update on this. I'm curious to see how much different it is from the old method from years by.

shaunjs

Since I'm sat here watching it render the last few frames so I can set it encoding and be done I'll walk you through it: 1. build a height table out of your collision tiles (a global array containing the height of each column). This is done dynamically at the start of the game by drawing them to a surface and using a for loop to check for coloured pixels. 2. when you collide horizontally, ignore the bottom corner pixels if you're currently on a slope (by getting the current tile index) to allow you to transition smoothly from slope to solid. 3. when you collide vertically, if you're on a slope, skip your regular collision walking up: 4. either way after this, compare your in-tile y position against the appropriate entry in the height table to see how far you are inside the ground (if at all). Move so that this distance is -1 above the ground. walking down: 5. if you were touching the ground at the start of the frame and haven't pressed jump or walked off a cliff, then at the end of the frame move down, again so the distance between you and the floor is -1. done!