Holy fucking shit I don't want to work on this. Sibly, you son of a ...

This commit is contained in:
Michael Fabain Dirks
2016-05-07 22:49:54 +02:00
parent b75ca4142c
commit aa22d21fb5
2577 changed files with 166501 additions and 194685 deletions
@@ -0,0 +1,10 @@
<TITLE>
-------
Author: <AUTHOR>
Email: <EMAIL>
WWW: <WEBSITE>
Sample About Text..
Write anything you want here.
@@ -0,0 +1,62 @@
BB Launcher V1.00
Written by Rob Hutchinson 19/08/2001
Requires VB Runtimes. You can get these from:
ftp://ftp.microsoft.com/Softlib/MSLFILES/VBRUN60sp3.EXE
BBLauncher specifically needs the MSVBVM60.DLL file. Which is the VB6 runtime dll.
It is included with the above runtimes and resides in <SYSTEM>\System dir, (IE
C:\Windows\System\, or C:\WINNT\System\) windows now comes with the VB runtimes
already installed (WinME, 2K and XP), and anyone running 95/98/NT will probably
already have installed the VB runtimes or another application might have.
But if you want to make sure that it definately runs on the end user machine,
just drop the MSVBVM60.DLL file in the same directory as Launcher.EXE.
INI Files:
There are 2 INI files (Launcher.INI and Launcher_CLEAN.INI) that come with the
launcher and 1 that is generated when you run BBLauncher (Settings.INI).
BBLauncher uses Launcher.INI to set itself up. And generates Settings.INI
on exit, depending on the options the user picks (provided they enable setting
saving which is on by default). Launcher_CLEAN.INI is just a "CLEAN" version of
Launcher.INI which is full of comments to help you set it up (not that its hard :))
But use Launcher_CLEAN.INI once you know what everything does. Just rename it
to Launcher.INI.
Programming:
Its pretty simple to use in your own program. If you're writing a 2D program
include "launcher2d.bb" and if you're writing a 3d program include "launcher3d.bb"
in place of GraphicsXX x,x,x,x : Setbuffer BackBuffer().
Basically the include will setup the screen for you, by default the screenmode
will be 640x480x16. But you can override this during development by adding a
command line from the blitz menu. The params are formatted: "/<OPTIONS><PARAMS>"
This: /TYPE0 /WIDTH1024 /HEIGHT768 /BPP32 /ADDIT1
Will open a 1024x768x32 screen in Fullscreen-Always, with the additional option
set to true.
The additional option param is /ADDITx, and to query it in your program just
read the iAdditional variable, this will either be 0 or 1 depending on what
the user selected. Don't forget you can disable the additional option in the INI
and ignore it in code, if you like.
Check out the example.bb program for usage.
Well thats about it really..
Have fun. And email me if you use it in something you wrote, I`d like to see how
many people would actually use it. If people are interested in it then I have a
lot of features I`d like to add that I probably wouldn`t use myself but would be
very useful to others. But I wont add them if noone is interested in it. So email
me if you are: loki.sd@cableinet.co.uk
One of the planned features is a fully customisable options section, which you
could put things like "Enable WBuffer", or well, basically anything... I didn`t
do this originally because it would need some more components that I didn`t want
to have to include in the distro ATM BBLauncher only uses the standard VB
components, and it was written purposly that way.
--
Rob Hutchinson, loki.sd@cableinet.co.uk / 27181384
End
@@ -0,0 +1,102 @@
;
; BBLAUNCHER V1.00 MAIN INIT FILE
; -------------------------------
;
; Feel Free To use BBLauncher With your own Programs!
; Dont Forget it requires VB runtimes, you can get these as a separate
; package from the MS website or you can just drop MSVBVM60.DLL from
; your system / system32 dir. WinME,2K and XP all come with the VB
; runtimes though and 98 users generally have them installed anyway.
; but if you want to be on the safe side, just drop the dll in the
; launcher dir.
;
; --
; Rob Hutchinson - 12/08/2001
; loki.sd@cableinet.co.uk
;
; Here are the main options. Here you can change the look and configuration of
; BB Launcher.
[Details]
; --> The name of your program.
Program Name = Example INI
; --> The build of your program.
Build = #0000
; --> The version of your program.
Version = 1.00
; --> Your name.
Author = Bub Elfig
; --> Your email.
Email = host@domain.sec
; --> The text to put in the window titlebar.
Title = Example INI
; --> The text to put in the options frame.
Frame = Options:
; --> The name of the text file to display in the about window.
About = About.TXT
; --> The name of your application.
Executable = MyProgram.EXE
; --> The icon to use (REQUIRED)
Icon = Icon.ico
; --> A colour for the banner atop the windows.
Banner Colour = &H00008080
; --> An additional option.
Additional Option Name = An Option.
; Resolution you want your program to possibly display. If the user does not have one
; of the following resolutions then your program will throw them back to the launcher
; and tell them that their GFX card doesn`t support the mode they selected.
[Resolutions]
Res[0] = 640x480
Res[1] = 320x200
Res[2] = 320x240
Res[3] = 400x300
Res[4] = 720x480
Res[5] = 720x576
Res[6] = 800x600
Res[7] = 960x720
Res[8] = 1024x768
Res[9] = 1280x1024
Res[10] = 1600x1200
; A list of possible depths. I doubt you`ll need or want to change any of these.
[BitsPerPixel]
BPP[0] = 16
BPP[1] = 24
BPP[2] = 32
; A list of disable flags. If for any reason you want to disable any options change
; these to "True" to disable, chantge to "False".
[Disables]
; --> Disable the fullscreen option?
DisableFullscreen = False
; --> Disable the scaled window option?
DisableScaled = False
; --> Disable the static window option?
DisableStatic = False
; --> Disable the program about button, if this is true you dont need to specify an about text above.
DisableAbout = False
; --> Disable the ability to save options?
DisableSaveSettings = False
; --> Disable the additional option button?
DisableAddition = False
Binary file not shown.
@@ -0,0 +1,45 @@
;
; BBLAUNCHER V1.00 INIT FILE
; Rob Hutchinson - 12/08/2001
; loki.sd@cableinet.co.uk
;
[Details]
Program Name = Example INI
Build = #0000
Version = 1.00
Author = Bub Elfig
Email = host@domain.sec
Title = Example INI
Frame = Options:
About = About.TXT
Executable = MyProgram.EXE
Icon = Icon.ico
Banner Colour = &H00008080
Additional Option Name = An Option.
[Resolutions]
Res[0] = 640x480
Res[1] = 320x200
Res[2] = 320x240
Res[3] = 400x300
Res[4] = 720x480
Res[5] = 720x576
Res[6] = 800x600
Res[7] = 960x720
Res[8] = 1024x768
Res[9] = 1280x1024
Res[10] = 1600x1200
[BitsPerPixel]
BPP[0] = 16
BPP[1] = 24
BPP[2] = 32
[Disables]
DisableFullscreen = False
DisableScaled = False
DisableStatic = False
DisableAbout = False
DisableSaveSettings = False
DisableAddition = False
@@ -0,0 +1,53 @@
;
; LAUNCHER 2D EXAMPLE V1.00
; -------------------------
; Simply shows usage of the BBLauncher includes.
; Written by Rob Hutchinson 2001
; Email: loki.sd@cableinet.co.uk / ICQ: 27181384
;
; Last Modified: 19/08/2001
;
; DONT FORGET:
; During development you can fiddle with the options that the launcher would
; return with the commandline. Goto menu - Program > Program Command Line..
; and enter a string in the format:
;
; "/TYPE<Screen> /WIDTH<Width> /HEIGHT<Height> /BPP<Depth> /ADDIT<Additional>"
; Where <Screen> is either:
; 0 = FULLSCREEN
; 2 = WINDOWED or
; 1 = SCALED
;
; <Width> = display width, <Height> = display height, <Depth> = display depth.
;
; If you do not specify a command line, the default resolution of: 640x480x16
; (fullscreen always), will be assumed.
;
; Include the bblauncher 2D include here in place of Graphics() and SetBuffer BackBuffer()
Include "launcher2d.bb"
; Draw something screen scalable..
iOffset = 50
iCount = 0
Repeat
; Print the status of the additional option, -1 = no /ADDIT, 0 = Additional option -
; false, 1 = Additional option - true. Set /ADDIT1 in the commandline.
Color 255,255,255
Text 0,0,"Additional Option: " + iAdditional
; Print a scalable square in the center of the screen.
iCount = QWrap(iCount+4,0,255)
Color iCount,-iCount,iCount
Rect iOffset,iOffset,GraphicsWidth()-(iOffset*2),GraphicsHeight()-(iOffset*2)
Flip
Until KeyDown(1)
End
; Functions:
Function QWrap(Value#,Low#,High#) ; Remember this? where is the Blitz
Return Low#+(Value# Mod High#) ; PC version when you need it? :))
End Function
Binary file not shown.

After

Width:  |  Height:  |  Size: 2.5 KiB

@@ -0,0 +1,60 @@
;
; LAUNCHER 2D INCLUDE V1.02
; -------------------------
; Simple Include to handle startup for programs written
; to use BBLauncher.
; Written by Rob Hutchinson 2001
; Email: loki.sd@cableinet.co.uk / ICQ: 27181384
;
; Last Modified: 18/08/2001
;
; Some default values, change these if you like...
Const RESOLUTION_DEFAULT_WIDTH = 640
Const RESOLUTION_DEFAULT_HEIGHT = 480
Const RESOLUTION_DEFAULT_DEPTH = 16
; This is the command line..
Global sCL$ = Upper(CommandLine())
; Find the screen mode...
iScrType = bblGetOption("TYPE",0)
Select iScrType
Case 1
iScreenMode = 3
HidePointer()
Case 2
iScreenMode = 2
HidePointer()
Case 0
iScreenMode = 1
End Select
; Get the screen details!
Global iScreenResX = bblGetOption("WIDTH",Str(RESOLUTION_DEFAULT_WIDTH))
Global iScreenResY = bblGetOption("HEIGHT",Str(RESOLUTION_DEFAULT_HEIGHT))
Global iBitsPerPixel = bblGetOption("BPP",Str(RESOLUTION_DEFAULT_DEPTH))
Global iAdditional = bblGetOption("ADDIT",-1)
; Work with the details!
If GfxModeExists(iScreenResX,iScreenResY,iBitsPerPixel)
Graphics iScreenResX,iScreenResY,iBitsPerPixel,iScreenMode
SetBuffer BackBuffer()
Else
; Fire it back out to the launcher cos screen res is unsupported...
ExecFile "Launcher.exe"
RuntimeError "The graphics card in this machine does not support the selected screenmode!" + Chr(10) + Chr(13) + "Please select another..."
End
EndIf
; FUNCTIONS ->
;------------------
Function bblGetOption$(opts$,defaultstr$="")
iInTmp = Instr(sCL$,"/" + opts$)
If iInTmp <> 0
iInTmp2 = Instr(Mid$(sCL$,iInTmp)," ")
Return Mid$(Mid$(sCL$,iInTmp+Len(opts$)+1),1,iInTmp2-(Len(opts$)+2))
Else
Return defaultstr$
EndIf
End Function
@@ -0,0 +1,60 @@
;
; LAUNCHER 3D INCLUDE V1.02
; -------------------------
; Simple Include to handle startup for programs written
; to use BBLauncher.
; Written by Rob Hutchinson 2001
; Email: loki.sd@cableinet.co.uk / ICQ: 27181384
;
; Last Modified: 18/08/2001
;
; Some default values, change these if you like...
Const RESOLUTION_DEFAULT_WIDTH = 640
Const RESOLUTION_DEFAULT_HEIGHT = 480
Const RESOLUTION_DEFAULT_DEPTH = 16
; This is the command line..
Global sCL$ = Upper(CommandLine())
; Find the screen mode...
iScrType = bblGetOption("TYPE",0)
Select iScrType
Case 1
iScreenMode = 3
HidePointer()
Case 2
iScreenMode = 2
HidePointer()
Case 0
iScreenMode = 1
End Select
; Get the screen details!
Global iScreenResX = bblGetOption("WIDTH",Str(RESOLUTION_DEFAULT_WIDTH))
Global iScreenResY = bblGetOption("HEIGHT",Str(RESOLUTION_DEFAULT_HEIGHT))
Global iBitsPerPixel = bblGetOption("BPP",Str(RESOLUTION_DEFAULT_DEPTH))
Global iAdditional = bblGetOption("ADDIT",-1)
; Work with the details!
If GfxMode3DExists(iScreenResX,iScreenResY,iBitsPerPixel)
Graphics3D iScreenResX,iScreenResY,iBitsPerPixel,iScreenMode
SetBuffer BackBuffer()
Else
; Fire it back out to the launcher cos screen res is unsupported...
ExecFile "Launcher.exe"
RuntimeError "The graphics card in this machine does not support the selected screenmode!" + Chr(10) + Chr(13) + "Please select another..."
End
EndIf
; FUNCTIONS ->
;------------------
Function bblGetOption$(opts$,defaultstr$="")
iInTmp = Instr(sCL$,"/" + opts$)
If iInTmp <> 0
iInTmp2 = Instr(Mid$(sCL$,iInTmp)," ")
Return Mid$(Mid$(sCL$,iInTmp+Len(opts$)+1),1,iInTmp2-(Len(opts$)+2))
Else
Return defaultstr$
EndIf
End Function
@@ -0,0 +1,21 @@
1.000000
0
0.000000
0.050000
30
0
0
0.000000
SDS.bmp
Brick1.bmp
-1
0
0
0
1.000000
0
1
1
420
2000.000000
10
@@ -0,0 +1,21 @@
1.000000
0
0.000000
1.500000
15
0
0
1.000000
Stone1.bmp
Wood1.bmp
-1
0
0
0
1.000000
0
1
1
150
2000.000000
12
@@ -0,0 +1,21 @@
0.010000
0
0.000000
3.000000
100
0
0
0.000000
BlueMush.bmp
Marble1.jpg
1
0
0
0
1.000000
0
1
1
0
100.000000
25
@@ -0,0 +1,21 @@
0.010000
0
0.000000
3.000000
100
0
0
0.000000
BlueMush.bmp
Marble1.jpg
0
0
0
0
1.000000
0
1
1
0
2000.000000
25
@@ -0,0 +1,21 @@
1.000000
1
0.100000
1.000000
30
0
0
1.000000
SDS.bmp
Brick1.bmp
-1
0
0
0
1.000000
0
1
1
10
2000.000000
25
@@ -0,0 +1,21 @@
1.000000
1
1.500000
1.000000
30
0
0
1.000000
SDS.bmp
Brick1.bmp
-1
0
0
0
1.000000
0
1
1
10
2000.000000
25
@@ -0,0 +1,21 @@
1.000000
0
0.000000
1.500000
30
0
0
1.000000
SDS.bmp
Brick1.bmp
-1
0
0
0
1.000000
0
1
1
45
2000.000000
25
@@ -0,0 +1,21 @@
0.500000
0
0.000000
1.000000
30
0
0
1.000000
SDS.bmp
Brick1.bmp
-1
0
0
0
1.000000
0
1
1
10
2000.000000
25
@@ -0,0 +1,21 @@
0.025000
0
0.000000
2.000000
100
1
7
0.000000
SDS.bmp
Marble1.jpg
1
0
0
0
1.000000
0
1
1
15
150.000000
20
@@ -0,0 +1,21 @@
0.100000
0
0.000000
0.300000
0
0
0
1.000000
Wood1.bmp
RedTile.bmp
1
0
0
0
1.000000
0
1
1
0
0
25
@@ -0,0 +1,21 @@
0.060000
0
0.000000
1.000000
30
1
8
1.000000
RedTile.bmp
Marble1.jpg
1
255
0
0
-200.
0
1
1
0
200.000000
25
@@ -0,0 +1,21 @@
0.300000
0
0.000000
1.000000
30
0
0
1.000000
SDS.bmp
Brick1.bmp
-1
0
0
0
1.000000
0
1
1
10
2000.000000
25
@@ -0,0 +1,21 @@
0.045000
0
0.000000
1.500000
33
1
4
0.000000
SDS.bmp
Stone1.bmp
1
0
0
0
1.000000
65
1
1
10
0
25
@@ -0,0 +1,21 @@
1.000000
0
0.500000
1.500000
30
1
4
0.000000
SDS.bmp
Stone1.bmp
1
0
0
0
1.000000
65
1
1
40
2000.000000
15
Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 192 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 122 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 17 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 192 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 192 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 27 KiB

@@ -0,0 +1,502 @@
;
; BLOX&SPHERES V1.07 - Written for Blitz 3D.
; Written by Rob Hutchinson - loki.sd@cableinet.co.uk
;
; A VERY simple 3D (ha!), demo, hacked up from something I did a long time
; ago with the very first version of Blitz 3D Beta when all we had
; were cubes and spheres ;))
;
; Might turn this into something better later, though, will probably just
; work on something a little more fun, and well, better :)
;
; More comments later.
;
; SPACE - Switch camera to different (random) box.
; ESC - Exit.
;
; Ok here we have a lot of menu stuff.
Print "[Blox&Spheres V1.07]"
Print "Written by Rob Hutchinson 2000 - 2001"
; Non program Vars
Global Profiles$ = "Profiles\"
Global ScreenFile$ = "_ScreenMode.def"
Global DriverFile$ = "_Driver.def"
Global TexDir$ = "Textures\"
; Inital values
Global ZoomFactor# = 1 ;
Global ZoomPanning = 0 ;
Global ZoomPanSpd# = 0.5 ;
Global TopSpeed# = 1.5 ;
Global Brightness = 30 ;
Global Spheres = 1 ;
Global Segments = 4 ;
Global Shiny# = 0
Global EntityTex$ = "SDS.bmp"
Global OuterTex$ = "Stone1.bmp"
Global FogMode = 1
Global FogColourR = 0
Global FogColourG = 0
Global FogColourB = 0
Global FogRangeA# = 1
Global FogRangeB# = 2000
Global TextureFlags= 65
Global BAntiAlias = True
Global BDithering = True
Global bloxMin = 5
Global bloxMax = 5000
Global maxBlox = 40
Global BackSeg = 15
;Global BackTex$ = ""
Dim Files$(1000)
SaveProfile(Profiles$ + "_Default.pro")
; Ask the user some questions
If IAskQuestion("Profile","Do you want to use a preset profile?",1)
UserDefined = 0
; we are using a profile now
; get the user to pick one...
Print ""
useprofile$ = ListDir$(Profiles$,"")
If useprofile$ <> ""
; Load in the profile and lets rock....
LoadProfile Profiles$ + useprofile$
Else
; Terminate just in case
RuntimeError "Couldn't read profile, terminating."
End
EndIf
Else
UserDefined = 1
Print ""
PrintHeading "Attributes"
BAntialias = IAskQuestion("","Use AntiAlias?",1,0,0,0,0)
BDithering = IAskQuestion("","Use Dithering?",1,0,0,0,0)
maxBlox = IAskQuestion("","No. of objects (0=Single)?",0,500,0,20,0)
TopSpeed = FAskQuestion("","Object top speed?",10.0,0.001,1.5,0)
TextureFlags= IAskQuestion("","Texture Flags (65=EnvMap)?",0,1000,0,0,0)
UseSph = IAskQuestion("","Use spheres instead of cubes?",1,0,0,0,0)
If UseSph
Spheres = 1
Segments = IAskQuestion("","How many segments per sphere?",0,30,4,6,0)
Else
Spheres = 0
Segments = 0
EndIf
ZoomFactor = FAskQuestion("","Zoom Factor?",10,-10,1,0)
UsePan = IAskQuestion("","Do you want to use 'Zoom Panning'?",1,0,0,0,0)
If UsePan
ZoomPanning = 1
ZoomPanSpd = FAskQuestion("","Zoom panning speed?",50,-50,0.5,0)
Else
ZoomPanning = 0
ZoomPanSpd = 0
EndIf
UseFog = IAskQuestion("","Do you want to use fog?",1,0,0,0,0)
If UseFog
FogMode = 1
FogColourR = IAskQuestion("","Fog red value?",0,255,0,0,0)
FogColourG = IAskQuestion("","Fog green value?",0,255,0,0,0)
FogColourB = IAskQuestion("","Fog blue value?",0,255,0,0,0)
FogRangeA = FAskQuestion("","Fog near?",3000,-3000,2000,0)
FogRangeB = FAskQuestion("","Fog far?",3000,-3000,1,0)
Else
FogMode = -1
ZoomPanSpd = 0
EndIf
Brightness = IAskQuestion("","What brightness to use?",0,255,0,30,0)
Shiny# = FAskQuestion("","How much shine?",1.0,0,0,0)
BackSeg = IAskQuestion("","Big sphere segments?",0,30,6,25,0)
Dump$ = Input("Now pick a texture for the objects [ENTER]")
Print ""
EntityTex$ = ListDir$(TexDir$,"")
Dump$ = Input("Pick a texture for the outer sphere [ENTER]")
Print ""
OuterTex$ = ListDir$(TexDir$,"")
EndIf
;----------------------------------------------------------------------------------------------
If FileType(ScreenFile$) = 1
; Use default screen mode.
ndf = ReadFile(ScreenFile$)
If ndf
sm = ReadLine(ndf)
CloseFile ndf
Else
RuntimeError "Unable To Read ScreenFile, Please Delete it! (" + ScreenFile$ + ")"
End
EndIf
Else
Print ""
PrintHeading "ScreenMode"
For a=1 To CountGfxModes()
If GfxMode3D(a)
Print Str(a) + " " + Str(GfxModeWidth(a)) + "x" + Str(GfxModeHeight(a)) + "x" + Str(GfxModeDepth(a))
EndIf
Next
; Ok here we get some input from the user screenmode.
sm = 0
Repeat
sm=Input("Enter a screen mode from the list above: ")
Until sm > 0 And sm <= CountGfxModes()
If IAskQuestion("Default Screenmode","Do you want to always use this mode?",1)
ndf = WriteFile(ScreenFile$)
If ndf
WriteLine ndf,sm
CloseFile ndf
Else
RuntimeError "Couldn't write preferences, terminating."
EndIf
EndIf
EndIf
Print ""
Print ""
PrintHeading("Controls")
Print "SPACE - Switch to another (random) box."
Print "W - Toggle wireframe on/off."
Print "ESC - Quit the program."
Print ""
Dump$ = Input("[ENTER]")
;----------------------------------------------------------------------------------------------
; Setup the graphics..
Graphics3D GfxModeWidth(sm),GfxModeHeight(sm),GfxModeDepth(sm)
SetBuffer BackBuffer()
SeedRnd MilliSecs()
; Setup some stuff
AmbientLight Brightness,Brightness,Brightness
AntiAlias BAntiAlias
Dither BDithering
; Create the lights....
lightgreen=CreateLight()
LightColor lightgreen,10,255,10
TurnEntity lightgreen,90,0,0
lightblue=CreateLight()
LightColor lightblue,10,10,255
TurnEntity lightblue,180,0,0
lightlello=CreateLight()
LightColor lightlello,255,255,10
TurnEntity lightlello,0,0,90
lightred=CreateLight()
LightColor lightred,255,10,10
TurnEntity lightred,90,0,0
; number wrapping function
Function QWrap(Value#,Low#,High#) ; Remember this? where is the Blitz
Return Low#+(Value# Mod High#) ; PC version when you need it? :))
End Function
Type blok ; A block type for each block.
Field obj
Field posx#,posy#,posz#
Field rotx#,roty#,rotz#
Field radx#,rady#,radz#
Field spdx#,spdy#,spdz#
Field spnx#,spny#,spnz#
End Type
Dim blox.blok(maxBlox) ; Dimension an array of blocks.
; Create a pile of boxes/spheres.
Global bsh=CreateBrush()
BrushColor bsh,255,255,255
BrushTexture bsh,LoadTexture(TexDir$ + EntityTex$,TextureFlags)
BrushShininess bsh,Shiny
cratesize = 20
If Spheres = 0
crate = CreateCube()
Else
crate = CreateSphere(Segments)
EndIf
PaintEntity crate,bsh
HideEntity crate
FitMesh crate,-cratesize,-cratesize,-cratesize,cratesize*2,cratesize*2,cratesize*2
LightMesh crate,0,0,0,2,255,255,255
For a=0 To maxBlox ; Create a pile of boxes.
blox(a) = New blok
blox(a)\obj = CopyEntity(crate)
EntityAlpha blox(a)\obj,Rnd(0.2,1.0)
ShowEntity blox(a)\obj
blox(a)\rotx = Rnd(360)
blox(a)\roty = Rnd(360)
blox(a)\rotz = Rnd(360)
blox(a)\radx = Rnd(-500,500)
blox(a)\rady = Rnd(-500,500)
blox(a)\radz = Rnd(-500,500)
blox(a)\spdx = Rnd(-TopSpeed#,TopSpeed#)
blox(a)\spdy = Rnd(-TopSpeed#,TopSpeed#)
blox(a)\spdz = Rnd(-TopSpeed#,TopSpeed#)
blox(a)\spnx = Rnd(-TopSpeed#,TopSpeed#)
blox(a)\spny = Rnd(-TopSpeed#,TopSpeed#)
blox(a)\spnz = Rnd(-TopSpeed#,TopSpeed#)
Next
; Create a material for the brick wall
Global bsh2=CreateBrush()
tx = LoadTexture(TexDir$ + OuterTex$)
ScaleTexture tx,.1,.1
BrushTexture bsh2,tx
BrushShininess bsh2,1
BrushColor bsh2,100,100,100
backbox = CreateSphere(BackSeg)
PaintEntity backbox,bsh2
FitMesh backbox,0,0,0,1500,1500,1500
FlipMesh backbox
MoveEntity backbox,-750,-750,-750 ;move it into the screen a bit
camera=CreateCamera() ; A camera for the scene.
CameraViewport camera,0,0,GfxModeWidth(sm),GfxModeHeight(sm)
CameraRange camera,1,2000
CameraZoom camera,ZoomFactor#
If FogMode <> -1 Then CameraFogMode camera,FogMode
If FogColourR <> -1 CameraFogColor camera,FogColourR,FogColourG,FogColourB
If FogMode <> -1 Then CameraFogRange camera,FogRangeA,FogRangeB
deg# = 1
While Not KeyDown(1)
If KeyHit(17)
wire=Not wire
WireFrame wire
EndIf
Gosub UpdateAll
RenderWorld
Flip
Wend
EndGraphics
If UserDefined = 1
; Ask them if they want to save the profile......
UsePro = IAskQuestion("","Do you want to save your profile?",1)
If UsePro
Print "Please enter a descriptive name:"
savename$ = Input("> ")
SaveProfile(Profiles$ + savename$ + ".pro")
EndIf
EndIf
End
.UpdateAll
If ZoomPanning <> 0
deg# = deg# + ZoomPanSpd#
CameraZoom camera,Cos(deg#)
EndIf
If KeyHit(17)
wire=Not wire
WireFrame wire
EndIf
TurnEntity lightgreen,1,0,1
TurnEntity lightred,-1,0,-1
TurnEntity lightblue,1,0,0
TurnEntity lightlello,0,0,1
; Spin the objects inside the box.
For a=0 To maxBlox
TurnEntity blox(a)\obj,blox(a)\spnx,blox(a)\spny,blox(a)\spnz
blox(a)\posx=Sin(blox(a)\rotx)*blox(a)\radx
blox(a)\posy=Cos(blox(a)\roty)*blox(a)\rady
blox(a)\posz=Sin(blox(a)\rotz)*blox(a)\radz
blox(a)\rotx=blox(a)\rotx+blox(a)\spdx
blox(a)\roty=blox(a)\roty+blox(a)\spdy
blox(a)\rotz=blox(a)\rotz+blox(a)\spdz
blox(a)\rotx=QWrap(blox(a)\rotx,0,360)
blox(a)\roty=QWrap(blox(a)\roty,0,360)
blox(a)\rotz=QWrap(blox(a)\rotz,0,360)
PositionEntity blox(a)\obj,blox(a)\posx,blox(a)\posy,blox(a)\posz
Next
; Put the camera inside the selected box, so it sees everything the box would.
PositionEntity camera,blox(camerafrom)\posx,blox(camerafrom)\posy,blox(camerafrom)\posz
; Turn it the same way as the box.
TurnEntity camera,blox(camerafrom)\spnx,blox(camerafrom)\spny,blox(camerafrom)\spnz
; Switch camera to a different box when spacebar is hit.
If KeyHit(57)
camerafrom = Rnd(0,maxBlox)
EndIf
Return
Function FAskQuestion#(name$,question$,high#,low#,def#,prtblk=1)
If prtblk = 1 Then Print ""
PrintHeading name$
outi# = 0
Repeat
outi# = Input(question$ + " " + TrimFloat$(low#) + "-" + TrimFloat$(high#) + " [Def=" + TrimFloat$(Def#) + "]: ")
Until outi# >= low# And outi# <= high#
Return outi#
End Function
Function IAskQuestion(name$,question$,mode,high=0,low=0,def=0,prtblk=1)
If prtblk = 1 Then Print ""
PrintHeading name$
If mode = 1 ; yes/no
out$ = ""
Repeat
out$ = Input(question$ + " (Y/N): ")
Until Upper(out$) = "Y" Or Upper(out$) = "N"
If Upper(out$) = "Y"
Return True
Else
Return False
EndIf
Else ; other type
outi = 0
Repeat
outi = Input(question$ + " (" + low + "-" + high + ") [Def=" + def + "]: ")
Until outi >= low And outi <= high
Return outi
EndIf
End Function
Function PrintHeading(name$)
If name$ <> "" Then Print "-[" + name$ + "]" + String("-",50-(Len(name$)+3))
End Function
Function ListDir$(dir$,only$)
; Clear the file list.
For a = 0 To 999
Files$(a) = ""
Next
; Stop
; Populate it..
countfiles = -1
dirhandle = ReadDir(dir$)
outfile$ = ""
countpage = 0
If dirhandle
nxfile$ = NextFile$(dirhandle)
While nxfile$ <> ""
If nxfile$ <> ".." And nxfile$ <> "."
If only$ = ""
countfiles = countfiles + 1
Files$(countfiles) = nxfile$
Else
If Upper(Right$(nxfile$,Len(only$))) = Upper(only$)
countfiles = countfiles + 1
Files$(countfiles) = nxfile$
EndIf
EndIf
EndIf
nxfile$ = NextFile$(dirhandle)
Wend
For nxf = 0 To countfiles
; output the files.
countpage = countpage + 1
Print nxf + ". " + Files$(nxf)
If countpage = 22
dump$ = Input("[ENTER]")
countpage = 0
EndIf
Next
outfile$ = Files(IAskQuestion("","Please select a file",0,countfiles,0,0))
CloseDir dirhandle
EndIf
Return outfile$
End Function
Function SaveProfile(file$)
flh=WriteFile(file$)
If flh
; WriteLine flh,
WriteLine flh,ZoomFactor#
WriteLine flh,ZoomPanning
WriteLine flh,ZoomPanSpd#
WriteLine flh,TopSpeed#
WriteLine flh,Brightness
WriteLine flh,Spheres
WriteLine flh,Segments
WriteLine flh,Shiny
WriteLine flh,EntityTex$
WriteLine flh,OuterTex$
WriteLine flh,FogMode
WriteLine flh,FogColourR
WriteLine flh,FogColourG
WriteLine flh,FogColourB
WriteLine flh,FogRangeA
WriteLine flh,TextureFlags
WriteLine flh,BAntiAlias
WriteLine flh,BDithering
WriteLine flh,maxBlox
WriteLine flh,FogRangeB
WriteLine flh,BackSeg
CloseFile flh
EndIf
End Function
Function LoadProfile(file$)
flh=ReadFile(file$)
If flh
ZoomFactor# = ReadLine$(flh)
ZoomPanning = ReadLine$(flh)
ZoomPanSpd# = ReadLine$(flh)
TopSpeed# = ReadLine$(flh)
Brightness = ReadLine$(flh)
Spheres = ReadLine$(flh)
Segments = ReadLine$(flh)
Shiny = ReadLine$(flh)
EntityTex$ = ReadLine$(flh)
OuterTex$ = ReadLine$(flh)
FogMode = ReadLine$(flh)
FogColourR = ReadLine$(flh)
FogColourG = ReadLine$(flh)
FogColourB = ReadLine$(flh)
FogRangeA = ReadLine$(flh)
TextureFlags= ReadLine$(flh)
BAntiAlias = ReadLine$(flh)
BDithering = ReadLine$(flh)
maxBlox = ReadLine$(flh)
FogRangeB = ReadLine$(flh)
BackSeg = ReadLine$(flh)
CloseFile flh
EndIf
End Function
Function TrimFloat$(flt#,trimto = 3)
fltstr$ = flt#
decpnt = Instr(fltstr$,".")
dec$ = Mid$(fltstr$,decpnt+1)
start$ = Mid$(fltstr$,1,decpnt)
Return start$ + Left$(dec$,trimto)
End Function
File diff suppressed because it is too large Load Diff
Binary file not shown.

After

Width:  |  Height:  |  Size: 192 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 192 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 192 KiB

@@ -0,0 +1,132 @@
;
; Small SpaceCraft and flame. Code, Textures and Models By Rob Hutchinson.
; loki.sd@cableinet.co.uk
;
; CONTROLS:
; LMB + Up/Down = Zoom in/out
; Move Mouse = Rotate
;
; LAST UPDATED: 18/08/2001
;
Global obfile$ = "craft1.x"
; Sorry about this, switch screen mode if it doesn`t work..
; But this was only a small test.
Include "start.bb"
Global light=CreateLight()
LightColor light,130,130,130
TurnEntity light,45,45,0
Global camera=CreateCamera()
CameraViewport camera,0,0,1024,768
Global shippivot = CreatePivot()
Global shipobj = LoadMesh(obfile$,shippivot)
ScaleEntity shipobj,.3,.3,.3
Global flameobj1 = LoadSprite("Flame1.bmp",1,shippivot)
ScaleSprite flameobj1,2.5,2.5
MoveEntity flameobj1,0,0,-7
EntityAlpha flameobj1,.3
HideEntity flameobj1
Global flameobj2 = LoadSprite("Flame2.bmp",1,shippivot)
ScaleSprite flameobj2,2.5,2.5
MoveEntity flameobj2,0,0,-7
EntityAlpha flameobj2,.3
HideEntity flameobj2
;flameob2 = LoadSprite("Flame2.bmp")
Global pointflameent = CopyEntity(flameobj1,shippivot)
MoveEntity pointflameent,0,0,-50
HideEntity pointflameent
Type ship_flame
Field obj,speed#,count#,untildist#,prescale#,scaledown#,alphadown#,alphacn#
End Type
MoveEntity camera,0,0,-60
Global x_speed#,y_speed#,y_zoom#
Global k
Global newflameAfterFrames = 0
Global flameCountFrame = 0
While Not KeyHit(1)
If MouseDown(1)
y_zoom=(MouseYSpeed()-y_zoom)/13+y_zoom
x_speed=(0-x_speed)/13+x_speed
y_speed=(0-y_speed)/13+y_speed
Else
x_speed=(MouseXSpeed()-x_speed)/13+x_speed
y_speed=(MouseYSpeed()-y_speed)/13+y_speed
y_zoom=(0-y_zoom)/13+y_zoom
EndIf
TurnEntity shippivot,0,-x_speed,0
TurnEntity shippivot,-y_speed,0,0
MoveEntity camera,0,0,y_zoom
MoveMouse GraphicsWidth()/2,GraphicsHeight()/2
DoFlame()
flameCountFrame = flameCountFrame + 1
If flameCountFrame > newflameAfterFrames
j = Rnd(100)
If j > 50
CreateNewFlame(flameobj1,0.8,20,6)
Else
CreateNewFlame(flameobj2,0.8,20,6)
EndIf
flameCountFrame = 0
EndIf
UpdateWorld
RenderWorld
Text 0,0,"Craft Flare: [By Rob Hutchinson 2001]"
k = 0
Flip
Wend
End
Function CreateNewFlame(object,speed#,untildist#,scale#)
n.ship_flame = New ship_flame
n\obj = CopyEntity(object)
RotateEntity n\obj,Rnd(0,360),Rnd(0,360),Rnd(0,360)
PointEntity n\obj,pointflameent
MoveEntity n\obj,0,0,7
rn1# = Rnd(-.5,.5)
rn2# = Rnd(-.5,.5)
MoveEntity n\obj,rn1,rn2,0
ShowEntity n\obj
If scale <> 1 Then ScaleSprite n\obj,scale,scale
n\speed = speed
n\untildist = untildist
n\prescale = (n\speed / n\untildist)
n\scaledown = scale
n\alphacn = 1.0 / (n\untildist / n\speed)
n\alphadown = 1
End Function
Function DoFlame()
For n.ship_flame = Each ship_flame
MoveEntity n\obj,0,0,n\speed
n\scaledown = n\scaledown - (n\prescale*4)
ScaleSprite n\obj,n\scaledown#,n\scaledown#
n\alphadown = n\alphadown - n\alphacn
EntityAlpha n\obj,n\alphadown
n\count = n\count + n\speed
If n\count > n\untildist
FreeEntity n\obj
Delete n
EndIf
k = k + 1
Next
End Function
@@ -0,0 +1,5 @@
CRAFT FLARE
-----------
By Rob Hutchinson 2001
Simple space craft flame effect.
Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 48 KiB

@@ -0,0 +1,125 @@
;Logo()
SetGfx()
Type GfxMode
Field width,height,depth
End Type
Function Logo()
Graphics3D 640,480
SetBuffer BackBuffer()
image=LoadImage( "b3dlogo.jpg" )
If image=0 image=LoadImage( "../b3dlogo.jpg" )
MidHandle image
Color 255,0,0
SetFont LoadFont( "helvetica",16 )
t=MilliSecs()
txt1$="(C)opyright Blitz Research Limited"
txt2$="Published by Guildhall Leisure Services"
txt3$="Find out more at www.blitz-3d.com"
yy=320
Repeat
Cls
DrawBlock image,320,yy-120
Color 0,0,192
Text 0,480-FontHeight()*2,txt1$
Text 0,480-FontHeight()*1,txt2$
Color 0,255,0
Text 640-StringWidth(txt3$),480-FontHeight()*1,txt3$
Color 255,0,0
Text 320,yy+FontHeight()*0,info1$,True,True
Text 320,yy+FontHeight()*1,info2$,True,True
Text 320,yy+FontHeight()*2,info3$,True,True
Text 320,yy+FontHeight()*3,info4$,True,True
d=MilliSecs()-t
If d>5000
If tick=0
tick=127
FlushKeys
Else
tick=tick-1
If tick=0 tick=127
EndIf
If tick And 64
Color 255,255,255
Text 320,yy+FontHeight()*5,"Press any key",True,True
EndIf
If GetKey() Then Exit
EndIf
Flip
Forever
For k=1 To 2
Cls:Flip
Next
FreeImage image
FlushKeys
End Function
Function SetGfx()
Print info1$:Print info2$:Print info3$:Print info4$:Print
If Windowed3D()
yn$=Input$( "Use windowed mode?" )
If Left$( Lower$( yn$ ),1 )="y"
HidePointer
Graphics3D 640,480,0,2
SetBuffer BackBuffer()
Return
EndIf
EndIf
Print ""
Print "Display drivers:"
Print "----------------"
For k=1 To CountGfxDrivers()
Print k+":"+GfxDriverName$(k)
Next
Print ""
If CountGfxDrivers()>1
Repeat
driver=Input$( "Display driver (1-"+CountGfxDrivers()+"):" )
Until driver>=1 And driver<=CountGfxDrivers()
SetGfxDriver driver
EndIf
Print ""
Print "Display modes:"
Print "--------------"
cnt=0
For k=1 To CountGfxModes()
If GfxMode3D(k)
t.GfxMode=New GfxMode
t\width=GfxModeWidth(k)
t\height=GfxModeHeight(k)
t\depth=GfxModeDepth(k)
cnt=cnt+1
Print cnt+":"+t\width+","+t\height+","+t\depth
EndIf
Next
If Not cnt
Print "No 3D Graphics modes available!"
Print "Press any key..."
WaitKey
End
EndIf
Repeat
mode=Input$( "Display Mode (1-"+cnt+"):" )
Until mode>=1 And mode<=cnt
t.GfxMode=First GfxMode
While mode>1
t=After t
mode=mode-1
Wend
Graphics3D t\width,t\height,t\depth,1
SetBuffer BackBuffer()
Delete Each GfxMode
End Function
@@ -0,0 +1,960 @@
xof 0302txt 0032
Header {
1;
0;
1;
}
template Header {
<3D82AB43-62DA-11cf-AB39-0020AF71E433>
WORD major;
WORD minor;
DWORD flags;
}
template Vector {
<3D82AB5E-62DA-11cf-AB39-0020AF71E433>
FLOAT x;
FLOAT y;
FLOAT z;
}
template Coords2d {
<F6F23F44-7686-11cf-8F52-0040333594A3>
FLOAT u;
FLOAT v;
}
template Matrix4x4 {
<F6F23F45-7686-11cf-8F52-0040333594A3>
array FLOAT matrix[16];
}
template ColorRGBA {
<35FF44E0-6C7C-11cf-8F52-0040333594A3>
FLOAT red;
FLOAT green;
FLOAT blue;
FLOAT alpha;
}
template ColorRGB {
<D3E16E81-7835-11cf-8F52-0040333594A3>
FLOAT red;
FLOAT green;
FLOAT blue;
}
template TextureFilename {
<A42790E1-7810-11cf-8F52-0040333594A3>
STRING filename;
}
template Material {
<3D82AB4D-62DA-11cf-AB39-0020AF71E433>
ColorRGBA faceColor;
FLOAT power;
ColorRGB specularColor;
ColorRGB emissiveColor;
[...]
}
template MeshFace {
<3D82AB5F-62DA-11cf-AB39-0020AF71E433>
DWORD nFaceVertexIndices;
array DWORD faceVertexIndices[nFaceVertexIndices];
}
template MeshTextureCoords {
<F6F23F40-7686-11cf-8F52-0040333594A3>
DWORD nTextureCoords;
array Coords2d textureCoords[nTextureCoords];
}
template MeshMaterialList {
<F6F23F42-7686-11cf-8F52-0040333594A3>
DWORD nMaterials;
DWORD nFaceIndexes;
array DWORD faceIndexes[nFaceIndexes];
[Material]
}
template MeshNormals {
<F6F23F43-7686-11cf-8F52-0040333594A3>
DWORD nNormals;
array Vector normals[nNormals];
DWORD nFaceNormals;
array MeshFace faceNormals[nFaceNormals];
}
template Mesh {
<3D82AB44-62DA-11cf-AB39-0020AF71E433>
DWORD nVertices;
array Vector vertices[nVertices];
DWORD nFaces;
array MeshFace faces[nFaces];
[...]
}
template FrameTransformMatrix {
<F6F23F41-7686-11cf-8F52-0040333594A3>
Matrix4x4 frameMatrix;
}
template Frame {
<3D82AB46-62DA-11cf-AB39-0020AF71E433>
[...]
}
template FloatKeys {
<10DD46A9-775B-11cf-8F52-0040333594A3>
DWORD nValues;
array FLOAT values[nValues];
}
template TimedFloatKeys {
<F406B180-7B3B-11cf-8F52-0040333594A3>
DWORD time;
FloatKeys tfkeys;
}
template AnimationKey {
<10DD46A8-775B-11cf-8F52-0040333594A3>
DWORD keyType;
DWORD nKeys;
array TimedFloatKeys keys[nKeys];
}
template AnimationOptions {
<E2BF56C0-840F-11cf-8F52-0040333594A3>
DWORD openclosed;
DWORD positionquality;
}
template Animation {
<3D82AB4F-62DA-11cf-AB39-0020AF71E433>
[...]
}
template AnimationSet {
<3D82AB50-62DA-11cf-AB39-0020AF71E433>
[Animation]
}
Frame Frm {
FrameTransformMatrix {
1.000000,0.000000,0.000000,0.000000,
0.000000,1.000000,0.000000,0.000000,
0.000000,0.000000,1.000000,0.000000,
0.000000,0.000000,0.000000,1.000000;;
}
Mesh object {
4;
20.250000;30.750000;-7.000000;,
-34.750000;30.750000;-7.000000;,
-34.750000;-20.250000;-7.000000;,
20.250000;-20.250000;-7.000000;;
2;
3;0,1,2;,
3;3,0,2;;
MeshMaterialList {
1;
2;
0,
0;;
Material {
0.800000;0.800000;0.800000;1.000000;;
2.000000;
0.000000;0.000000;0.000000;;
0.040000;0.040000;0.040000;;
TextureFilename {
"facia_0.bmp";
}
}
}
MeshNormals {
4;
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;;
2;
3;0,1,2;,
3;3,0,2;;
}
MeshTextureCoords {
4;
2.560683;0.711789;,
0.598332;0.711789;,
0.598332;2.299513;,
2.560683;2.299513;;
}
}
}
Frame backplate {
FrameTransformMatrix {
1.000000,0.000000,0.000000,0.000000,
0.000000,1.000000,0.000000,0.000000,
0.000000,0.000000,1.000000,0.000000,
0.000000,0.000000,0.000000,1.000000;;
}
Mesh backplate1 {
6;
-4.621520;6.674383;5.200000;,
-10.308411;6.698773;5.200000;,
-10.308411;0.856122;5.200000;,
-4.621520;6.674383;5.200000;,
-10.308411;0.856122;5.200000;,
-4.621413;0.848771;5.200000;;
2;
3;0,1,2;,
3;3,4,5;;
MeshMaterialList {
1;
2;
0,
0;;
Material {
0.800000;0.800000;0.800000;1.000000;;
2.000000;
0.000000;0.000000;0.000000;;
0.040000;0.040000;0.040000;;
TextureFilename {
"facia_1.bmp";
}
}
}
MeshNormals {
6;
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;;
2;
3;0,1,2;,
3;3,4,5;;
}
MeshTextureCoords {
6;
0.999981;1.004169;,
0.000000;1.000000;,
0.000000;1.998743;,
0.999981;0.004169;,
0.000000;0.998743;,
1.000000;1.000000;;
}
}
}
Frame flare {
FrameTransformMatrix {
1.000000,0.000000,0.000000,0.000000,
0.000000,1.000000,0.000000,0.000000,
0.000000,0.000000,1.000000,0.000000,
0.000000,0.000000,0.000000,1.000000;;
}
Mesh flare1 {
6;
-4.621520;6.674383;4.400000;,
-10.308411;6.698773;4.400000;,
-10.308411;0.856122;4.400000;,
-4.621520;6.674383;4.400000;,
-10.308411;0.856122;4.400000;,
-4.621413;0.848771;4.400000;;
2;
3;0,1,2;,
3;3,4,5;;
MeshMaterialList {
1;
2;
0,
0;;
Material {
0.800000;0.800000;0.800000;1.000000;;
2.000000;
0.000000;0.000000;0.000000;;
0.040000;0.040000;0.040000;;
TextureFilename {
"facia_1.bmp";
}
}
}
MeshNormals {
6;
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;;
2;
3;0,1,2;,
3;3,4,5;;
}
MeshTextureCoords {
6;
0.999981;1.004169;,
0.000000;1.000000;,
0.000000;1.998743;,
0.999981;0.004169;,
0.000000;0.998743;,
1.000000;1.000000;;
}
}
}
Frame Duplicate01 {
FrameTransformMatrix {
1.000000,0.000000,0.000000,0.000000,
0.000000,1.000000,0.000000,0.000000,
0.000000,0.000000,1.000000,0.000000,
0.000000,0.000000,0.000000,1.000000;;
}
Mesh Duplicate011 {
6;
-4.621520;6.674383;3.400000;,
-10.308411;6.698773;3.400000;,
-10.308411;0.856122;3.400000;,
-4.621520;6.674383;3.400000;,
-10.308411;0.856122;3.400000;,
-4.621413;0.848771;3.400000;;
2;
3;0,1,2;,
3;3,4,5;;
MeshMaterialList {
1;
2;
0,
0;;
Material {
0.800000;0.800000;0.800000;1.000000;;
2.000000;
0.000000;0.000000;0.000000;;
0.040000;0.040000;0.040000;;
TextureFilename {
"facia_1.bmp";
}
}
}
MeshNormals {
6;
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;;
2;
3;0,1,2;,
3;3,4,5;;
}
MeshTextureCoords {
6;
0.999981;1.004169;,
0.000000;1.000000;,
0.000000;1.998743;,
0.999981;0.004169;,
0.000000;0.998743;,
1.000000;1.000000;;
}
}
}
Frame Duplicate02 {
FrameTransformMatrix {
1.000000,0.000000,0.000000,0.000000,
0.000000,1.000000,0.000000,0.000000,
0.000000,0.000000,1.000000,0.000000,
0.000000,0.000000,0.000000,1.000000;;
}
Mesh Duplicate021 {
6;
-4.621520;6.674383;2.600000;,
-10.308411;6.698773;2.600000;,
-10.308411;0.856122;2.600000;,
-4.621520;6.674383;2.600000;,
-10.308411;0.856122;2.600000;,
-4.621413;0.848771;2.600000;;
2;
3;0,1,2;,
3;3,4,5;;
MeshMaterialList {
1;
2;
0,
0;;
Material {
0.800000;0.800000;0.800000;1.000000;;
2.000000;
0.000000;0.000000;0.000000;;
0.040000;0.040000;0.040000;;
TextureFilename {
"facia_1.bmp";
}
}
}
MeshNormals {
6;
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;;
2;
3;0,1,2;,
3;3,4,5;;
}
MeshTextureCoords {
6;
0.999981;1.004169;,
0.000000;1.000000;,
0.000000;1.998743;,
0.999981;0.004169;,
0.000000;0.998743;,
1.000000;1.000000;;
}
}
}
Frame Duplicate03 {
FrameTransformMatrix {
1.000000,0.000000,0.000000,0.000000,
0.000000,1.000000,0.000000,0.000000,
0.000000,0.000000,1.000000,0.000000,
0.000000,0.000000,0.000000,1.000000;;
}
Mesh Duplicate031 {
6;
-4.621520;6.674383;1.800000;,
-10.308411;6.698773;1.800000;,
-10.308411;0.856122;1.800000;,
-4.621520;6.674383;1.800000;,
-10.308411;0.856122;1.800000;,
-4.621413;0.848771;1.800000;;
2;
3;0,1,2;,
3;3,4,5;;
MeshMaterialList {
1;
2;
0,
0;;
Material {
0.800000;0.800000;0.800000;1.000000;;
2.000000;
0.000000;0.000000;0.000000;;
0.040000;0.040000;0.040000;;
TextureFilename {
"facia_1.bmp";
}
}
}
MeshNormals {
6;
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;;
2;
3;0,1,2;,
3;3,4,5;;
}
MeshTextureCoords {
6;
0.999981;1.004169;,
0.000000;1.000000;,
0.000000;1.998743;,
0.999981;0.004169;,
0.000000;0.998743;,
1.000000;1.000000;;
}
}
}
Frame Duplicate04 {
FrameTransformMatrix {
1.000000,0.000000,0.000000,0.000000,
0.000000,1.000000,0.000000,0.000000,
0.000000,0.000000,1.000000,0.000000,
0.000000,0.000000,0.000000,1.000000;;
}
Mesh Duplicate041 {
6;
-4.621520;6.674383;1.000000;,
-10.308411;6.698773;1.000000;,
-10.308411;0.856122;1.000000;,
-4.621520;6.674383;1.000000;,
-10.308411;0.856122;1.000000;,
-4.621413;0.848771;1.000000;;
2;
3;0,1,2;,
3;3,4,5;;
MeshMaterialList {
1;
2;
0,
0;;
Material {
0.800000;0.800000;0.800000;1.000000;;
2.000000;
0.000000;0.000000;0.000000;;
0.040000;0.040000;0.040000;;
TextureFilename {
"facia_1.bmp";
}
}
}
MeshNormals {
6;
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;;
2;
3;0,1,2;,
3;3,4,5;;
}
MeshTextureCoords {
6;
0.999981;1.004169;,
0.000000;1.000000;,
0.000000;1.998743;,
0.999981;0.004169;,
0.000000;0.998743;,
1.000000;1.000000;;
}
}
}
Frame Duplicate05 {
FrameTransformMatrix {
1.000000,0.000000,0.000000,0.000000,
0.000000,1.000000,0.000000,0.000000,
0.000000,0.000000,1.000000,0.000000,
0.000000,0.000000,0.000000,1.000000;;
}
Mesh Duplicate051 {
6;
-4.621520;6.674383;0.200000;,
-10.308411;6.698773;0.200000;,
-10.308411;0.856122;0.200000;,
-4.621520;6.674383;0.200000;,
-10.308411;0.856122;0.200000;,
-4.621413;0.848771;0.200000;;
2;
3;0,1,2;,
3;3,4,5;;
MeshMaterialList {
1;
2;
0,
0;;
Material {
0.800000;0.800000;0.800000;1.000000;;
2.000000;
0.000000;0.000000;0.000000;;
0.040000;0.040000;0.040000;;
TextureFilename {
"facia_1.bmp";
}
}
}
MeshNormals {
6;
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;;
2;
3;0,1,2;,
3;3,4,5;;
}
MeshTextureCoords {
6;
0.999981;1.004169;,
0.000000;1.000000;,
0.000000;1.998743;,
0.999981;0.004169;,
0.000000;0.998743;,
1.000000;1.000000;;
}
}
}
Frame Duplicate06 {
FrameTransformMatrix {
1.000000,0.000000,0.000000,0.000000,
0.000000,1.000000,0.000000,0.000000,
0.000000,0.000000,1.000000,0.000000,
0.000000,0.000000,0.000000,1.000000;;
}
Mesh Duplicate061 {
6;
-4.621520;6.674383;-0.600000;,
-10.308411;6.698773;-0.600000;,
-10.308411;0.856122;-0.600000;,
-4.621520;6.674383;-0.600000;,
-10.308411;0.856122;-0.600000;,
-4.621413;0.848771;-0.600000;;
2;
3;0,1,2;,
3;3,4,5;;
MeshMaterialList {
1;
2;
0,
0;;
Material {
0.800000;0.800000;0.800000;1.000000;;
2.000000;
0.000000;0.000000;0.000000;;
0.040000;0.040000;0.040000;;
TextureFilename {
"facia_1.bmp";
}
}
}
MeshNormals {
6;
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;;
2;
3;0,1,2;,
3;3,4,5;;
}
MeshTextureCoords {
6;
0.999981;1.004169;,
0.000000;1.000000;,
0.000000;1.998743;,
0.999981;0.004169;,
0.000000;0.998743;,
1.000000;1.000000;;
}
}
}
Frame Duplicate07 {
FrameTransformMatrix {
1.000000,0.000000,0.000000,0.000000,
0.000000,1.000000,0.000000,0.000000,
0.000000,0.000000,1.000000,0.000000,
0.000000,0.000000,0.000000,1.000000;;
}
Mesh Duplicate071 {
6;
-4.621520;6.674383;-1.400000;,
-10.308411;6.698773;-1.400000;,
-10.308411;0.856122;-1.400000;,
-4.621520;6.674383;-1.400000;,
-10.308411;0.856122;-1.400000;,
-4.621413;0.848771;-1.400000;;
2;
3;0,1,2;,
3;3,4,5;;
MeshMaterialList {
1;
2;
0,
0;;
Material {
0.800000;0.800000;0.800000;1.000000;;
2.000000;
0.000000;0.000000;0.000000;;
0.040000;0.040000;0.040000;;
TextureFilename {
"facia_1.bmp";
}
}
}
MeshNormals {
6;
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;;
2;
3;0,1,2;,
3;3,4,5;;
}
MeshTextureCoords {
6;
0.999981;1.004169;,
0.000000;1.000000;,
0.000000;1.998743;,
0.999981;0.004169;,
0.000000;0.998743;,
1.000000;1.000000;;
}
}
}
Frame Duplicate08 {
FrameTransformMatrix {
1.000000,0.000000,0.000000,0.000000,
0.000000,1.000000,0.000000,0.000000,
0.000000,0.000000,1.000000,0.000000,
0.000000,0.000000,0.000000,1.000000;;
}
Mesh Duplicate081 {
6;
-4.621520;6.674383;-2.000000;,
-10.308411;6.698773;-2.000000;,
-10.308411;0.856122;-2.000000;,
-4.621520;6.674383;-2.000000;,
-10.308411;0.856122;-2.000000;,
-4.621413;0.848771;-2.000000;;
2;
3;0,1,2;,
3;3,4,5;;
MeshMaterialList {
1;
2;
0,
0;;
Material {
0.800000;0.800000;0.800000;1.000000;;
2.000000;
0.000000;0.000000;0.000000;;
0.040000;0.040000;0.040000;;
TextureFilename {
"facia_1.bmp";
}
}
}
MeshNormals {
6;
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;;
2;
3;0,1,2;,
3;3,4,5;;
}
MeshTextureCoords {
6;
0.999981;1.004169;,
0.000000;1.000000;,
0.000000;1.998743;,
0.999981;0.004169;,
0.000000;0.998743;,
1.000000;1.000000;;
}
}
}
Frame Duplicate09 {
FrameTransformMatrix {
1.000000,0.000000,0.000000,0.000000,
0.000000,1.000000,0.000000,0.000000,
0.000000,0.000000,1.000000,0.000000,
0.000000,0.000000,0.000000,1.000000;;
}
Mesh Duplicate091 {
6;
-4.621520;6.674383;-2.800000;,
-10.308411;6.698773;-2.800000;,
-10.308411;0.856122;-2.800000;,
-4.621520;6.674383;-2.800000;,
-10.308411;0.856122;-2.800000;,
-4.621413;0.848771;-2.800000;;
2;
3;0,1,2;,
3;3,4,5;;
MeshMaterialList {
1;
2;
0,
0;;
Material {
0.800000;0.800000;0.800000;1.000000;;
2.000000;
0.000000;0.000000;0.000000;;
0.040000;0.040000;0.040000;;
TextureFilename {
"facia_1.bmp";
}
}
}
MeshNormals {
6;
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;;
2;
3;0,1,2;,
3;3,4,5;;
}
MeshTextureCoords {
6;
0.999981;1.004169;,
0.000000;1.000000;,
0.000000;1.998743;,
0.999981;0.004169;,
0.000000;0.998743;,
1.000000;1.000000;;
}
}
}
Frame Duplicate11 {
FrameTransformMatrix {
1.000000,0.000000,0.000000,0.000000,
0.000000,1.000000,0.000000,0.000000,
0.000000,0.000000,1.000000,0.000000,
0.000000,0.000000,0.000000,1.000000;;
}
Mesh Duplicate111 {
6;
-4.621520;6.674383;-3.600000;,
-10.308411;6.698773;-3.600000;,
-10.308411;0.856122;-3.600000;,
-4.621520;6.674383;-3.600000;,
-10.308411;0.856122;-3.600000;,
-4.621413;0.848771;-3.600000;;
2;
3;0,1,2;,
3;3,4,5;;
MeshMaterialList {
1;
2;
0,
0;;
Material {
0.800000;0.800000;0.800000;1.000000;;
2.000000;
0.000000;0.000000;0.000000;;
0.040000;0.040000;0.040000;;
TextureFilename {
"facia_1.bmp";
}
}
}
MeshNormals {
6;
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;;
2;
3;0,1,2;,
3;3,4,5;;
}
MeshTextureCoords {
6;
0.999981;1.004169;,
0.000000;1.000000;,
0.000000;1.998743;,
0.999981;0.004169;,
0.000000;0.998743;,
1.000000;1.000000;;
}
}
}
Frame Duplicate12 {
FrameTransformMatrix {
1.000000,0.000000,0.000000,0.000000,
0.000000,1.000000,0.000000,0.000000,
0.000000,0.000000,1.000000,0.000000,
0.000000,0.000000,0.000000,1.000000;;
}
Mesh Duplicate121 {
6;
-4.621520;6.674383;-4.400000;,
-10.308411;6.698773;-4.400000;,
-10.308411;0.856122;-4.400000;,
-4.621520;6.674383;-4.400000;,
-10.308411;0.856122;-4.400000;,
-4.621413;0.848771;-4.400000;;
2;
3;0,1,2;,
3;3,4,5;;
MeshMaterialList {
1;
2;
0,
0;;
Material {
0.800000;0.800000;0.800000;1.000000;;
2.000000;
0.000000;0.000000;0.000000;;
0.040000;0.040000;0.040000;;
TextureFilename {
"facia_1.bmp";
}
}
}
MeshNormals {
6;
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;,
0.000000;0.000000;1.000000;;
2;
3;0,1,2;,
3;3,4,5;;
}
MeshTextureCoords {
6;
0.999981;1.004169;,
0.000000;1.000000;,
0.000000;1.998743;,
0.999981;0.004169;,
0.000000;0.998743;,
1.000000;1.000000;;
}
}
}
Binary file not shown.

After

Width:  |  Height:  |  Size: 192 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 48 KiB

@@ -0,0 +1,101 @@
;
; MODEL CHILDREN V1.00
; --------------------
; Simple example of how to play around with a model's children objects.
; Here, the flares and backplate are part of the "Models\facia.x" model.
; The example gets entities from each of the child flare subobjects in
; the facia model and moves them around on the X and Y axis. Simple.
;
; Email: loki.sd@cableinet.co.uk / ICQ: 27181384
;
; Created with BB3D Beta 1.60
; Last Modified: 13/08/2001
;
AppTitle "Model Children V1.00 - By Rob Hutchinson 2001"
; Randomize from the timer.
SeedRnd MilliSecs()
; Setup the screen
Include "start.bb"
; Setup the camera
camera = CreateCamera()
; Load in our model
mainmesh = LoadAnimMesh("models\facia.x")
MoveEntity mainmesh,7,3,20
TurnEntity mainmesh,180,0,0
; Some ambient lighting
AmbientLight 200,200,200
; Flies:
Type fly
Field obj
Field posx#,posy#
Field rotx#,roty#
Field radx#,rady#
Field spdx#,spdy#
End Type
; Count the number of children in the model. We already know
; that child 1 is the backface, so we use all other objects (the flares).
Global maxFlies = CountChildren(mainmesh)-1
Global TopSpeed# = 2.5
Dim flies.fly(maxFlies+1)
For a=0 To CountChildren(mainmesh)-2
flies(a) = New fly
; Get a handle to the child object.
flies(a)\obj = GetChild(mainmesh,a+2)
; Addition blend the object so it appears as a light rather than a brick.
EntityBlend flies(a)\obj,3
; Randomize some movement values.
flies(a)\rotx = Rnd(360)
flies(a)\roty = Rnd(360)
flies(a)\radx = Rnd(-15,15)
flies(a)\rady = Rnd(-15,15)
flies(a)\spdx = Rnd(-TopSpeed#,TopSpeed#)
flies(a)\spdy = Rnd(-TopSpeed#,TopSpeed#)
Next
Repeat
; Allow the user to switch to wireframe mode.
If KeyHit(17) Then wire = Not wire
WireFrame wire
; Move them all!
For a=0 To CountChildren(mainmesh)-2
flies(a)\posx=Sin(flies(a)\rotx)*flies(a)\radx
flies(a)\posy=Cos(flies(a)\roty)*flies(a)\rady
flies(a)\rotx=flies(a)\rotx+flies(a)\spdx
flies(a)\roty=flies(a)\roty+flies(a)\spdy
flies(a)\rotx=QWrap(flies(a)\rotx,0,360)
flies(a)\roty=QWrap(flies(a)\roty,0,360)
PositionEntity flies(a)\obj,flies(a)\posx,flies(a)\posy,EntityZ(flies(a)\obj)
Next
; Update the world stuff
UpdateWorld
RenderWorld
; Flip display
Flip
Until KeyDown(1)
; Terminate.
End
Function CurveValue#(current#,destination#,curve)
current#=current#+((destination#-current#)/curve)
Return current#
End Function
Function QWrap(Value#,Low#,High#) ; Remember this? where is the Blitz
Return Low#+(Value# Mod High#) ; PC version when you need it? :))
End Function
@@ -0,0 +1,125 @@
;Logo()
SetGfx()
Type GfxMode
Field width,height,depth
End Type
Function Logo()
Graphics3D 640,480
SetBuffer BackBuffer()
image=LoadImage( "b3dlogo.jpg" )
If image=0 image=LoadImage( "../b3dlogo.jpg" )
MidHandle image
Color 255,0,0
SetFont LoadFont( "helvetica",16 )
t=MilliSecs()
txt1$="(C)opyright Blitz Research Limited"
txt2$="Published by Guildhall Leisure Services"
txt3$="Find out more at www.blitz-3d.com"
yy=320
Repeat
Cls
DrawBlock image,320,yy-120
Color 0,0,192
Text 0,480-FontHeight()*2,txt1$
Text 0,480-FontHeight()*1,txt2$
Color 0,255,0
Text 640-StringWidth(txt3$),480-FontHeight()*1,txt3$
Color 255,0,0
Text 320,yy+FontHeight()*0,info1$,True,True
Text 320,yy+FontHeight()*1,info2$,True,True
Text 320,yy+FontHeight()*2,info3$,True,True
Text 320,yy+FontHeight()*3,info4$,True,True
d=MilliSecs()-t
If d>5000
If tick=0
tick=127
FlushKeys
Else
tick=tick-1
If tick=0 tick=127
EndIf
If tick And 64
Color 255,255,255
Text 320,yy+FontHeight()*5,"Press any key",True,True
EndIf
If GetKey() Then Exit
EndIf
Flip
Forever
For k=1 To 2
Cls:Flip
Next
FreeImage image
FlushKeys
End Function
Function SetGfx()
Print info1$:Print info2$:Print info3$:Print info4$:Print
If Windowed3D()
yn$=Input$( "Use windowed mode?" )
If Left$( Lower$( yn$ ),1 )="y"
HidePointer
Graphics3D 640,480,0,2
SetBuffer BackBuffer()
Return
EndIf
EndIf
Print ""
Print "Display drivers:"
Print "----------------"
For k=1 To CountGfxDrivers()
Print k+":"+GfxDriverName$(k)
Next
Print ""
If CountGfxDrivers()>1
Repeat
driver=Input$( "Display driver (1-"+CountGfxDrivers()+"):" )
Until driver>=1 And driver<=CountGfxDrivers()
SetGfxDriver driver
EndIf
Print ""
Print "Display modes:"
Print "--------------"
cnt=0
For k=1 To CountGfxModes()
If GfxMode3D(k)
t.GfxMode=New GfxMode
t\width=GfxModeWidth(k)
t\height=GfxModeHeight(k)
t\depth=GfxModeDepth(k)
cnt=cnt+1
Print cnt+":"+t\width+","+t\height+","+t\depth
EndIf
Next
If Not cnt
Print "No 3D Graphics modes available!"
Print "Press any key..."
WaitKey
End
EndIf
Repeat
mode=Input$( "Display Mode (1-"+cnt+"):" )
Until mode>=1 And mode<=cnt
t.GfxMode=First GfxMode
While mode>1
t=After t
mode=mode-1
Wend
Graphics3D t\width,t\height,t\depth,1
SetBuffer BackBuffer()
Delete Each GfxMode
End Function
@@ -0,0 +1,46 @@
SKY PLATEAU V1.01
-----------------
Author: Rob Hutchinson
Email: loki.sd@cableinet.co.uk
WWW: http://www.blitzbasic.com/
Blitz3D Demonstration.
Inspired by Unreal :)
This program was written in the space of about 5
days or so (including all models, textures (a few
borrowed from other B3D examples),
sounds, and BBLauncher(vb)), with Blitz Basic
Beta V1.60.
So what features does it show off?
- Spherical Environment Mapping.
- Alpha Blending.
- Fogging.
- Ping-Pong Mesh Deformation Animations.
- Unlimited Length Planes.
- Directional/Point Lighting.
- Light Ranging.
- Sprites.
- X/MD2 Loader.
- Tonnes of Pivoting..
- But most importantly, how fast Blitz3D is!
What are the controls?
Its a rolling (spinning :)) demo, so theres not
much interaction, but you can navigate the menu
with the up and down arrow keys, select a menu
option with the enter key. And quick-exit with
the escape key. Mouselook option allows you to
look around with the mouse, and the Pause Rot
option allows to you pause the rotation so you
can look around without spinning.
Have fun watching it!
--
Rob Hutchinson - loki.sd@cableinet.co.uk
Binary file not shown.

After

Width:  |  Height:  |  Size: 48 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 192 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 48 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 48 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 192 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 192 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 24 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 96 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 19 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 192 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 192 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 192 KiB

@@ -0,0 +1,51 @@
;
; BBLAUNCHER V1.00 MAIN INIT FILE
; -------------------------------
;
; Feel Free To use BBLauncher With your own Programs!
; Dont Forget it requires VB, you can actually just whack the
; VM Runtimes in the same dir if you like.
; --
; Rob Hutchinson - 12/08/2001
;
[Details]
Program Name = Sky Plateau
Build = #0034
Version = 1.01
Author = Rob Hutchinson
Email = loki.sd@cableinet.co.uk
Title = Sky Plateau V1.01 - Launcher
Frame = Sky Plateau Pre-Launch Options:
About = About.TXT
Executable = SkyPlateau.EXE
Icon = Icon.ico
Banner Colour = &H00000080
Additional Option Name = Unreal lighting effects (Slower)?
[Resolutions]
Res[0] = 640x480
Res[1] = 320x200
Res[2] = 320x240
Res[3] = 400x300
Res[4] = 720x480
Res[5] = 720x576
Res[6] = 800x600
Res[7] = 960x720
Res[8] = 1024x768
Res[9] = 1280x1024
Res[10] = 1600x1200
[BitsPerPixel]
BPPDef = 16
BPP[0] = 16
BPP[1] = 24
BPP[2] = 32
[Disables]
DisableFullscreen = False
DisableScaled = False
DisableStatic = False
DisableAbout = False
DisableSaveSettings = False
DisableAddition = False
Binary file not shown.
File diff suppressed because it is too large Load Diff
Binary file not shown.

After

Width:  |  Height:  |  Size: 192 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 192 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 96 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 48 KiB

File diff suppressed because it is too large Load Diff
Binary file not shown.

After

Width:  |  Height:  |  Size: 48 KiB

File diff suppressed because it is too large Load Diff
Binary file not shown.

After

Width:  |  Height:  |  Size: 192 KiB

@@ -0,0 +1,5 @@
[Settings]
Option = 0
ResIndex = 0
BPPIndex = 0
Additional = 1
@@ -0,0 +1,674 @@
;
; SKY PLATEAU V1.01
; --------------------
; Simple 3D Demo, shows lots of simple 3D concepts.
; Written by Rob Hutchinson 2001 for Blitz 3D
; All models, textures and sounds by Rob Hutchinson.
; Email: loki.sd@cableinet.co.uk / ICQ: 27181384
;
; Created with BB3D Beta 1.60
; Last Modified: 18/08/2001
;
; Change this if you like.....
Global maxFlies = 5
Global skiesUnreal = 1
; Application title
AppTitle "Sky Plateau V1.01 - By Rob Hutchinson 2001"
; A type to hold each totem pole..
Type totem
Field pivot,totem,flare,light
End Type
Type plant
Field pivot,plant1,plant2,plant3,plant4
End Type
; Startup Include for BBLauncher!
;---------------------------------
; you can format the "Program Command Line" from the options like this:
; "/TYPE<Screen> /WIDTH<Width> /HEIGHT<Height> /BPP<Depth> /ADDIT<Additional>"
; Where <Screen> is either:
; 0 = FULLSCREEN
; 2 = WINDOWED or
; 1 = SCALED
;
; <Width> = display width, <Height> = display height, <Depth> = display depth.
;
; If you do not specify a command line, the default resolution of: 640x480x16
; (fullscreen always), will be assumed.
;
Include "launcher3d.bb"
If iAdditional = -1 Or iAdditional = 0
skiesUnreal = 0
Else
skiesUnreal = 1
EndIf
If skiesUnreal = 1
iPlaneSegs = 15
Else
iPlaneSegs = 1
EndIf
; Build the camera grouping...
Global campiv = CreatePivot()
Global camgrp = CreatePivot(campiv) ; Camera Grip
Global camera = CreateCamera(camgrp)
MoveEntity campiv,0,5,0
MoveEntity camgrp,0,25,-40
CameraFogMode camera,1
CameraFogRange camera,1,2
PointEntity camgrp,campiv
If skiesUnreal Then AmbientLight 0,0,0
Global cammoving = 1
; Create some totem poles.
Dim totems.totem(4)
totems(0) = stCreateTotem("Models\totem.x","Graphics\flare.bmp",20,0,20,0,45*5,0,255,0,0)
totems(1) = stCopyTotem(totems(0),-20,0,-20,0,45,0,0,255,0)
totems(2) = stCopyTotem(totems(0),20,0,-20,0,45*3,0,0,0,255)
totems(3) = stCopyTotem(totems(0),-20,0,20,0,45*7,0,0,255,255)
; Load up the plateau.
Global ground = LoadAnimMesh("Models\Ground.x")
MoveEntity ground,0,-2,0
; Sky and lower
Global skyplane1 = CreatePlane(iPlaneSegs)
Global skyplane1t = LoadTexture("Graphics\sky.bmp")
ScaleTexture skyplane1t,70,70
EntityTexture skyplane1,skyplane1t
TurnEntity skyplane1,0,0,180
MoveEntity skyplane1,0,-65,0
EntityAlpha skyplane1,.8
EntityBlend skyplane1,3
Global skyplane2 = CreatePlane()
Global skyplane2t = LoadTexture("Graphics\stars.bmp")
ScaleTexture skyplane2t,22,22
EntityTexture skyplane2,skyplane2t
TurnEntity skyplane2,0,0,180
MoveEntity skyplane2,0,-65.2,0
Global skyplane3 = CreatePlane(4)
Global skyplane3t = LoadTexture("Graphics\lower.bmp")
ScaleTexture skyplane3t,70,70
EntityTexture skyplane3,skyplane3t
MoveEntity skyplane3,0,-10,0
; Logo
logosp = LoadSprite("Graphics\logo.bmp",1,camgrp)
EntityOrder logosp,-1
; SETUP SYSTEM
Const DEMO_STATE_FOGOPEN = 1
Const DEMO_STATE_FOGLOGOMOVE = 2
Const DEMO_STATE_FADEOPTIONS = 3
Const DEMO_STATE_STREAM = 99
Const DEMO_STATE_TERMINATESPIN = 1000
Const DEMO_STATE_TERMINATEFOGFADE = 1001
demostate = DEMO_STATE_FOGOPEN
fr# = 2
; Logo movement
LogoStartX# = 0
LogoStartY# = 0
LogoStartZ# = 3.3
LogoEndX# = -4.8
LogoEndY# = 3.4
LogoEndZ# = 6
MoveSpd# = 0.1
SlowSpd# = 1.015
PositionEntity logosp,LogoStartX#,LogoStartY#,LogoStartZ#
movetopiv = CreatePivot(camgrp)
PositionEntity movetopiv,LogoEndX#,LogoEndY#,LogoEndZ#
; Menu Setup
Const MENU_STATE_IDLE = 0
Const MENU_STATE_FADEDN = 1
Const MENU_STATE_FADEUP = 2
Const MENU_STATE_ENTERU = 3
Const MENU_STATE_ENTERD = 4
Global menustate = MENU_STATE_IDLE
Global menufademax# = .5
Global menufade# = menufademax#
Global menufadespd# = .02
optssp = LoadSprite("Graphics\options.bmp",1,camgrp)
EntityOrder optssp,-1
ScaleSprite optssp,1.5,.7
optsbarsp = LoadSprite("Graphics\menubar.bmp",1,camgrp)
EntityOrder optsbarsp,-1
ScaleSprite optsbarsp,1.6,.19
EntityAlpha optsbarsp,menufade#
PointEntity logosp,movetopiv
PositionEntity optssp,-LogoEndX#-.5,LogoEndY#+.3,LogoEndZ#
Type mnuitem
Field x#,y#,z#
End Type
Dim MenuItems.mnuitem(4)
MenuItems(0) = New mnuitem
MenuItems(0)\x = 4.12
MenuItems(0)\y = 4.07
MenuItems(0)\z = 5.8
MenuItems(1) = New mnuitem
MenuItems(1)\x = 4.12
MenuItems(1)\y = 3.74
MenuItems(1)\z = 5.8
MenuItems(2) = New mnuitem
MenuItems(2)\x = 4.12
MenuItems(2)\y = 3.42
MenuItems(2)\z = 5.8
MenuItems(3) = New mnuitem
MenuItems(3)\x = 4.12
MenuItems(3)\y = 3.09
MenuItems(3)\z = 5.8
Global CurrentOption = 3
PositionEntity optsbarsp,MenuItems(CurrentOption)\x,MenuItems(CurrentOption)\y,MenuItems(CurrentOption)\z
Global FadeBias# = 0.1
; Fireflies........
Type firefly
Field obj
Field posx#,posy#,posz#
Field rotx#,roty#,rotz#
Field radx#,rady#,radz#
Field spdx#,spdy#,spdz#
Field spnx#,spny#,spnz#
End Type
; Setup the fireflies
Global TopSpeed# = 2.5
flyOrig = LoadSprite("Graphics\hyperflare.bmp",1)
PositionEntity flyOrig,0,20,0
ScaleSprite flyOrig,1.75,1.75
HideEntity flyOrig
; Create the fireflies
Dim flies.firefly(maxFlies+1)
For a=0 To maxFlies ; Create a pile of flies
flies(a) = New firefly
flies(a)\obj = CopyEntity(flyOrig)
EntityAlpha flies(a)\obj,Rnd(0.1,1.0)
ShowEntity flies(a)\obj
flies(a)\rotx = Rnd(360)
flies(a)\roty = Rnd(360)
flies(a)\rotz = Rnd(360)
flies(a)\radx = Rnd(-10,10)
flies(a)\rady = Rnd(-10,10)
flies(a)\radz = Rnd(-10,10)
flies(a)\spdx = Rnd(-TopSpeed#,TopSpeed#)
flies(a)\spdy = Rnd(-TopSpeed#,TopSpeed#)
flies(a)\spdz = Rnd(-TopSpeed#,TopSpeed#)
flies(a)\spnx = Rnd(-TopSpeed#,TopSpeed#)
flies(a)\spny = Rnd(-TopSpeed#,TopSpeed#)
flies(a)\spnz = Rnd(-TopSpeed#,TopSpeed#)
Next
; the environment map.
steela = LoadTexture("Graphics\env.bmp",64)
surrounda = LoadTexture("Graphics\env2.bmp",64)
; the center tubing computer thing-e-me-bob.. + the computer screens and up lighter...
EntityAlpha GetChild(ground,6),.7
EntityAlpha GetChild(ground,7),.7
centertube = GetChild(ground,5)
EntityTexture centertube,surrounda
EntityBlend GetChild(ground,9),3
Global iMouseLook = 0
; icon thing..
iconmesh = LoadAnimMesh("Models\icon.x")
icon = GetChild(iconmesh,1)
container = GetChild(iconmesh,2)
ScaleEntity iconmesh,.2,.2,.2
MoveEntity iconmesh,0,20,0
EntityAlpha container,.2
shieldsa = LoadTexture("Graphics\shields.bmp")
EntityTexture icon,steela
EntityTexture container,shieldsa
; MD2 stuff.....
myplant.plant = stCreateFourPlant("Models\Plantlife.md2","Graphics\Plantlife.bmp",11.8,-2.1,-10.2,0,0,0)
planter1.plant = stCopyFourPlant(myplant,-40.6,1.4,7.0,-17.2,36.79,-7.4,4)
planter2.plant = stCopyFourPlant(myplant,29,1.6,-49.2,4,0,9.9,4)
planter3.plant = stCopyFourPlant(myplant,-11,-2.4,3.82,-6.39,-28.4,-2,1)
planter4.plant = stCopyFourPlant(myplant,30.8,2.7,46.76,-1.19,-108.3,-21.1,1)
; Final lighting...
;piva = CreatePivot()
;cona = CreateCone(3,1,piva)
;toplight = CreateLight(2,piva)
;LightColor toplight,50,50,50
;LightRange toplight,100
;RotateEntity toplight,90,0,0
;MoveEntity piva,0,30,0
If skiesUnreal
skylightpiv = CreatePivot()
;skylightcone = CreateCone(3,1,skylightpiv)
skylight = CreateLight(2,skylightpiv)
LightColor skylight,255,0,0
LightRange skylight,90
RotateEntity skylight,-90,0,0
MoveEntity skylightpiv,80,30,80
skylightpiv1 = CreatePivot()
;skylightcone1 = CreateCone(3,1,skylightpiv1)
skylight1 = CreateLight(2,skylightpiv1)
LightColor skylight1,0,0,255
LightRange skylight1,90
RotateEntity skylight1,-90,0,0
MoveEntity skylightpiv1,-80,30,80
skylightpiv2 = CreatePivot()
;skylightcone2 = CreateCone(3,1,skylightpiv2)
skylight2 = CreateLight(2,skylightpiv2)
LightColor skylight2,255,255,0
LightRange skylight2,90
RotateEntity skylight2,-90,0,0
MoveEntity skylightpiv2,80,30,-80
skylightpiv3 = CreatePivot()
;skylightcone3 = CreateCone(3,1,skylightpiv3)
skylight3 = CreateLight(2,skylightpiv3)
LightColor skylight3,0,255,255
LightRange skylight3,90
RotateEntity skylight3,-90,0,0
MoveEntity skylightpiv3,-80,30,-80
EndIf
; Start the music, boy-o!
Global musicchan
musicchan = StartMusic()
Repeat
If iMouseLook
; Thanks to Si for this little block of code I pinched :)....
mxs=MouseXSpeed()/2
mys=MouseYSpeed()/2
; Update destination camera angle x and y values
dest_xang#=dest_xang#+mys
dest_yang#=dest_yang#-mxs
; Curve camera angle values towards destination values
xang#=CurveValue#(xang#,dest_xang#,5)
yang#=CurveValue#(yang#,dest_yang#,5)
; Rotate camera
RotateEntity camgrp,xang#,yang#,0
MoveMouse GraphicsWidth()/2,GraphicsHeight()/2
EndIf
; Do music repeat
If ChannelPlaying(musicchan) = False Then musicchan = StartMusic()
; Do the fire flies.
For a=0 To maxFlies
TurnEntity flies(a)\obj,flies(a)\spnx,flies(a)\spny,flies(a)\spnz
flies(a)\posx=Sin(flies(a)\rotx)*flies(a)\radx
flies(a)\posy=Cos(flies(a)\roty)*flies(a)\rady
flies(a)\posz=Sin(flies(a)\rotz)*flies(a)\radz
flies(a)\rotx=flies(a)\rotx+flies(a)\spdx
flies(a)\roty=flies(a)\roty+flies(a)\spdy
flies(a)\rotz=flies(a)\rotz+flies(a)\spdz
flies(a)\rotx=QWrap(flies(a)\rotx,0,360)
flies(a)\roty=QWrap(flies(a)\roty,0,360)
flies(a)\rotz=QWrap(flies(a)\rotz,0,360)
PositionEntity flies(a)\obj,flies(a)\posx,flies(a)\posy+20,flies(a)\posz
Next
; Demo states...
Select demostate
Case DEMO_STATE_FOGOPEN
CameraFogRange camera,1,fr#
fr# = fr# + 0.4
If fr# >= 250 Then demostate = DEMO_STATE_LOGOMOVE
Case DEMO_STATE_LOGOMOVE
MoveEntity logosp,0,0,MoveSpd
MoveSpd = MoveSpd / SlowSpd
If EntityZ(logosp) >= LogoEndZ# Then demostate = DEMO_STATE_FADEOPTIONS
Case DEMO_STATE_FADEOPTIONS
Case DEMO_STATE_STREAM
Case DEMO_STATE_TERMINATESPIN
MoveEntity camgrp,0,0,-FadeBias#
If fadebw = 0
FadeBias# = FadeBias# * 1.02
Else
FadeBias# = FadeBias# / 1.02
EndIf
If FadeBias# >= 2.00 Then fadebw = 1
If fadebw = 1
If FadeBias# < 0.2
demostate = DEMO_STATE_TERMINATEFOGFADE
EndIf
EndIf
Case DEMO_STATE_TERMINATEFOGFADE
fr# = fr# - 1.7
If fr# <= 2.0 Then End
CameraFogRange camera,1,fr#
End Select
; Menu Controls.
If menuonline = 0
Select menustate
Case MENU_STATE_IDLE
If KeyHit(208) ; Down
CurrentOption = CurrentOption + 1
If CurrentOption > 3
CurrentOption = 3
Else
menustate = MENU_STATE_FADEDN
EndIf
Else
If KeyHit(200) ; Up
CurrentOption = CurrentOption - 1
If CurrentOption < 0
CurrentOption = 0
Else
menustate = MENU_STATE_FADEDN
EndIf
Else
If KeyHit(28) ; Enter
menustate = MENU_STATE_ENTERU
EndIf
EndIf
EndIf
Case MENU_STATE_FADEDN
menufade# = menufade# - menufadespd#
If menufade# <= 0
menufade# = 0
menustate = MENU_STATE_FADEUP
PositionEntity optsbarsp,MenuItems(CurrentOption)\x,MenuItems(CurrentOption)\y,MenuItems(CurrentOption)\z
EndIf
EntityAlpha optsbarsp,menufade#
Case MENU_STATE_FADEUP
menufade# = menufade# + menufadespd#
If menufade# >= menufademax#
menufade# = menufademax#
menustate = MENU_STATE_IDLE
EndIf
EntityAlpha optsbarsp,menufade#
Case MENU_STATE_ENTERU
menufade# = menufade# + menufadespd#
If menufade# >= 1
menufade# = 1
menustate = MENU_STATE_ENTERD
; Menu commands:
Select CurrentOption
Case 0
EndGraphics
ExecFile "Launcher.exe"
End
Case 1
iMouseLook = Not iMouseLook
Case 2
cammoving = Not cammoving
Case 3
menuonline = 1
demostate = DEMO_STATE_TERMINATESPIN
End Select
EndIf
EntityAlpha optsbarsp,menufade#
Case MENU_STATE_ENTERD
menufade# = menufade# - menufadespd#
If menufade# <= menufademax#
menufade# = menufademax#
menustate = MENU_STATE_IDLE
EndIf
EntityAlpha optsbarsp,menufade#
End Select
EndIf
; Move stuff around a lil
MoveEntity skyplane1,0,0,.5
MoveEntity skyplane2,0,0,.2
MoveEntity skyplane3,0,0,.3
TurnEntity container,0,1,2
TurnEntity icon,0,-2,0
If cammoving
RotateEntity campiv,Sin(ll#)*20,ll#,0
ll# = ll# + 0.7
EndIf
UpdateWorld
RenderWorld
; DEVPosRotEntityWM(planter4\pivot,campiv)
Flip
Until KeyDown(1)
End
Function stCreateTotem.totem(filename$,flarename$,x#,y#,z#,p#,ya#,r#,lr,lg,lb)
Local tTotem.totem = New totem
tTotem\pivot = CreatePivot()
tTotem\totem = LoadMesh(filename$,tTotem\pivot)
tTotem\flare = LoadSprite(flarename$,1,tTotem\pivot)
If skiesUnreal=0 Then
tTotem\light = CreateLight(1,tTotem\pivot)
LightColor tTotem\light,lr,lg,lb
PointEntity tTotem\light,campiv
MoveEntity tTotem\light,2.2,26.65,0
EndIf
ScaleSprite tTotem\flare,5,5
MoveEntity tTotem\flare,2.2,26.65,0
EntityOrder tTotem\flare,-1
PositionEntity tTotem\pivot,x#,y#,z#
RotateEntity tTotem\pivot,p#,ya#,r#
Return tTotem
End Function
Function stCopyTotem.totem(tot.totem,x#,y#,z#,p#,ya#,r#,lr,lg,lb)
Local tTotem.totem = New totem
tTotem\pivot = CreatePivot()
tTotem\totem = CopyEntity(tot\totem,tTotem\pivot)
tTotem\flare = CopyEntity(tot\flare,tTotem\pivot)
If skiesUnreal=0 Then
tTotem\light = CreateLight(1,tTotem\pivot)
MoveEntity tTotem\light,2.2,26.65,0
LightColor tTotem\light,lr,lg,lb
PointEntity tTotem\light,campiv
EndIf
PositionEntity tTotem\pivot,x,y,z
RotateEntity tTotem\pivot,p,ya,r
Return tTotem
End Function
Function QWrap(Value#,Low#,High#) ; Remember this? where is the Blitz
Return Low#+(Value# Mod High#) ; PC version when you need it? :))
End Function
Function StartMusic()
Return PlayMusic("Music\atmos.mp3")
End Function
Function CurveValue#(current#,destination#,curve)
current#=current#+((destination#-current#)/curve)
Return current#
End Function
Function stCreateFourPlant.plant(filename$,texturepa$,x#,y#,z#,p#,ya#,r#)
Local tPlant.plant = New plant
tPlant\pivot = CreatePivot()
tPlant\plant1 = LoadMD2(filename$,tPlant\pivot)
EntityTexture tPlant\plant1,LoadTexture(texturepa$)
ScaleEntity tPlant\plant1,.2,.1,.1
PositionEntity tPlant\plant1,-.5,0,0
tPlant\plant2 = CopyEntity(tPlant\plant1,tPlant\pivot)
tPlant\plant3 = CopyEntity(tPlant\plant1,tPlant\pivot)
tPlant\plant4 = CopyEntity(tPlant\plant1,tPlant\pivot)
RotateEntity tPlant\plant2,0,90*1,0
RotateEntity tPlant\plant3,0,90*2,0
RotateEntity tPlant\plant4,0,90*3,0
PositionEntity tPlant\pivot,x#,y#,z#
RotateEntity tPlant\pivot,p#,ya#,r#
AnimateMD2 tPlant\plant1,2,Rnd(0.02,0.05),0,2
AnimateMD2 tPlant\plant2,2,Rnd(0.02,0.05),0,2
AnimateMD2 tPlant\plant3,2,Rnd(0.02,0.05),0,2
AnimateMD2 tPlant\plant4,2,Rnd(0.02,0.05),0,2
Return tPlant
End Function
Function stCopyFourPlant.plant(planty.plant,x#,y#,z#,p#,ya#,r#,copyamt)
Local tPlant.plant = New plant
tPlant\pivot = CreatePivot()
If copyamt > 0
tPlant\plant1 = CopyEntity(planty\plant1,tPlant\pivot)
AnimateMD2 tPlant\plant1,2,Rnd(0.02,0.05),0,2
EndIf
If copyamt > 1
tPlant\plant3 = CopyEntity(planty\plant3,tPlant\pivot)
AnimateMD2 tPlant\plant3,2,Rnd(0.02,0.05),0,2
EndIf
If copyamt > 2
tPlant\plant2 = CopyEntity(planty\plant2,tPlant\pivot)
AnimateMD2 tPlant\plant2,2,Rnd(0.02,0.05),0,2
EndIf
If copyamt > 3
tPlant\plant4 = CopyEntity(planty\plant4,tPlant\pivot)
AnimateMD2 tPlant\plant4,2,Rnd(0.02,0.05),0,2
EndIf
PositionEntity tPlant\pivot,x#,y#,z#
RotateEntity tPlant\pivot,p#,ya#,r#
Return tPlant
End Function
; DEVPosRotEntityWM(entityobject,cameraobject,[speed#])
; -----------------------------------------------------
; AUTHOR: Rob Hutchinson (loki.sd@cableinet.co.uk)
; BB3DV: v1.60 Beta.
; DESC: Simple function to help you position and rotate an entity with the mouse.
; PARAMS: entityobject - the entity you want to fiddle with.
; speed# - the speed to move with. Recommend around 0.1 (default)
; NOTES: Will lock the mouse in the center of the screen in order to achieve more
; smooth movement with MXS() and MYS(). You should comment out any mouse
; command stuff your program is doing before using this function.
; USAGE: Call this function straight after RenderWorld(), cos it needs to output text.
;
; CONTROL: NORMAL MODE + ALT MODE + ROT MODE + ROT+ALT MODE
; CONTROLS: Up/Down = +/- Z axis | +/- Y axis | +/- Roll | +/- Roll
; Left/Right = +/- X axis | +/- X axis | +/- Pitch | +/- Yaw
; ---------------------------------------------------------------------------
; SWITCHES:
; LMB = Hold down to switch to alt mode.
; RMB = Hold down to switch to rotation mode.
; MMB = Hold down to switch to camera mode. (this will allow you to
; simply see whats going on)
; F1 = Reset all positions
;
; HAHA! its a bitch to start with, but it gets easier :) (unless your MMB is
; in some ungodly place on the mouse :)).
;
Global entitX#,entitY#,entitZ#
Global entitPi#,entitYa#,entitRo#
Global cammyX#,cammyY#,cammyZ#
Global cammyPi#,cammyYa#,cammyRo#
Function DEVPosRotEntityWM(ent,cammy,spd# = .1)
msX# = MouseXSpeed() * spd#
msY# = MouseYSpeed() * spd#
If MouseDown(3) = False
; We are working with the entity..
If MouseDown(2) = False
entitX# = entitX# + msX#
If MouseDown(1) = False
entitZ# = entitZ# - msY#
Else
entitY# = entitY# - msY#
EndIf
Else
entitPi# = entitPi# - msY#
If MouseDown(1) = False
entitRo# = entitRo# - msX#
Else
entitYa# = entitYa# + msX#
EndIf
EndIf
Else
; We are working with the camera..
If MouseDown(2) = False
cammyX# = cammyX# + msX#
If MouseDown(1) = False
cammyZ# = cammyZ# - msY#
Else
cammyY# = cammyY# - msY#
EndIf
Else
cammyPi# = cammyPi# - msY#
If MouseDown(1) = False
cammyRo# = cammyRo# - msX#
Else
cammyYa# = cammyYa# + msX#
EndIf
EndIf
EndIf
If KeyHit(59)
; Reset positions....
entitX# = 0 : entitY# = 0 : entitZ# = 0
cammyX# = 0 : cammyY# = 0 : cammyZ# = 0
entitPi# = 0 : entitYa# = 0 : entitRo# = 0
cammyPi# = 0 : cammyYa# = 0 : cammyRo# = 0
EndIf
PositionEntity ent,entitX#,entitY#,entitZ#
RotateEntity ent,entitPi#,entitYa#,entitRo#
PositionEntity cammy,cammyX#,cammyY#,cammyZ#
RotateEntity cammy,cammyPi#,cammyYa#,cammyRo#
Text 0,FontHeight()*0,"PRWM() - Entity X# = " + entitX#
Text 0,FontHeight()*1,"PRWM() - Entity Y# = " + entitY#
Text 0,FontHeight()*2,"PRWM() - Entity Z# = " + entitZ#
Text 0,FontHeight()*3,"PRWM() - Entity Pitch# = " + entitPi#
Text 0,FontHeight()*4,"PRWM() - Entity Yaw# = " + entitYa#
Text 0,FontHeight()*5,"PRWM() - Entity Roll# = " + entitRo#
MoveMouse GraphicsWidth()/2,GraphicsHeight()/2
End Function
Binary file not shown.

After

Width:  |  Height:  |  Size: 3.2 KiB

@@ -0,0 +1,60 @@
;
; LAUNCHER 3D INCLUDE V1.01
; -------------------------
; Simple Include to handle startup for programs written
; to use BBLauncher.
; Written by Rob Hutchinson 2001
; Email: loki.sd@cableinet.co.uk / ICQ: 27181384
;
; Last Modified: 18/08/2001
;
; Some default values, change these if you like...
Const RESOLUTION_DEFAULT_WIDTH = 640
Const RESOLUTION_DEFAULT_HEIGHT = 480
Const RESOLUTION_DEFAULT_DEPTH = 16
; This is the command line..
Global sCL$ = Upper(CommandLine())
; Find the screen mode...
iScrType = bblGetOption("TYPE",0)
Select iScrType
Case 1
iScreenMode = 3
HidePointer()
Case 2
iScreenMode = 2
HidePointer()
Case 0
iScreenMode = 1
End Select
; Get the screen details!
iScreenResX = bblGetOption("WIDTH",Str(RESOLUTION_DEFAULT_WIDTH))
iScreenResY = bblGetOption("HEIGHT",Str(RESOLUTION_DEFAULT_HEIGHT))
iBitsPerPixel = bblGetOption("BPP",Str(RESOLUTION_DEFAULT_DEPTH))
iAdditional = bblGetOption("ADDIT",-1)
; Work with the details!
If GfxMode3DExists(iScreenResX,iScreenResY,iBitsPerPixel)
Graphics3D iScreenResX,iScreenResY,iBitsPerPixel,iScreenMode
SetBuffer BackBuffer()
Else
; Fire it back out to the launcher cos screen res is unsupported...
ExecFile "Launcher.exe"
RuntimeError "The graphics card in this machine does not support the selected screenmode!" + Chr(10) + Chr(13) + "Please select another..."
End
EndIf
; FUNCTIONS ->
;------------------
Function bblGetOption$(opts$,defaultstr$="")
iInTmp = Instr(sCL$,"/" + opts$)
If iInTmp <> 0
iInTmp2 = Instr(Mid$(sCL$,iInTmp)," ")
Return Mid$(Mid$(sCL$,iInTmp+Len(opts$)+1),1,iInTmp2-(Len(opts$)+2))
Else
Return defaultstr$
EndIf
End Function
Binary file not shown.

After

Width:  |  Height:  |  Size: 192 KiB

@@ -0,0 +1,125 @@
;Logo()
SetGfx()
Type GfxMode
Field width,height,depth
End Type
Function Logo()
Graphics3D 640,480
SetBuffer BackBuffer()
image=LoadImage( "b3dlogo.jpg" )
If image=0 image=LoadImage( "../b3dlogo.jpg" )
MidHandle image
Color 255,0,0
SetFont LoadFont( "helvetica",16 )
t=MilliSecs()
txt1$="(C)opyright Blitz Research Limited"
txt2$="Published by Guildhall Leisure Services"
txt3$="Find out more at www.blitz-3d.com"
yy=320
Repeat
Cls
DrawBlock image,320,yy-120
Color 0,0,192
Text 0,480-FontHeight()*2,txt1$
Text 0,480-FontHeight()*1,txt2$
Color 0,255,0
Text 640-StringWidth(txt3$),480-FontHeight()*1,txt3$
Color 255,0,0
Text 320,yy+FontHeight()*0,info1$,True,True
Text 320,yy+FontHeight()*1,info2$,True,True
Text 320,yy+FontHeight()*2,info3$,True,True
Text 320,yy+FontHeight()*3,info4$,True,True
d=MilliSecs()-t
If d>5000
If tick=0
tick=127
FlushKeys
Else
tick=tick-1
If tick=0 tick=127
EndIf
If tick And 64
Color 255,255,255
Text 320,yy+FontHeight()*5,"Press any key",True,True
EndIf
If GetKey() Then Exit
EndIf
Flip
Forever
For k=1 To 2
Cls:Flip
Next
FreeImage image
FlushKeys
End Function
Function SetGfx()
Print info1$:Print info2$:Print info3$:Print info4$:Print
If Windowed3D()
yn$=Input$( "Use windowed mode?" )
If Left$( Lower$( yn$ ),1 )="y"
HidePointer
Graphics3D 640,480,0,2
SetBuffer BackBuffer()
Return
EndIf
EndIf
Print ""
Print "Display drivers:"
Print "----------------"
For k=1 To CountGfxDrivers()
Print k+":"+GfxDriverName$(k)
Next
Print ""
If CountGfxDrivers()>1
Repeat
driver=Input$( "Display driver (1-"+CountGfxDrivers()+"):" )
Until driver>=1 And driver<=CountGfxDrivers()
SetGfxDriver driver
EndIf
Print ""
Print "Display modes:"
Print "--------------"
cnt=0
For k=1 To CountGfxModes()
If GfxMode3D(k)
t.GfxMode=New GfxMode
t\width=GfxModeWidth(k)
t\height=GfxModeHeight(k)
t\depth=GfxModeDepth(k)
cnt=cnt+1
Print cnt+":"+t\width+","+t\height+","+t\depth
EndIf
Next
If Not cnt
Print "No 3D Graphics modes available!"
Print "Press any key..."
WaitKey
End
EndIf
Repeat
mode=Input$( "Display Mode (1-"+cnt+"):" )
Until mode>=1 And mode<=cnt
t.GfxMode=First GfxMode
While mode>1
t=After t
mode=mode-1
Wend
Graphics3D t\width,t\height,t\depth,1
SetBuffer BackBuffer()
Delete Each GfxMode
End Function
@@ -0,0 +1,103 @@
;
; WATERY TERRAIN V1.00
; --------------------
; Creating and modifying terrain entities to create water (err, something that sort
; of resembles water,.. sort of :)). Mainly just to show how to modify terrain to
; create such effects. You could do crashing waves, or water ripples. (Might
; have a crack at that later :))
;
; Written by Rob Hutchinson 2001 for Blitz 3D
; Textures by Rob Hutchinson. Email: loki.sd@cableinet.co.uk / ICQ: 27181384
;
; Created with BB3D Beta 1.57
; Last Modified: 10/08/2001
;
; Modify these if you like :)
Const WATER_GRID_SIZE = 16
Global WATER_HEIGHT# = 8.2
; Setup the water grid values
Dim WaterY(WATER_GRID_SIZE+1,WATER_GRID_SIZE+1)
For q = 0 To WATER_GRID_SIZE
For j = 0 To WATER_GRID_SIZE
WaterY(q,j) = Rnd(0,360)
Next
Next
; Setup the screen
Include "start.bb"
; Setup the camera
campiv = CreatePivot()
camera = CreateCamera(campiv)
CameraFogMode camera,1
CameraFogRange camera,1,100
MoveEntity campiv,0,5,0
MoveEntity camera,0,1,-10
; Create some terrain and load the water texture onto it
water = CreateTerrain(WATER_GRID_SIZE)
watert = LoadTexture("water.bmp")
ScaleTexture watert,2,2
EntityTexture water,watert
EntityAlpha water,.4
; Create a floor plane and texture it
bed = CreatePlane()
bedt = LoadTexture("oceanfloor.bmp")
ScaleTexture bedt,15,15
EntityTexture bed,bedt
MoveEntity bed,0,-8,0
; Modify the detail of the terrain
TerrainShading water,True
Global curdetail = 2000
TerrainDetail water,curdetail,True
; Resize and position the water
MoveEntity water,-60,-10,-60
ScaleEntity water,8,WATER_HEIGHT#,8
; Some ambient lighting
AmbientLight 200,200,200
Repeat
; Allow the user to switch to wireframe mode.
If KeyHit(17) Then wire = Not wire
WireFrame wire
; Move the camera around
RotateEntity campiv,Sin(ll#)*10,ll#,0
ll# = ll# + 0.2
PointEntity camera,campiv
; Terrain Detail level
If KeyDown(26) Then curdetail = curdetail - 10
If KeyDown(27) Then curdetail = curdetail + 10
TerrainDetail water,curdetail,True
; Here we itterate through all the cells on the terrain grid (switch wireframe on to
; see them) and then make them simply bounce up and down.
For z = 0 To WATER_GRID_SIZE-1
For x = 0 To WATER_GRID_SIZE-1
hite# = Sin(WaterY(z,x))
ModifyTerrain water,x,z,Abs(hite#/2)+.5,False
WaterY(z,x) = WaterY(z,x) + 1
Next
Next
; Update the world stuff
UpdateWorld
RenderWorld
; Print some simple details on screen.
Text 0,0,"W = Wireframe Toggle"
Text 0,12,"LOD = [ and ] (" + curdetail + ")"
; Flip display
Flip
Until KeyDown(1)
; Terminate.
End
Binary file not shown.

After

Width:  |  Height:  |  Size: 192 KiB

File diff suppressed because it is too large Load Diff
Binary file not shown.

After

Width:  |  Height:  |  Size: 192 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 192 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 192 KiB

@@ -0,0 +1,647 @@
;
; Wings Pilot V0.01
; Written and Copyright by Rob Hutchinson 2001
;
; CONTROLS:
; ESC - Exit
; ARROWS - Move craft around.
; A - Thrust
; Z - Brake
; ALT - Fire
; SPACE - Shields
;
;
; To do next:
; - Add meters.
;
; Then:
; - Use INI functions to create a mini level script language with names of objects to load and positions.
; - Create ground (try some terrains)
;
;
;Graphics3D 1024,768,16
Graphics3D 640,480
SetBuffer BackBuffer()
; Variables..
Global dObjs$ = "objects\",dGfx$ = "graphics\",dSnd$ = "sounds\"
Global cCamera,mShip,pRing,mRing,sLamp,tRing,mCent,tCent
Global mCraft,sFlame1,sFlame2,pCraft,pCraftIn,mShields,mShields2,tShields
Global pWeaponPoint1,pWeaponPoint2
Global screenLeft = -20,screenRight = 20,screenTop = 15,screenBottom = -15
; Craft VARS
Global craftTopSpeed# = 0.5 ; Craft's top speed.
Global craftInertiaX# = 0 ; Craft X inertia.
Global craftInertiaY# = 0 ; Craft Y inertia.
Global craftAccel# = craftTopSpeed# / 50 ; Craft acceleration speed.
Global craftDecel# = craftTopSpeed# / 100 ; Craft deceleration speed.
Global craftTilt# = 100 ; Amount to tilt the craft when manouvering
Global craftPitch# = 0 ; This is used by the program to store craft tilt.
Global craftRoll# = 0 ; -"-
Global craftRollMax# = 60 ; What angle to stop craft rotating at when moving.
Global craftPitchMax# = 70 ; -"-
Global craftWobble# = 0 ; Used in prog for general craft wobble
Global craftX# = 0 ; Craft absolute x
Global craftY# = 0 ; Craft absolute y
Global craftZ# = 15 ; Craft absolute z
Global craftShieldAlphaMax# = 0.3 ; Maximum shield alpha
Global craftShieldAlphaRunOff# = craftShieldAlphaMax# / 150 ; How fast shields fade back to 0
Global craftShieldAlpha# = 0 ; Current alpha level of the shields.
Global craftTurbulance# = 0 ; Current craft turbulance
Global craftTurbulanceRunOff# = 0.07 ; How fast turbulance wears off.
; Scene variables
Global sceneZ#
Global sceneSpeed#
; Sound variables
Global sThruRing,sRingBonus,sDamage
; Ring variables
Type tRing
; Entities
Field ePivot
Field eRing
Field eCenter
Field eFlare1
Field eFlare2
; Attributes
Field x#,y#,z#
Field pitch#,yaw#,roll#
Field bonus
End Type
Global ringDamage# = 150 ; The amount of damage hitting a ring does.
; Flame variables.
Type tFlame
Field obj
Field speed#,count#,untildist#
Field prescale#,scaledown#
Field alphadown#,alphacn#
End Type
Global pFlamePoint
Global flameCountFrame = 0
Global newflameAfterFrames = 0
Global flameNormalSize# = 1.5
Global flameNewSize# = 0
; Player variables
Global playerScore# = 0 ; Current players' score.
Global playerThrust = 1000 ; How much thrust does the player have left?
Global playerThrustMax = 1000 ; How much thrust can the player have maximum.
Global playerBrake = 250 ; How much brake does the player have left?
Global playerBrakeMax = 250 ; How much brake can the player have maximum.
Global playerThrustZ# = 0 ; The current amount of thrust
Global playerBrakeZ# = 0 ; The current amount of brake
Global playerThrustZMax# = 0.8 ; How much to add to scene coords when thrust is at max.
Global playerBrakeZMax# = 0.2 ; How much to sub from scene coords when thrust is at max.
Global playerFrameToMax# = 60 ; Number of updates before thrust of brake is at full capacity.
Global playerFSThrstMax# = 1.5 ; FLAME SCALE: Addition to make when thrust is at full.
Global playerFSBrakeMax# = 0.5 ; FLAME SCALE: Subtraction to make when brake is at full.
Global playerShields# = 1000 ; The current amount of shields the player has.
Global playerShieldsMax# = 1000 ; The max shields amount
Global playerEnergy# = 1000 ; The current amount of energy the player has.
Global playerEnergyMax# = 1000 ; The max energy amount
; Weapons
Type tWeapon
Field name$
Field ent
Field typeid
Field sound
Field strength#
Field speed#
Field vanishdist#
Field ammomax
Field ammo
Field rotspeed#
End Type
Const WEAPON_TYPEID_RECHARGE = 1
Const WEAPON_TYPEID_UNLIMITED = 2
Const WEAPON_TYPEID_DEMINISHING = 3
Dim weaponList.tWeapon(100)
Global weaponCurrent = 0
Type tBullet
Field weapon
Field ent1
Field rot#
End Type
; Floor
Global mFloor1,tFloor1,mFloor2,tFloor2
Global fRot1#
; sky
Global mSky1,tSky1,mSky2,tSky2
; Constants..
Const T_RING=1,T_CRAFT=2,T_CENTER=3
Const KEY_UP = 200
Const KEY_LEFT = 203
Const KEY_RIGHT = 205
Const KEY_DOWN = 208
Const KEY_A = 30
Const KEY_Z = 44
Const KEY_X = 45
Collisions T_CRAFT,T_RING,2,0
Collisions T_CRAFT,T_CENTER,2,0
; Set everything up..
Setup()
lt# = 0
For a=0 To 50
CreateNewRing(Sin(lt#)*25,Cos(lt#)*25,a*60,Rnd(-4.0,4.0),Rnd(-4.0,4.0),Rnd(-12.0,12.0),Rnd(0,255),Rnd(0,255),Rnd(0,255))
lt = lt + 30
Next
Global temp
; Main loop!
Repeat
; Stuff
If KeyDown(KEY_LEFT)
craftInertiaX# = craftInertiaX# - craftAccel#
ikeyHitX = True
EndIf
If KeyDown(KEY_RIGHT)
craftInertiaX# = craftInertiaX# + craftAccel#
ikeyHitX = True
EndIf
If KeyDown(KEY_DOWN)
craftInertiaY# = craftInertiaY# + craftAccel#
ikeyHitY = True
EndIf
If KeyDown(KEY_UP)
craftInertiaY# = craftInertiaY# - craftAccel#
ikeyHitY = True
EndIf
; Fire button
If KeyHit(KEY_X)
AddWeaponFire(weaponCurrent)
EndIf
; Do thrust calc
If KeyDown(KEY_A)
playerThrust = playerThrust - 1
If playerThrust < 0 Then playerThrust = 0
If playerThrust > 0
playerThrustZ# = playerThrustZ# + (playerThrustZMax#/playerFrameToMax#)
If playerThrustZ# >= playerThrustZMax# Then playerThrustZ# = playerThrustZMax#
Else
playerThrustZ# = playerThrustZ# - (playerThrustZMax#/playerFrameToMax#)
If playerThrustZ# < 0 Then playerThrustZ# = 0
EndIf
Else
playerThrustZ# = playerThrustZ# - (playerThrustZMax#/playerFrameToMax#)
If playerThrustZ# < 0 Then playerThrustZ# = 0
EndIf
; Do brake calc
If KeyDown(KEY_Z)
playerBrake = playerBrake - 1
If playerBrake < 0 Then playerBrake = 0
If playerBrake > 0
playerBrakeZ# = playerBrakeZ# + (playerBrakeZMax#/playerFrameToMax#)
If playerBrakeZ# >= playerBrakeZMax# Then playerBrakeZ# = playerBrakeZMax#
Else
playerBrakeZ# = playerBrakeZ# - (playerBrakeZMax#/playerFrameToMax#)
If playerBrakeZ# < 0 Then playerBrakeZ# = 0
EndIf
Else
playerBrakeZ# = playerBrakeZ# - (playerBrakeZMax#/playerFrameToMax#)
If playerBrakeZ# < 0 Then playerBrakeZ# = 0
EndIf
; Start slowing down if no key is hit.
If ikeyHitX = False
If craftInertiaX# <> 0
If craftInertiaX# < 0
craftInertiaX# = craftInertiaX# + craftDecel#
If craftInertiaX >= craftDecel# Then craftInertiaX# = 0
Else
craftInertiaX# = craftInertiaX# - craftDecel#
If craftInertiaX <= craftDecel# Then craftInertiaX# = 0
EndIf
EndIf
EndIf
If ikeyHitY = False
If craftInertiaY# <> 0
If craftInertiaY# < 0
craftInertiaY# = craftInertiaY# + craftDecel#
If craftInertiaY >= craftDecel# Then craftInertiaY# = 0
Else
craftInertiaY# = craftInertiaY# - craftDecel#
If craftInertiaY <= craftDecel# Then craftInertiaY# = 0
EndIf
EndIf
EndIf
; Craft Turbulance calculations.
craftTurbulance# = craftTurbulance# - craftTurbulanceRunOff#
If craftTurbulance# < 0 Then craftTurbulance# = 0
; Do shield stuff.
craftShieldAlpha# = craftShieldAlpha# - craftShieldAlphaRunOff#
If craftShieldAlpha# < 0 Then craftShieldAlpha# = 0
DoShields(craftShieldAlpha#,4)
; Move scenery. calculate speed here.
sceneSpeed# = ((0.4 + playerThrustZ#) - playerBrakeZ#)
UpdateScene(sceneSpeed#)
; PointEntity cCamera,mCraft
MoveMouse 200,200
UpdateWorld
; If EntityCollided(mRing,T_CRAFT)
; Text 0,0,"collided"
; EndIf
ent = EntityCollided(pCraft,T_RING)
; Collisions with the outer ring here.
If ent
EntityType ent,0
ResetEntity ent
; Work damage taken for hitting ring....
If playerShields# <= 0
craftTurbulance# = 6
Else
craftTurbulance# = 4
craftShieldAlpha# = craftShieldAlphaMax#
EndIf
; Work out shield damage.
If playerShields# <> 0
playerShields# = playerShields# - ringDamage#
If playerShields# < 0
; Take it off energy cos shields are down.
playerEnergy# = playerEnergy# - Abs(playerShields#)
playerShields# = 0
EndIf
Else
playerEnergy# = playerEnergy# - ringDamage#
PlaySound sDamage
If playerEnergy# <= 0
; Terminate Game
EndIf
EndIf
EndIf
ent = EntityCollided(pCraft,T_CENTER)
; Collisions with the inner part of the ring here.
If ent
EntityType ent,0
ResetEntity ent
; Work out score for passing thru the ring...
dist# = EntityDistance(mCraft,ent)
If dist# < 2
; Give big score bonus for hitting the ring very close to the center.
playerScore = playerScore + 500
PlaySound sRingBonus
Else
playerScore = playerScore + (100.0 / dist)
PlaySound sThruRing
EndIf
; Reposition and re-update.
PositionEntity pCraft,craftX#,craftY#,sceneZ# + craftZ#
UpdateWorld
EndIf
RenderWorld
mph# = (sceneSpeed# * 300.0)+(Cos(deg#)*(sceneSpeed#*20)) - Abs(craftPitch#/5) - Abs(craftRoll#/5)
deg#=deg#+1.2
Text 0,0,"SCORE: " + Int(playerScore)
Text 0,15,"DISTANCE FROM CENTER OF RING: " + dist
Text 0,40,"THRUST: " + playerThrust + "/" + playerThrustMax
Text 0,55,"BRAKE: " + playerBrake + "/" + playerBrakeMax
Text 0,70,"SHIELDS: " + Int(playerShields#) + "/" + Int(playerShieldsMax#)
Text 0,95,"ENERGY: " + Int(playerEnergy#) + "/" + Int(playerEnergyMax#)
Text 0,110,"SPEED: " + Int(mph#) + " mph"
Text 0,200,"BULLETS ON SCREEN: " + temp
temp = 0
ikeyHitX = False
ikeyHitY = False
Flip
Until KeyDown(1)
End
Function UpdateScene(amount#)
; Move the floor
fRot1# = fRot1# + 3
PositionEntity mFloor1,(Sin(fRot1#)*1.2)+craftX#,-21,(Cos(fRot1#)*2.9)+craftZ#
PositionEntity mFloor2,-(Sin(fRot1#)*3.0)+craftX#,-22,-(Cos(fRot1#)*1.1)+craftZ#
; Move the sky
PositionEntity mSky1,(Sin(fRot1#)*1.2)+craftX#,21,(Cos(fRot1#)*2.9)+craftZ#
PositionEntity mSky2,-(Sin(fRot1#)*3.0)+craftX#,22,-(Cos(fRot1#)*1.1)+craftZ#
; Update scene position
sceneZ = sceneZ + amount#
; Calculate craft tilt.
craftRoll# = -(craftInertiaX#*100)
craftPitch# = -(craftInertiaY#*100)
If craftRoll# > craftRollMax#
craftRoll# = craftRollMax#
ElseIf craftRoll# < -craftRollMax#
craftRoll# = -craftRollMax#
EndIf
If craftPitch# > craftPitchMax#
craftPitch# = craftPitchMax#
ElseIf craftPitch# < -craftPitchMax#
craftPitch# = -craftPitchMax#
EndIf
turbPitch# = Rnd(-craftTurbulance#,craftTurbulance#)
turbYaw# = Rnd(-craftTurbulance#,craftTurbulance#)
turbRoll# = Rnd(-craftTurbulance#,craftTurbulance#)
; Tilt it!
newCPitch# = craftPitch#+(Sin(craftWobble#)*3)+turbPitch#
newCYaw# = craftRoll#+turbYaw#
newCRoll# = craftRoll#+(Cos(craftWobble#)*15)+turbRoll#
RotateEntity pCraftIn,newCPitch#,newCYaw#,newCRoll#
craftWobble# = craftWobble# + 1
; Move the craft.
craftX# = craftX# + craftInertiaX#
craftY# = craftY# + craftInertiaY#
PositionEntity pCraft,craftX#,craftY#,sceneZ# + craftZ#
; Move the camera.
PositionEntity cCamera,EntityX(pCraft)/1.5,EntityY(pCraft)/1.5,sceneZ
RotateEntity cCamera,turbPitch#/6,turbYaw#/6,turbRoll#/6
; Do stuff.
DoFlame()
DoRings()
DoBullets()
; Update the flame.
flameCountFrame = flameCountFrame + 1
If flameCountFrame > newflameAfterFrames
j = Rnd(100)
; Calculate the size of the flame, larger if there is thrust, smaller if there is brake.
flameNewSize# = (flameNormalSize# + ((playerThrustZ# / playerThrustZMax#) * playerFSThrstMax#)) - ((playerBrakeZ# / playerBrakeZMax#) * playerFSBrakeMax#)
If j > 50
CreateNewFlame(sFlame1,0.0000001,.000008,flameNewSize#)
Else
CreateNewFlame(sFlame2,0.0000001,.000008,flameNewSize#)
EndIf
flameCountFrame = 0
EndIf
End Function
Function Setup()
cCamera = CreateCamera()
CameraRange cCamera,1,300
CameraFogMode cCamera,1
CameraFogRange cCamera,1,300
CameraFogColor cCamera,0,0,0
light = CreateLight()
; Create the ring.....
pRing = CreatePivot()
mRing = LoadMesh(dObjs$ + "mainring.x",pRing)
mCent = LoadMesh(dObjs$ + "maincent.x",pRing)
NameEntity mRing,"ring"
NameEntity mCent,"center"
EntityAlpha mCent,0
EntityType mCent,T_CENTER
EntityType mRing,T_RING
tRing = LoadTexture(dGfx$ + "ring.bmp")
EntityTexture mRing,tRing
; tCent = LoadTexture(dGfx$ + "central.bmp")
; EntityTexture mCent,tCent
; TextureBlend tCent,1
sLamp = LoadSprite(dGfx$ + "lamp.bmp",1,pRing)
ScaleSprite sLamp,3,3
sLam2 = CopyEntity(sLamp,pRing)
NameEntity sLamp,"lamp1"
NameEntity sLam2,"lamp2"
MoveEntity sLamp,14.5,0,0
MoveEntity sLam2,-14.5,0,0
MoveEntity pRing,0,0,50
HideEntity pRing
; Create ship
pCraft = CreatePivot()
pCraftIn = CreatePivot(pCraft)
mCraft = LoadMesh("craft1.x",pCraftIn)
ScaleEntity mCraft,.08,.08,.08
EntityType pCraft,T_CRAFT
pWeaponPoint1 = CreatePivot(pCraftIn)
MoveEntity pWeaponPoint1,-2,0,20
pWeaponPoint2 = CreatePivot(pCraftIn)
MoveEntity pWeaponPoint2,2,0,20
; MoveEntity pCraft,0,0,15
; Create Ships' Shields.
mShields = CreateSphere(7,pCraftIn)
ScaleEntity mShields,3.5,1.5,3.5
tShields = LoadTexture(dGfx$ + "shields.bmp")
EntityTexture mShields,tShields
EntityAlpha mShields,.3
MoveEntity mShields,0,-.3,.5
mShields2 = CreateSphere(7,pCraftIn)
ScaleEntity mShields2,3.4,1.4,3.4
EntityTexture mShields2,tShields
MoveEntity mShields2,0,-.3,.5
; Setup the ship flame
pFlamePoint = CreatePivot(pCraftIn)
MoveEntity pFlamePoint,0,0,-4
sFlame1 = LoadSprite(dGfx$ + "flame1.bmp",1,pCraftIn)
sFlame2 = LoadSprite(dGfx$ + "flame2.bmp",1,pCraftIn)
MoveEntity sFlame1,0,0,-2.2
MoveEntity sFlame2,0,0,-2.2
HideEntity sFlame1
HideEntity sFlame2
; Load sound FX
sThruRing = LoadSound(dSnd$ + "toot.wav")
sRingBonus = LoadSound(dSnd$ + "bonus.wav")
sDamage = LoadSound(dSnd$ + "damage.wav")
; Setup the weapons
weaponList(0) = New tWeapon
weaponList(0)\name$ = "Sparktronic-Protoblogterfier"
weaponList(0)\sound = LoadSound(dSnd$ + "bullet1.wav")
weaponList(0)\ent = LoadSprite(dGfx$ + "bullet1.bmp",1,pCraftIn)
weaponList(0)\vanishdist# = 500
ScaleSprite weaponList(0)\ent,1.4,1.4
MoveEntity weaponList(0)\ent,-2,0,4
HideEntity weaponList(0)\ent
weaponList(0)\strength# = 5
weaponList(0)\ammomax = 200
weaponList(0)\ammo = 200
weaponList(0)\speed# = 4
weaponList(0)\rotspeed# = 10
; Setup the ground:
mFloor1 = CreatePlane(3)
tFloor1 = LoadTexture(dGfx$ + "lava3.bmp")
ScaleTexture tFloor1,30,30
EntityTexture mFloor1,tFloor1
EntityAlpha mFloor1,.3
mFloor2 = CreatePlane(3)
EntityTexture mFloor2,tFloor1
EntityAlpha mFloor2,.6
TurnEntity mFloor2,0,90,0
EntityOrder mFloor2,2
EntityOrder mFloor1,1
; Setup the sky:
mSky1 = CreatePlane(3)
tSky1 = LoadTexture(dGfx$ + "marblate1.bmp")
tSky2 = LoadTexture(dGfx$ + "marblate1.bmp")
ScaleTexture tSky1,20,20
ScaleTexture tSky2,20,20
EntityTexture mSky1,tSky1
EntityAlpha mSky1,.3
mSky2 = CreatePlane(3)
EntityTexture mSky2,tSky2
EntityAlpha mSky2,.9
RotateEntity mSky1,0,0,180
RotateEntity mSky2,0,90,180
EntityOrder mSky2,2
EntityOrder mSky1,1
End Function
Function CreateNewFlame(flameent,speed#,untildist#,scale#)
Local tempFlame.tFlame = New tFlame
Local rn1#,rn2#
tempFlame\obj = CopyEntity(flameent)
RotateEntity tempFlame\obj,Rnd(0,359),Rnd(0,359),Rnd(0,359)
PositionEntity tempFlame\obj,EntityX(pCraft),EntityY(pCraft),EntityZ(pCraft)
PointEntity tempFlame\obj,pFlamePoint
rn1# = Rnd(-.2,.2)
rn2# = Rnd(-.2,.2)
MoveEntity tempFlame\obj,rn1,rn2,2.2 ; jiggle it a little.
ShowEntity tempFlame\obj
If scale <> 1 Then ScaleSprite tempFlame\obj,scale,scale
tempFlame\speed = speed
tempFlame\untildist = untildist
tempFlame\prescale = (tempFlame\speed / tempFlame\untildist)
tempFlame\scaledown = scale
tempFlame\alphacn = 1.0 / (tempFlame\untildist / tempFlame\speed)
tempFlame\alphadown = 1
End Function
Function DoFlame()
Local tempFlame.tFlame
For tempFlame = Each tFlame
MoveEntity tempFlame\obj,0,0,tempFlame\speed
tempFlame\scaledown = tempFlame\scaledown - (tempFlame\prescale*4)
ScaleSprite tempFlame\obj,tempFlame\scaledown#,tempFlame\scaledown#
EntityAlpha tempFlame\obj,tempFlame\scaledown#
; RotateSprite tempFlame\obj,Rnd(0,360)
If tempFlame\scaledown# < 0.05
FreeEntity tempFlame\obj
Delete tempFlame
Else
tempFlame\alphadown = tempFlame\alphadown - tempFlame\alphacn
EntityAlpha tempFlame\obj,tempFlame\alphadown
tempFlame\count = tempFlame\count + tempFlame\speed
If tempFlame\count > tempFlame\untildist
FreeEntity tempFlame\obj
Delete tempFlame
EndIf
EndIf
Next
End Function
Function CreateNewRing.tRing(x#,y#,z#,pitch#,yaw#,roll#,r,g,b)
Local tempRing.tRing = New tRing
tempRing\x = x
tempRing\y = y
tempRing\z = z
tempRing\pitch = pitch
tempRing\yaw = yaw
tempRing\roll = roll
tempRing\ePivot = CopyEntity(pRing)
tempRing\eRing = GetChild(tempRing\ePivot,1)
tempRing\eCenter = GetChild(tempRing\ePivot,2)
tempRing\eFlare1 = GetChild(tempRing\ePivot,3)
tempRing\eFlare2 = GetChild(tempRing\ePivot,4)
MoveEntity tempRing\ePivot,x,y,z
ShowEntity tempRing\ePivot
If (r Or g Or b) <> -1 Then EntityColor tempRing\eRing,r,g,b
Return tempRing
End Function
Function DoRings()
Local tempRing.tRing
For tempRing = Each tRing
TurnEntity tempRing\ePivot,tempRing\pitch,tempRing\yaw,tempRing\roll
Next
End Function
Function DoShields(alph#,turnspeed#)
EntityAlpha mShields,alph#
EntityAlpha mShields2,alph#
TurnEntity mShields,0,turnspeed#,0
TurnEntity mShields2,0,-turnspeed#,0
End Function
Function AddWeaponFire(weapon)
tempBullet1.tBullet = CreateBullet(weapon,EntityX(pCraft)-2,EntityY(pCraft),EntityZ(pCraft)+4,pWeaponPoint1)
tempBullet2.tBullet = CreateBullet(weapon,EntityX(pCraft)+2,EntityY(pCraft),EntityZ(pCraft)+4,pWeaponPoint2)
PlaySound weaponList(weapon)\sound
End Function
Function CreateBullet.tBullet(weapon,x#,y#,z#,weaponpoint)
tempBullet.tBullet = New tBullet
tempBullet\weapon = weapon
tempBullet\ent1 = CopyEntity(weaponList(weapon)\ent)
PositionEntity tempBullet\ent1,x#,y#,z#
PointEntity tempBullet\ent1,weaponpoint
EntityAutoFade tempBullet\ent1,1,weaponList(weapon)\vanishdist#
Return tempBullet
End Function
Function DoBullets()
For tempBullet.tBullet = Each tBullet
MoveEntity tempBullet\ent1,0,0,weaponList(tempBullet\weapon)\speed#
RotateSprite tempBullet\ent1,tempBullet\rot#
tempBullet\rot# = tempBullet\rot# + weaponList(tempBullet\weapon)\rotspeed#
If EntityDistance(pCraft,tempBullet\ent1) > weaponList(tempBullet\weapon)\vanishdist#
FreeEntity tempBullet\ent1
Delete tempBullet
EndIf
temp = temp + 1
Next
End Function
Binary file not shown.

After

Width:  |  Height:  |  Size: 192 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 192 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 192 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 192 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 192 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 24 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 48 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 192 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 48 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 48 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 192 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 192 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 MiB

Some files were not shown because too many files have changed in this diff Show More