• Log InLog In
  • Register
Liquid`
Team Liquid Liquipedia
EDT 21:27
CEST 03:27
KST 10:27
  • Home
  • Forum
  • Calendar
  • Streams
  • Liquipedia
  • Features
  • Store
  • EPT
  • TL+
  • StarCraft 2
  • Brood War
  • Smash
  • Heroes
  • Counter-Strike
  • Overwatch
  • Liquibet
  • Fantasy StarCraft
  • TLPD
  • StarCraft 2
  • Brood War
  • Blogs
Forum Sidebar
Events/Features
News
Featured News
RSL Season 1 - Final Week6[ASL19] Finals Recap: Standing Tall12HomeStory Cup 27 - Info & Preview18Classic wins Code S Season 2 (2025)16Code S RO4 & Finals Preview: herO, Rogue, Classic, GuMiho0
Community News
Esports World Cup 2025 - Brackets Revealed7Weekly Cups (July 7-13): Classic continues to roll2Team TLMC #5 - Submission extension2Firefly given lifetime ban by ESIC following match-fixing investigation17$25,000 Streamerzone StarCraft Pro Series announced7
StarCraft 2
General
Esports World Cup 2025 - Brackets Revealed Who will win EWC 2025? Team TLMC #5 - Submission extension The GOAT ranking of GOAT rankings Esports World Cup 2025 - Final Player Roster
Tourneys
RSL: Revival, a new crowdfunded tournament series FEL Cracov 2025 (July 27) - $8000 live event $5,100+ SEL Season 2 Championship (SC: Evo) WardiTV Mondays Sparkling Tuna Cup - Weekly Open Tournament
Strategy
How did i lose this ZvP, whats the proper response Simple Questions Simple Answers
Custom Maps
External Content
Mutation # 482 Wheel of Misfortune Mutation # 481 Fear and Lava Mutation # 480 Moths to the Flame Mutation # 479 Worn Out Welcome
Brood War
General
BW General Discussion Flash Announces (and Retracts) Hiatus From ASL Starcraft in widescreen BGH Auto Balance -> http://bghmmr.eu/ A cwal.gg Extension - Easily keep track of anyone
Tourneys
Cosmonarchy Pro Showmatches [Megathread] Daily Proleagues CSL Xiamen International Invitational [BSL20] Non-Korean Championship 4x BSL + 4x China
Strategy
Simple Questions, Simple Answers I am doing this better than progamers do.
Other Games
General Games
Nintendo Switch Thread Stormgate/Frost Giant Megathread Path of Exile CCLP - Command & Conquer League Project The PlayStation 5
Dota 2
Official 'what is Dota anymore' discussion
League of Legends
Heroes of the Storm
Simple Questions, Simple Answers Heroes of the Storm 2.0
Hearthstone
Heroes of StarCraft mini-set
TL Mafia
TL Mafia Community Thread Vanilla Mini Mafia
Community
General
US Politics Mega-thread Russo-Ukrainian War Thread Summer Games Done Quick 2025! Things Aren’t Peaceful in Palestine Stop Killing Games - European Citizens Initiative
Fan Clubs
SKT1 Classic Fan Club! Maru Fan Club
Media & Entertainment
Movie Discussion! [Manga] One Piece Anime Discussion Thread [\m/] Heavy Metal Thread
Sports
Formula 1 Discussion TeamLiquid Health and Fitness Initiative For 2023 2024 - 2025 Football Thread NBA General Discussion NHL Playoffs 2024
World Cup 2022
Tech Support
Computer Build, Upgrade & Buying Resource Thread
TL Community
The Automated Ban List
Blogs
Men Take Risks, Women Win Ga…
TrAiDoS
momentary artworks from des…
tankgirl
from making sc maps to makin…
Husyelt
StarCraft improvement
iopq
Trip to the Zoo
micronesia
Customize Sidebar...

Website Feedback

Closed Threads



Active: 486 users

Student Game Dev Part Six - Even more physics

Blogs > Soan
Post a Reply
Soan
Profile Blog Joined August 2010
New Zealand194 Posts
December 20 2013 07:33 GMT
#1
Part One - It begins
Part Two - Technical Foundation
Part Three - Game Design
Part Four - Input and Physics
Part Five - More Physics Things

This Week
Hello again TeamLiquid!

Welcome back to my blog about the development of The Adventures of Sam the Pirate, the 2D platformer I'm creating as the final game project for my Bachelor of Software Engineering degree. I know I know, another blog on physics?! All of my work over the last few weeks has been on the physics, so that's all I've really got to talk about at the moment. Last week I covered my work on movement and collision detection, this week is updates on mostly more of the same, which might be a bit boring, but I've managed to get moving platforms working, and have a new piece of concept art to show off.

Collision Detection
Collision detection response is now more accurate. The player will always sit directly on top of a tile, rather than sink into it a little, which is perfect. The overall reaction is still a bit dodgy, as horizontal and vertical checks are done at the same time. So if the player lands directly on top of a tile, there's no problem. If the player hits the side of a tile, the horizontal response goes off and the player doesn't go through the tile, but the vertical response goes off as well and the player is teleported to either the top or bottom of the tile, depending on their height when they collided. Not 100% sure on how I'm going to fix this yet, so I'll need to do some thinking over the holidays.

Moving platforms!
On the upside, I've now got moving platforms! They make use of the same vertical collision response as previously mentioned, but because there's no vertical collision check, they work perfectly fine. If the player lands on the moving platform, they can ride back and forth as you'd expect, but it's a little dodgy at the moment. Every time the platform changes direction, the player continues in the previous direction for a few frames before turning around with the platform. If you ride the platform for long enough, eventually this effect will cause you to be shunted off, at which the point the players velocity is still matching the moving platform, so they just slide along. So it works, but it's pretty buggy.

New Concept Art
[image loading]

What's next?
No new blog posts for a couple of weeks, due to Christmas and New Years. I've got plans to still do some work, likely starting work on an interface framework, buttons and the like, so when I come back the next blog post will be about any progress I've made with that. Along with any work on fixing the physics that I manage to get done. Right now that will probably be around the 7th of January. Until then, I hope you all enjoy your Christmas and have a good New Years!

Keep up to date!
Be sure to follow me on Twitter, and like the Facebook page to stay up to date on future content and blog posts when they happen. If you have any questions don't hesitate to ask, either through Twitter or Facebook!

Tobberoth
Profile Joined August 2010
Sweden6375 Posts
December 20 2013 09:03 GMT
#2
I had that same collision detection issue recently, took me quite a while to figure out how to work around it. Basically, what you want to do, is check the axises separately. So first you do horizontal movement, if there is collision, you fix the horizontal movement. THEN you do the vertical movement, and fix it. Since you are always moving and checking only one direction at a time, it's always clear how the object should be moved, and you don't get jumpiness, you can always move it minimally. (This, of course, assumes axis aligned bounding boxes, I think it's far more complex otherwise).
stefantheterran
Profile Joined December 2013
Austria61 Posts
December 20 2013 12:35 GMT
#3
I look forward to your next update, hope you get lots of work done so you can show little more of your game (if you can/want)!
Cyx.
Profile Joined November 2010
Canada806 Posts
December 22 2013 04:17 GMT
#4
On December 20 2013 18:03 Tobberoth wrote:
I had that same collision detection issue recently, took me quite a while to figure out how to work around it. Basically, what you want to do, is check the axises separately. So first you do horizontal movement, if there is collision, you fix the horizontal movement. THEN you do the vertical movement, and fix it. Since you are always moving and checking only one direction at a time, it's always clear how the object should be moved, and you don't get jumpiness, you can always move it minimally. (This, of course, assumes axis aligned bounding boxes, I think it's far more complex otherwise).

Haha quoted for truth =D I've been following these blogs for a while without posting, but I just recently did a little game-engine project in 2d and I had the same problem =P resolved in the exact same manner. Just do them one at a time, and resolve them before you move on =) I really love these blogs though, I've gone through a ton of the same stuff as this.
Please log in or register to reply.
Live Events Refresh
Replay Cast
00:00
SEL Masters #4 - Day 2
CranKy Ducklings108
Liquipedia
[ Submit Event ]
Live Streams
Refresh
StarCraft 2
Nina 210
Livibee 130
ProTech55
StarCraft: Brood War
Artosis 836
Icarus 4
Dota 2
monkeys_forever861
NeuroSwarm150
League of Legends
JimRising 748
Trikslyr89
Counter-Strike
Fnx 1563
taco 347
Super Smash Bros
hungrybox766
Other Games
summit1g14628
shahzam1706
Day[9].tv395
C9.Mang0230
Maynarde153
Mew2King31
RuFF_SC219
Organizations
Other Games
gamesdonequick3522
BasetradeTV37
StarCraft 2
Blizzard YouTube
StarCraft: Brood War
BSLTrovo
sctven
[ Show 15 non-featured ]
StarCraft 2
• Berry_CruncH136
• Mapu4
• AfreecaTV YouTube
• intothetv
• Kozan
• IndyKCrew
• LaughNgamezSOOP
• Migwel
• sooper7s
StarCraft: Brood War
• BSLYoutube
• STPLYoutube
• ZZZeroYoutube
League of Legends
• Doublelift6170
• Scarra1661
Other Games
• Day9tv395
Upcoming Events
Replay Cast
8h 34m
WardiTV European League
14h 34m
ShoWTimE vs sebesdes
Percival vs NightPhoenix
Shameless vs Nicoract
Krystianer vs Scarlett
ByuN vs uThermal
Harstem vs HeRoMaRinE
PiGosaur Monday
22h 34m
uThermal 2v2 Circuit
1d 14h
Replay Cast
1d 22h
The PondCast
2 days
Replay Cast
2 days
Epic.LAN
3 days
CranKy Ducklings
4 days
Epic.LAN
4 days
[ Show More ]
BSL20 Non-Korean Champi…
4 days
Bonyth vs Sziky
Dewalt vs Hawk
Hawk vs QiaoGege
Sziky vs Dewalt
Mihu vs Bonyth
Zhanhun vs QiaoGege
QiaoGege vs Fengzi
Sparkling Tuna Cup
5 days
Online Event
5 days
BSL20 Non-Korean Champi…
5 days
Bonyth vs Zhanhun
Dewalt vs Mihu
Hawk vs Sziky
Sziky vs QiaoGege
Mihu vs Hawk
Zhanhun vs Dewalt
Fengzi vs Bonyth
Liquipedia Results

Completed

2025 ACS Season 2: Qualifier
RSL Revival: Season 1
Murky Cup #2

Ongoing

JPL Season 2
BSL 2v2 Season 3
CSL 17: 2025 SUMMER
Copa Latinoamericana 4
Jiahua Invitational
BSL20 Non-Korean Championship
Championship of Russia 2025
FISSURE Playground #1
BLAST.tv Austin Major 2025
ESL Impact League Season 7
IEM Dallas 2025
PGL Astana 2025
Asian Champions League '25
BLAST Rivals Spring 2025
MESA Nomadic Masters

Upcoming

CSL Xiamen Invitational
CSL Xiamen Invitational: ShowMatche
2025 ACS Season 2
CSLPRO Last Chance 2025
CSLPRO Chat StarLAN 3
BSL Season 21
K-Championship
RSL Revival: Season 2
SEL Season 2 Championship
uThermal 2v2 Main Event
FEL Cracov 2025
Esports World Cup 2025
Underdog Cup #2
ESL Pro League S22
StarSeries Fall 2025
FISSURE Playground #2
BLAST Open Fall 2025
BLAST Open Fall Qual
Esports World Cup 2025
BLAST Bounty Fall 2025
BLAST Bounty Fall Qual
IEM Cologne 2025
TLPD

1. ByuN
2. TY
3. Dark
4. Solar
5. Stats
6. Nerchio
7. sOs
8. soO
9. INnoVation
10. Elazer
1. Rain
2. Flash
3. EffOrt
4. Last
5. Bisu
6. Soulkey
7. Mini
8. Sharp
Sidebar Settings...

Advertising | Privacy Policy | Terms Of Use | Contact Us

Original banner artwork: Jim Warren
The contents of this webpage are copyright © 2025 TLnet. All Rights Reserved.