Dark Bit Factory & Gravity

PROGRAMMING => Freebasic => Topic started by: Clyde on July 06, 2008

Title: Tiny PTC Extension Problems
Post by: Clyde on July 06, 2008
For some daft reason the following code running under vista ultimate with service pack 1, makes it's self not work and closes upon compiling.

Thought I'd let you know, and perhaps there's a solution.

Code: [Select]
Option Static
Option Explicit

#Include Once "TinyPtc_ext.bi"
#Include Once "Windows.bi"

Const XRES=640
Const YRES=480

Const ARES=XRES*YRES

Dim ScreenBuffer(ARES)


Ptc_SetDialog(1,"Would You Prefer Fullscreen Dude?",0,0)

If( ptc_open( "Tester", XRES, YRES ) = 0 ) Then
    End -1                                   
End if

Dim Key As String

While Key<>Chr(27)
   
    PTC_Update@ ScreenBuffer(0)
   
    Key=Inkey()
   
    Erase ScreenBuffer
   
Wend

PTC_Close()

Cheers and many thanks,
Clyde.
Title: Re: Tiny PTC Extension Problems
Post by: Shockwave on July 06, 2008
It works perfectly here Clyde.

I know this sounds stupid but have you tried running it with an older version of Freebasic?

I dont thing Rbz's ptc ext is compatible with the shit new oop versions
Title: Re: Tiny PTC Extension Problems
Post by: Rbz on July 08, 2008
@Clyde: I've no idea what could cause this problem, I don't have Vista here.

Does freebasic original tinyptc works for you ?
Title: Re: Tiny PTC Extension Problems
Post by: Clyde on July 08, 2008
This is strange as just one particular project stops working with both the extension and regular tinyptc. And Im using an older version of Freebasic too.
Title: Re: Tiny PTC Extension Problems
Post by: DrewPee on July 08, 2008
Clyde,
I running Vista Ultimate (32bit) version (fully updated), and that runs okay on my machine?

Andy