home *** CD-ROM | disk | FTP | other *** search
- {∞TuC∞TuC∞TuC∞TuC∞TuC∞TuC∞TuC∞TuC∞TuC∞TuC∞TuC∞TuC∞TuC∞TuC∞TuC∞TuC∞TuC∞TuC∞TuC∞
- ┌───────────────────────────────────────────────────────────────────────────┐
- │EXAMPLE 3 & TGP is Copyright (c)1994,95 by Gunther Voet - aka Freaker / TuC│
- ├───────────────────────────────────────────────────────────────────────────┤
- │ Starfield:Sinecure/Optimization:Freaker/Music:CAL.MOD (by kiwi ?) │
- └───────────────────────────────────────────────────────────────────────────┘
- ∞TuC∞TuC∞TuC∞TuC∞TuC∞TuC∞TuC∞TuC∞TuC∞TuC∞TuC∞TuC∞TuC∞TuC∞TuC∞TuC∞TuC∞TuC∞TuC∞}
-
-
- PROGRAM EXAMPLE_3;
-
- {This example shows you how to play a file copied binary to your executable }
- {file. You can do it manually by looking to the filesize, then do a OVLLOAD }
- {with the exact filesize of the execute (check again !), then perform a }
- {binairy copy, and you will get the same like this example ! }
- { }
- {A binairy copy can be performed by doing
- COPY EXAMPLE3.EXE/B+MODFILE.MOD/B TEST.EXE
-
- OR use COPY_BIN, also supplied in this package, you can see to the exact
- size you must add in the pascalfile, and the program will append any modfile
- to the executable. Remember: You must: - FIRST CHECK THE EXE SIZE
- or use "REALEXESIZE" as size.
- - CHANGE THIS IN THE PROGRAM
- - APPEND THEN THE MODFILE ! }
-
- {Then you will see the file will be played from position 71xxx (size of this}
- {executable file! - you can add more than one modfile, just do the same, and}
- {change the location of the file. Just DON'T forget to unload every modfile!}
-
-
- {$M 4096,0,8192} {This directive is NECESSARY for the mod-load}
- {2000 bytes heap & stacksize is REQUIRED for the player}
- {4096 bytes heap / 9128 stack is RECOMMENDED}
-
-
-
- {MUSIC ROUTINES}
- { V }
- USES TGP,TUC_DEMO;
- { ^ }
- {EXAMPLE GFX}
-
-
- begin
- tgp.debugmode:=true; {TGP debugmode on, display errors}
-
- TGP.QUICKSETUP;
- TGP.LOADOVL(REALEXESIZE); {LOAD OVERLAY}
-
- {EXAMPLE3.MOD is used as overlay}
-
- {Use "REALEXESIZE" if you use only ONE modfile in your executable.
- else use the number of the offset in the executable file.
-
- You can use REALEXESIZE if you compressed your file with PKLITE,
- DIET, ... REALEXESIZE will always give the amount of bytes stored
- in your executable file header.}
-
-
- TGP.INITCARD; {INITIALIZE CARD}
-
- TGP.STARTMUS; {MUSIC! MAESTRO}
-
- TGP.VOLUME(254); {BLOW 't UP !}
-
- tgp.pollbuffer; {Poll before initstars}
-
- initstars; {Initialize star routines}
-
- repeat {Start of Repeat}
-
- {You can eventually call "TGP.POLLMUSIC" or "TGP.POLLBUFFER"
- if you experience problems using TGP with interrupt dependent tasks.}
-
- plotstars; {plotstars by sinecure !}
-
- until port[$60]=1; {repeat until port $60 = 1 (faster }
- {than keypressed $60 = ESC (#27))}
-
- TGP.STOPMUS; {Stop music (before unitialize)}
- TGP.UNLOADMUS; {ALWAYS uninitialize !!!!!!!}
-
- uninit_demounit; {Go back to textmode & show copyright}
- end.
-