Jump to content

Request: Motion Sensors- See through Bulletproof Glass


Grue

Recommended Posts

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.

Link to comment
Share on other sites

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.

Link to comment
Share on other sites

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?

Link to comment
Share on other sites

Something like:

 

<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.

 

 	
<insertAfter xpath="/materials/material[@id='MglassBulletproof']/property[@name='MaxDamage']" >
	<property name="collidable" value="false"/>
</insertAfter>

Link to comment
Share on other sites

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.

Link to comment
Share on other sites

  • 7 months later...
On 12/31/2019 at 8:00 AM, xyth said:

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.

 

    
    <!-- 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>

   

 

 

 

 

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...