help with collision detection :(

Post a topic about yourself to let others know your skills, hobbies, etc.
Post Reply
FemboyTwink
What is PSXDEV?
What is PSXDEV?
Posts: 2
Joined: Dec 28, 2022

help with collision detection :(

Post by FemboyTwink » December 28th, 2022, 12:27 pm

Hi, im really sorry, but im new to all of this stuff and im trying to learn, i was wondering if anyone would be able to help me with collision detection, i only have a basic thing setup atm where you can move a box.

Thank you - Layla

User avatar
nocash
Verified
PSX Aficionado
PSX Aficionado
Posts: 541
Joined: Nov 12, 2012
Contact:

Post by nocash » December 28th, 2022, 3:03 pm

A box isn't bad. You could also use a circle, eg. dist=sqrt(xdist² + ydist²), if dist<radius then collide.
But say, are you talking about 2D or 3D, and what shape shall collide with which other shape(s)?

FemboyTwink
What is PSXDEV?
What is PSXDEV?
Posts: 2
Joined: Dec 28, 2022

Post by FemboyTwink » December 29th, 2022, 12:39 am

its just a 2D box shape, and i want it to be able to collide with the walls so that it can't leave the screen

Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests