;========================================================
; Proyecto : Beta Centauro.
; Programador : Yue Rexie.
; Sitio Web : http://www.iris3d.tk.
; Empresa : Iris3D -Games Studios-© 2007-2012.
; Nombre Fichero : Inicio.bb.
;========================================================
; OBJETIVO FILE : Logos (Distribuidor-Desarrollador)
; : y precarga menu principal.
;========================================================
Local Version$ = "Demo v.1.0"
AppTitle Version$
Local R% ; Resolución.
R% = Buscar_MG(800,600,16) ; Modo gráfico temporal.
; Includes Especiales I
;========================================================
Include "Includes2\Draw3D2.bb" ; Efectos 2D.
Include "Includes2\DrawSGG.bb" ; Efectos GUI.
Include "Includes2\DrawXTD.bb"
Include "PackMachine.bb" ; Contenedor Recursos.
Include "Includes2\scancodes.bb" ; Constantes Teclado.
; Includes Generales.
;========================================================
Include "Includes\Constantes.bb" ; Constantes.
Include "Includes\Variables.bb" ; Variables.
Include "Includes\Funciones.bb" ; Funciones.
Ente% = PLoadImage%("IMG","Logo1",Ruta$) ; Logo Distribuidor.
HandleImage (Ente%,ImageWidth(Ente%)/2,ImageHeight(Ente%)/2); Centro de el Logo.
Crono% = MilliSecs() ; Inicia Cronometro.
; Buble Principal Logo Distribuidor.
;========================================================
While MilliSecs() < Crono% + 5000 ; 5 Segundos.
RenderWorld() ; Render Mundo.
DrawImage (Ente%,Ancho_P%/2,Alto_P%/2) ; Dibujado del Logo.
Flip() ; Se gira el Buffer.
; Salto del Logo.
If Salto%() = True And KeyDown(KEY_ESC%)=False
E_Tecla% = False
Exit
End If
Wend
Cls
RenderWorld
Flip
FreeImage(Ente%) ; Liberamos Imagen.
; Includes Especiales II
;========================================================
Include "includes2\BlitzAL.bb" ; OpenAL (Sonido-Música)
;Include "Includes2\FastExt.bb" ; Efectos Especiales.
;Include "Includes2\ShadowsMultiple.bb"
;Include "Includes2\FastImage.bb" ; Efectos 2D.
;Include "Includes2\h_lotus.bb" ; Sistema de partculas.
; Entidades.
;========================================================
Luz% = CreateLight() ; Luz%
Camara% = CreateCamera() ; Cámara.
Lente% = CreateCube(Camara%) ; Lente de la Cámara.
FlipMesh (Lente%) ; Caras Inversas.
EntityColor Lente%,0,0,0 ; Color del Lente.
CameraClsColor (Camara%,64,64,64) ; Color Fondo.
Ente% = PLoadMesh%("Models","Computador",Ruta$) ; Computador.
PositionEntity Ente%,0,-25,160 ; Posición Computador.
DrawInit3D(Camara%):DebugLog("Init Draw2") ; Init Draw2
alInitialise():DebugLog("Init OpenAL") ; Init OpenAL
Origin3D (800,600) ; Centro de Dibujado.
IMG% = PLoadImage3D("IMG","Gauss.Yue",Ruta$) ; Imagen Draw.
Font%=FontRange3D(PLoadImage3D("IMG","Font",Ruta$,2,2,0,-2)); Fuente Draw.
FlushFace3D(IMG%) ; Efecto Especial.
CreateFlakes4D(500,500,1,0.05)
AnimRifled4D(IMG%,0,0,-20, 0.2, 5)
Cine(IMG%,Ancho_P%,50,1) ; Efecto Cine.
Sound_Intro%=PalCreateSource(Ruta$,"Sounds","Goteo") ; Sonido Intro.
alSourceSetLoop(Sound_Intro,True)
alSourcePlay(Sound_Intro,False)
FadeIn%(Lente%,Time2%) ; Se aclara el Lente.
Crono% = MilliSecs() ; Reiniciamos Cronometro.
Time% = MilliSecs() - Periodo% ; Iniciamos Temporizador.
; Buble Principal Logo Desarrollador.
;========================================================
While MilliSecs() < Crono% + 5000 ; 5 Segundos.
Repeat : elapsed = MilliSecs() - Time : Until elapsed
ticks = elapsed / Periodo
Tween# = Float(elapsed Mod Periodo) / Float(Periodo)
For k=1 To ticks
Time = Time + Periodo
If k = ticks Then CaptureWorld
TurnEntity Ente%, 0,2.2,0
AnimRifled4D(IMG%,0,0,-20, 0.2, 5)
UpdateWorld
Next
Text3D(Font%,0,-250,"www.Iris3D.tk -Games Studios-",1,0,Sin(MilliSecs()))
Rect3D(IMG%,0,250,Ancho_P%,50,1) ; Banda Superior.
Rect3D(IMG%,0,-250,Ancho_P%,50,1) ; Banda Inferior.
alUpdate()
RenderWorld Tween#
Clear3D%()
Flip
; Salto Logo.
If Salto%() = True And KeyDown(KEY_ESC%)=False
E_Tecla% =False
Exit
End If
Wend
AnimRifled4D(IMG%,0,0,-20, 0.2, 5)
Cine%(IMG%,Ancho_P%,50,1) ; Efecto Cine.
FadeOut%(Lente%,Time2%) ; Se oscurce el Lente.
FreeEntity Ente% ; Liberamos Ente.
DrawFree3D() ; Cierre Draw2.
alDestroy() ; Finaliza OpenAL
EndGraphics() ; Finalizamos Gráficos.
End
Full Code.
|