//-----------------------------------------------------------------------------------
// Bismillahirrahmanirrahim  
//-----------------------------------------------------------------------------------
//																					|
//               MOS 2D Engine ( MEYDANERİ OpenGL Software Engine)					|
//																				    |
// ----------------------------------------------------------------------------------
//    Yapimci = Vedat Meydaneri														|
//     email = Chenmy1@yahoo.com													|
//     web = www.turkop.cjb.net														|
//-----------------------------------------------------------------------------------
// MOS 2D Engine (Vedat Meydaneri ) - Olusturma tarihi :10/ Temmuz /2003 saat: 15:00 |
//************************************************************************************
//************************************************************************************
//************************************************************************************
//------------------------------------------------------------------------------------  



#ifndef __MOSTEMP_H__
#define __MOSTEMP_H__


#include <stdio.h>		
#include <gl\glaux.h>
#include <windows.h>
#include <windowsx.h>
#include <mmsystem.h>
#include <stdio.h>
#include <gl\gl.h>
#include <gl\glu.h>
#include <dshow.h>
#include <glext.h>

#define MOS2DALL
#include <mos2d.h>
#include <mosresim.h>
#include <mosfont.h>
#include <mossprite.h>
#include <mosbutton.h>
#include <dsound.h>


#include <Mossound.h>



extern MOSEkran pencere;
extern CDXInput Input;
extern MOSResim resim;
extern MOSButton button;



enum SOUNDS
{
	SOUND_SALLA,
	SOUND_TOP,
	SOUND_YAN,
	SOUND_UST,
	SOUND_PATLA,
	SOUND_SOPA,
	SOUND_MAX
};

enum
{
	PS_BOS,
	PS_OYUN,
	PS_MENU,
	PS_SKOR,
	PS_RESETGAME,
	PS_SEC,
	PS_KAZAN,
	PS_KAYBET,
	PS_KAYIT,
	PS_RELOAD,
	PS_SALLA,

};

enum HITS
{
	HIT_TOP = 1,
	HIT_BOTTOM,
	HIT_LEFT,
	HIT_RIGHT,
	HIT_X,
	HIT_Y,
	NO_HIT,
};

//Objeler
#define OYUNAG      2
#define KUCUL       3
#define ASAGI_GIT       4
#define PATLA 5
#define CANLI       1
#define CANSIZ    0
#define BOS     -1

//Duvar turleri


//Sprites list sadece
#define TYPE_TOP 1

//Duvar sprites list sadece
#define TYPE_DUVAR 2

#define TYPE_EFEK 1



//Klavye CPP icindekiler
extern void Klavye();
extern LONG mx,my;


extern DWORD Ps;

//Sprite Ciz

extern void Spritelariciz();


//Spriteinit icindekiler
extern MOSSprite mouse;
extern MOSSprite logo;
extern MOSSprite lava;
extern MOSSprite lava2;
extern MOSSprite arka;
extern MOSFont font;
extern MOSSprite top;
extern MOSSprite sopa;
extern MOSSprite player;
extern MOSSprite efek;
extern MOSSprite menus;

extern MOSSprite arka2;

extern void Spriteinit();
extern MOSTile *duvartile;
extern MOSTile *exp2tile;

//Oyun icindeki

extern void Oyun();
extern void OyunYazi();
extern void OyunKlavye();
extern void ResetGame();
extern bool reload();

//Node duvar
extern void sprite_ekle_Duvar(MOSTile *tile,int type,int x,int y,int state,int frame,int delay);
extern void sprite_ekle_Duvar_renk(MOSTile *tile,int type,int x,int y,int state,int frame,int delay,float r,float g,float b);
extern void Sprites_Update_Duvar(DWORD drawturu,bool blend,bool mask);
extern MOSSpriteList DuvarSprites;

//Efek
extern void Sprites_Update_Efek(DWORD drawturu,bool blend,float hiz);
extern MOSSprite * s3;
extern MOSSpriteList EfekSprites;

extern void sprite_ekle_efek(MOSTile *tile,int type,int x,int y,int state,int frame,int delay);
//Sesler
extern IGraphBuilder *pGraph;             // filter graph için 
extern IMediaControl *pMediaControl;      //Data flow kontrolü için  filter graph tan geçen data
extern IMediaEvent   *pMediaEvent;        //Event handling 


#define SOUND_MAX 100

extern CDXSound *Sound;
extern CDXSoundBuffer *Sounds[SOUND_MAX];

extern void Dsoundkaldir();
extern BOOL Dsoundinit(void);
extern void LoopSes();




#endif