• If you have a mod, tool or prefab, please use the Resources section. Click Mods at the top of the forums.

Request: Motion Sensors- See through Bulletproof Glass

Grue

Refugee
As title suggests, I am trying to get motion sensors to work through Bulletproof glass as they do through bars.

I am also trying to figure out why cop vomit seems to travel through solid blocks to hurt things underneath.

The goal is to make bulletproof glass a viable way to protect electronics such as the motion sensor from being barfed on and damaged.

 
Not tested this but you likely would need to make a new material for bulletproof glass that has the property of: <property name="collidable" value="false"/> then on the bulletproffglass block set all the collision types except for sight.

 
Not tested this but you likely would need to make a new material for bulletproof glass that has the property of: <property name="collidable" value="false"/> then on the bulletproffglass block set all the collision types except for sight.
Ok, I will give it a try.

What is the property to set the other collision types?

 
Something like:

Code:
<property name="Collide" value="movement,melee,bullet,arrow,rocket"/>
Thank you.

Block "glassBulletproofMaster" already has those collide settings, and I modded the corresponding materials.xml to turn off collision as Xyth suggested, but the glass still blocks line of sight for the motion sensor.

Code:
<insertAfter xpath="/materials/material[@id='MglassBulletproof']/property[@name='MaxDamage']" >
	<property name="collidable" value="false"/>
</insertAfter>
 
Last edited by a moderator:
Your new material should be exactly the same as the material Mair then on the block set the collision as you did above leaving sight out of it. Also on the block dont override the light opacity of the material, keep it 0. If that doesnt work it may be a vanilla bug.

 
Your new material should be exactly the same as the material Mair then on the block set the collision as you did above leaving sight out of it. Also on the block dont override the light opacity of the material, keep it 0. If that doesnt work it may be a vanilla bug.
I was revisiting this issue as I updated my little pack of personal utility modlets for A19.

After rereading your earlier comments, I noticed something I had previously misunderstood. 

If the block will not override the opacity of the material, then I should make both the collision and opacity changes in Materials and then add in the collision filters back in at the Block level.

So this is what I came up with, I will test it later to see if it works.

Code:
    
    <!-- This should make motion sensors see through bulletproof glass -->
    <set xpath="/materials/material[@id='MglassBulletproof']/property[@name='LightOpacity']/@value">0</set>
    
    <insertAfter xpath="/materials/material[@id='MglassBulletproof']/property[@name='MaxDamage']" >
        <property name="collidable" value="false"/>
    </insertAfter>

   








 
Back
Top