Hi,
There is a transparency issue with newer model computers and windows os. The link below addresses it directly.
https://forum.thegamecreators.com/thread/211609#msg2548248
Basically, the way to approach it is to have layered objects with transparency and opposite alpha blending. So you make two of the same object. Texture them the same and put them into the exact same position. You set transparency on for both objects. Then:
ghost object on 1
ghost object on 2,1
Now, for object 1, to make sure the alpha blending is not still semi transparent, use SET OBJECT AMBIENT to increase the objects ambient lighting until the solid parts are solid.
Below is a snippet that shows the basics of it. Also note that I set the culling of the plane to off so that both sides of the plane can be seen from different camera angles and also different rotation angles of the object
REMSTART
==============================================================
= TITLE : DB Classic Transparency with Newer Windows
= Author : Latch
= Date : 05/31/2020
= UPDATE :
= Version: 1
==============================================================
Comments:
With the newer windows OSs and the change in graphics cards/drivers
DBC has issues with transparency and culling. Basically you have
to use a combination of ghosting (Alpha Blending) and transparency
settings to get reasonable results
==============================================================
REMEND
REM =============================================================
REM = SET UP DISPLAY
REM =============================================================
AUTOCAM OFF
SET DISPLAY MODE 800,600,32
SYNC ON
SYNC RATE 60
REM =============================================================
REM = MAIN
REM =============================================================
_main:
REM initialize environment
`set camera
gosub _init
DO
ang#=ang# + .5
x=cos(ang#)*90
z=sin(ang#)*90
`Rotate the plane with the hole in it
turn object right 1,2
turn object right 3,2
`move camera
position camera x,0,z
point camera 0,0,0
`reposition plane with camera but offset a little
newx#=newxvalue(x,camera angle y(),30)
newz#=newzvalue(z,camera angle y(),40)
position object 1,newx#,0,newz#
position object 3,newx#,0,newz#
if ang#>=360 then ang#=0
SYNC
LOOP
END
REM =============================================================
REM = SUBROUTINES - PROCEDURES
REM =============================================================
_init:
REM make a red box texture with a hole in it
ink rgb(255,0,0),0
box 0,0,256,256
ink 0,0
x=128 : y=128
FillCircle(x,y,64)
get image 1,0,0,256,256
sync
rem make a plane and slap the texture on it
make object plain 1,25,25
texture object 1,1
`SET OBJECT Object Number, Wireframe, Transparency, Cull, Filter, Light, Fog, Ambient
set object 1,1,0,0
ghost object on 1
set object ambient 1,rgb(255,255,255)
make object plain 3,25,25
texture object 3,1
`SET OBJECT Object Number, Wireframe, Transparency, Cull, Filter, Light, Fog, Ambient
set object 3,1,0,0
ghost object on 3,1
rem make a box behind the plain
make object box 2,50,5,5
position object 2,0,0,20
rem put a sphere out in the landscape
make object sphere 4,30
position object 4,-30,2,-10
sync
return
REM =============================================================
REM = FUNCTIONS
REM =============================================================
function FillCircle( CX, CY, R )
sR = R*R
for i = 1 to R
h = sqrt( sR - i*i )
box CX - i, CY - h, CX + i, CY + h
next i
endfunction
REM =============================================================
REM = DATA STATEMENTS
REM =============================================================
Enjoy your day.