Barriers/walls creation help

So this isn’t exactly level help
But I need to create impassable walls or barriers for a game in Java
Was wondering if anyone knows how to?

I need a little context here. What are you using to make the game? Like what game engine did you use or something.

I…coded it? It’s a team project for school. I’m in charge of collisions
I have two rectangles and I need to make it so that one rectangle can’t go through another. I can do collision detection.

But what software are you using to make it

InteliJ community and blueJ

K I’ll see if I can help. Prob not tho cuz I’m not good at JavaScript

1 Like

idk, put it in the player???

What does that mean???

Wait is it Java or JavaScript

Pretty sure just Java

As most programmers always say, when in doubt stackoverflow your way out.

Try looking through here. It’s literally the exact same question so I bet somebody has an answer in here.


'When stackoverflow doesn’t get it, use decade-old posts on Reddit."


i meant like disable the player movement/gravity if the position is close to the wall position

1 Like

I was able to make it :+1:
Thank you :D


This topic was automatically closed 12 hours after the last reply. New replies are no longer allowed.