#Physics updates

1 messages ยท Page 1 of 1 (latest)

keen pecan
#

One message removed from a suspended account.

#

One message removed from a suspended account.

#

One message removed from a suspended account.

#

One message removed from a suspended account.

#

One message removed from a suspended account.

tepid ether
keen pecan
#

One message removed from a suspended account.

#

One message removed from a suspended account.

tepid ether
#

Hold on I'll make a little video so it's a little less abstract

#

Okay so first of all here is the original problem I'm trying to avoid. The bombs should do 200 Damage to any object, you can see the HP on the right. Since the bench has 3 colliders, it does triple the damage

#

however

#

There's some attacks that spawn two hitboxes from the same script too (like a weak part and a strong part)

#

Buuut yeah lemme try your idea first because if it just works I don't need to explain any further haha

#

Okay yeah works as a thought. It does 200 damage, but ignores silmultanious triggers. This is already an improvement though, as this is way more of an edge case than the previous one. So thank you already! (: โค๏ธ Let's see if it's possible to fix that second thing too though

keen pecan
#

One message removed from a suspended account.

#

One message removed from a suspended account.

#

One message removed from a suspended account.

tepid ether
keen pecan
#

One message removed from a suspended account.

#

One message removed from a suspended account.

tepid ether
#

Also List by itself doesn't exist ๐Ÿ‘๏ธ๐Ÿ‘„๐Ÿ‘๏ธ

keen pecan
#

One message removed from a suspended account.

tepid ether
#

oh ty haha

#

๐Ÿ‘๏ธ๐Ÿ‘„๐Ÿ‘๏ธ ยฒ

#

oh collections.generic, got it

keen pecan
#

One message removed from a suspended account.

#

One message removed from a suspended account.

tepid ether
keen pecan
keen pecan
tepid ether
#

I think everything working as intended, there is a little spike when I use hitboxes every frame, but i commented out your part and it's still there so it's just my shit code that I'll work on myself ๐Ÿ‘

opal gale
# keen pecan One message removed from a suspended account.

What? No... use hasTouched.Clear() to remove all entries from the list.

To save a few code operations and easen the garbage collection
This is completely wrong. When you "reset" the List<GameObject> by instantiating it again every frame you create more garbage and requires more operations to be executed. Just instantiate a List in the class and call hasTouched.Clear() when necessary.