wiremod / wire

Garry's Mod add-on that allows users to wire up components in order to make more elaborate automatic and user-controlled contraptions.
http://www.wiremod.com
Apache License 2.0
551 stars 331 forks source link

Fix RT Camera OnRemove detection #3027

Closed wrefgtzweve closed 4 months ago

wrefgtzweve commented 4 months ago

Currently ObservedCamerasIndex isn't fully cleared which can cause RT material leakage.

After talking with @stepa2 he localized the issue to be in OnRemove which this PR fixes.

This also fixes the console command wire_rt_camera_recreate erroring.

The argument passed into OnRemove should be available on gmod main branch too but it's not entirely clear on the wiki, i've aksed the gmod devs to be sure.

thegrb93 commented 4 months ago

The argument passed into OnRemove should be available on gmod main branch too but it's not entirely clear on the wiki, i've aksed the gmod devs to be sure.

I guess let us know when sure

wrefgtzweve commented 4 months ago

Seems like its in the base game, rubat just removed the warning from the wiki after i asked about it https://wiki.facepunch.com/gmod/ENTITY:OnRemove~diff:561626