Page 1 of 1

[GTA IV] car window don't break

PostPosted: Sun Apr 09, 2017 11:46 pm
by xX_Racer_Xx
I have converted Koenigsegg Regera for GTA IV but it's window don't break. Bullets passed through it, every window or glass is unbreakable. it happened to other models too which i converted. anyone have fix for it ?

Re: [GTA IV] car window don't break

PostPosted: Mon Apr 10, 2017 6:13 am
by Oleg
glass break requires two UV channels to be available on a model file and secondary UV channel to have some ordinary (projected from front or top or side view) mapping layout. Additionally, collision object associated with window should have correct ID values set on polygons (I can't remind exact values, inspect original game model). And finally, chassis model's collision should have proper ID value on polygons that relates to window and doors. This specific ID value tells the game to let player pass by and let bullets fly through chassis collision on these particular polygons, as "some other collision model will take respond to this action" (allowing window to take proper respond if it's not yet broken). If I'm not mistaken, value of 2 is "pass through", inspect original game model as a reference too.

Re: [GTA IV] car window don't break

PostPosted: Mon Apr 10, 2017 4:46 pm
by xX_Racer_Xx
I'm using stock COL model (imported from stock car model), so I think it is already having all properties as you mentioned. But windows still don't break.

Re: [GTA IV] car window don't break

PostPosted: Tue Apr 11, 2017 4:00 am
by Oleg
ensure your window has L1 models too, as these are essential for glass crash effect.

Re: [GTA IV] car window don't break

PostPosted: Tue Apr 11, 2017 4:10 pm
by xX_Racer_Xx
I added L1 model, now bullet don't pass through it but still it don't break window.

Re: [GTA IV] car window don't break

PostPosted: Thu Apr 13, 2017 4:26 am
by Oleg
import original game model and examine material settings. all texture slots and their settings are essential.

do you have UV#2 on a geometry and have you made some uv-mapping for UV#2 too? the game uses UV#2 to draw glass cracks.

Re: [GTA IV] car window don't break

PostPosted: Thu Apr 13, 2017 8:24 pm
by xX_Racer_Xx
All materials are correct and windows have UV too. The rear light glass break but none of the window break.