Wallbang (Competitive FPS Shooter)

Im making a competitive fps shooter and i want to add wallbang im new to scripting any way on how to implement this?

wall bang mechanics are usually applied to material intended to look and act weak, brittle enough for bullets to go pass without losing much velocity and impact force

you can start by making ignoretables, set the parent of all walls you want to have a mechanic of wall bang to a folder probably named something like “wallBangWalls”

make a script then create a function that fires in a different non-yielding thread that will insert descendants in the folder in the wall bang folder, after that you can filter the raycast’s ignore list on whats inside the table by using global variables

hopefully you understood and good luck

Hmm i didnt really understand since im new to this would u be able to explain it more?

bruh start woth the basics then you move forward. If you’re a first timer then make a simple game. Not trying to demotivate u but start with the basics

2 Likes

Your right thanks alot!
(word fill)

yh no problem

ignore this

ignore this

tell me what you didn’t understand, i forgot that you are a new one so i’ll state some of the key factors in my explanation

tables are dictionaries/arrays which in this case we will be using the array kind (doesn’t matter though) and when you use table.insert(table, obj) it will like written insert a given object (only one at a time) to a specific folder

the reason why this is useful is to keep track of objects in number forms without even getting confused, there is a second parameter in the old raycasting method workspace:FindPartOnRayWithIgnoreList(ray, table) which will completely ignore objects part of that folder and go past it

the only issue is that the mouse position is still based on the ignored object so the ray is a minor bit useless, i don’t have much time explaining this but someone has already made another topic on this and you can find the answer with some bit of reading and stuff