26-05-2008, 11:29 PM
Add this to the bottom of:Public Sub BltTile(ByVal x As Long, ByVal y As Long)
The variable night refers to which tile it is going to blit over. So make your second tile on your tile sheet a 32x32 checker board. Dim Night as 1.
This is a very primitive way to display night. If you want to just test it as night all the time, get rid of the if statement.
Code:
If GameTime = 1 Then
With rec
.top = Int(Night / 32) * PIC_Y
.Bottom = .top + PIC_Y
.Left = (Night - Int(Night / 32) * 32) * PIC_X
.Right = .Left + PIC_X
End With
Call DD_BackBuffer.BltFast(x * PIC_X, y * PIC_Y, DD_TileSurf, rec, DDBLTFAST_WAIT Or DDBLTFAST_SRCCOLORKEY)
End If
The variable night refers to which tile it is going to blit over. So make your second tile on your tile sheet a 32x32 checker board. Dim Night as 1.
This is a very primitive way to display night. If you want to just test it as night all the time, get rid of the if statement.