Trouble with TxAlpha and AlphaPR now in 9.1.1

The topic now is unanswered for quite a long time, maybe there is no solution or the script interface is no longer supported?
In Version 7 the method for applying Translucency in scripts for MSTS models was changed. I need this for makling the ballast of tracks beeing translucent to the ground.

for me it worked like such:

Dim TxAlpha, AlphaPr

TxAlpha = 3DCapp.GetMaterialCustomFieldID(‘Tx Alpha’)
If TxAlpha = -1 Then
TxAlpha = 3DCapp.AddMaterialCustomField(‘Tx Alpha’)
End If

AlphaPr = 3DCapp.GetMaterialCustomFieldID(‘Alpha Pr’)
If AlphaPr = -1 Then
AlphaPr = 3DCapp.AddMaterialCustomField(‘Alpha Pr’)
End If

matbase.SetCustomFieldValue TxAlpha, ‘Translucency’ ‘Translucency/Transparency/None’
matbase.SetCustomFieldValue AlphaPr, ‘1’ ‘0/1’

In version 8 and again some time later for version 9 it changed again. I am a bit puzzled if I should stay with the custom Fields, or if I should use the new Get- and SetTanslucent Methods. But I found nothimg about the Alpha Priority. Does anyone have useful hints for me besides staying with 3DC7?

regards,

Ytracks

You must be logged in to reply in this thread.

1 post
recent posts