Messages récents

#81
PVSnesLib English section / Re : Sprite between two Backgr...
Dernier message par faeldaniel - 28 Janvier 2013 à 21:32:41
I came to another conclusion, in example "Transparency" I changed the code default for:


      // Initialize SNES
consoleInit();

// Copy tiles to VRAM
bgInitTileSet(0, &LandTiles, &LandPalette, 1, (&LandTiles_end - &LandTiles), (&LandPalette_end - &LandPalette), BG_16COLORS, 0x0000);
bgInitTileSet(1, &CloudTiles, &CloudPalette, 0, (&CloudTiles_end - &CloudTiles), (&CloudPalette_end - &CloudPalette),  BG_4COLORS, 0x1000);

// Copy Map to VRAM
bgInitMapSet(0, &Maps, (&Maps_end - &Maps),SC_32x32, 0x2000);
bgInitMapSet(1, &Mapsc, (&Mapsc_end - &Mapsc),SC_32x32, 0x2400);

// Now Put in 16 color mode and put cloud on top of screen
setMode(BG_MODE1, BG3_MODE1_PRORITY_HIGH); bgSetDisable(2); 

// Set BG3 SubScreen and
bgSetEnableSub(1);

// enable Subscreen Color ADD/SUB and Color addition on BG1 and Backdrop color
setColorEffect(CM_SUBBGOBJ_ENABLE, CM_MSCR_BACK | CM_MSCR_BG1);




its working normally, BG1 front in BG0, but coment this parte the code:


      // Initialize SNES
consoleInit();

// Copy tiles to VRAM
bgInitTileSet(0, &LandTiles, &LandPalette, 1, (&LandTiles_end - &LandTiles), (&LandPalette_end - &LandPalette), BG_16COLORS, 0x0000);
bgInitTileSet(1, &CloudTiles, &CloudPalette, 0, (&CloudTiles_end - &CloudTiles), (&CloudPalette_end - &CloudPalette),  BG_4COLORS, 0x1000);

// Copy Map to VRAM
bgInitMapSet(0, &Maps, (&Maps_end - &Maps),SC_32x32, 0x2000);
bgInitMapSet(1, &Mapsc, (&Mapsc_end - &Mapsc),SC_32x32, 0x2400);

// Now Put in 16 color mode and put cloud on top of screen
setMode(BG_MODE1, BG3_MODE1_PRORITY_HIGH); bgSetDisable(2); 

// Set BG3 SubScreen and
//bgSetEnableSub(1);

// enable Subscreen Color ADD/SUB and Color addition on BG1 and Backdrop color
//setColorEffect(CM_SUBBGOBJ_ENABLE, CM_MSCR_BACK | CM_MSCR_BG1);




The BG1 is behind BG0. I read something about "Main screen" and "Sub screen".

As in this example would be  BG0 in front of the BG1 without transparency in BG_MODE1? it is thus not:

..
bgInitTileSet(1, &LandTiles, &LandPalette, 1, (&LandTiles_end - &LandTiles), (&LandPalette_end - &LandPalette), BG_16COLORS, 0x0000);
bgInitTileSet(0, &CloudTiles, &CloudPalette, 0, (&CloudTiles_end - &CloudTiles), (&CloudPalette_end - &CloudPalette),  BG_4COLORS, 0x1000);

// Copy Map to VRAM
bgInitMapSet(1, &Maps, (&Maps_end - &Maps),SC_32x32, 0x2000);
bgInitMapSet(0, &Mapsc, (&Mapsc_end - &Mapsc),SC_32x32, 0x2400);
..


#82
PVSnesLib English section / Re : Sprite between two Backgr...
Dernier message par faeldaniel - 22 Janvier 2013 à 17:33:42
you refer to it?


while(1) {
...
...
if (move) bgSetScroll(0, scrX,scrY);

//this is refreshing oam memory?
oamSet(0,  mychar.x, mychar.y,  mychar.priority, mychar.direcionSpriter, 0, sprTiles[mychar.positionOffSetSpriter], 0);

WaitForVBlank();
}



In background mode 2
setMode(BG_MODE2,0);
work as I want

Layer 0
Sprite
Layer 1


but mode 2 only has two layers :'(, different mode 1 having three layers .
#83
PVSnesLib English section / Re : Sprite between two Backgr...
Dernier message par alekmaul - 22 Janvier 2013 à 07:24:25
Nope, no idea of that problem, will take a look when i will have time.
You're sure you're refreshing oam memory each time ?
#84
PVSnesLib English section / Re : Sprite between two Backgr...
Dernier message par faeldaniel - 21 Janvier 2013 à 03:31:30
I made many tests, discovered that this is a problem of lib, because I came to this conclusion? as you can see bgSet trees is 0, so in theory the sprite set as priority 1 would be in front from the trees.
When I start the sprite priority 0 or 1, the sprite is always behind the trees, look this code:


mychar.priority = 0;

//Init spite
oamInitGfxSet(&gfxpsrite, (&gfxpsrite_end - &gfxpsrite), &palsprite, 0, 0x0000, OBJ_SIZE32);
oamSet(0,  mychar.x, mychar.y,  mychar.priority, 0, 0, 0, 0);
oamSetEx(0, OBJ_LARGE, OBJ_SHOW);

//Init Map
bgInitTileSet(0, &patterns, &palette, 0, (&patterns_end - &patterns), 16*2, BG_16COLORS, 0x6000);
bgInitMapSet(0, &map, (&map_end - &map), SC_64x64, 0x5000);


Prints

mychar.priority = 0;


mychar.priority = 1;


but when put as priority 2 sprite goes to the front from the trees

mychar.priority = 2;



alekmaul have any idea what you can this happening?
#85
PVSnesLib English section / Re : Sprite between two Backgr...
Dernier message par faeldaniel - 17 Janvier 2013 à 03:01:35
Look this brothers:  ;D

http://www.youtube.com/watch?v=dWz7ZWBXdcU

The Graphics is bad  ;) , i am studying color palettes, however this to get an idea of what I intend to do, this case I'll add the character to stay behind the trees. In the future, with an awesome graphic artist, the game will have beautiful graphics.  ::)

I buy the Pier Solar for Sega Genesis saw how far we can get with dedication, the boss of the project is a Brazilian like myself.

alekmaul i loved Ultima, i have this game for Nes ;) i search this games for other consoles.

Waiting for that games too.
#86
Discussions Générales / Re : pstros:un emulateur java ...
Dernier message par alekmaul - 15 Janvier 2013 à 20:46:33
J'avais vu ça ? l'époque sur le site de davr, je sais pas si c'est tr?s exploitable ...  :-\
#87
PVSnesLib English section / Re : Sprite between two Backgr...
Dernier message par alekmaul - 15 Janvier 2013 à 20:44:54
Great, thanks , waiting for that.
Began to do a ultima3 RPG for NDS, perhaps will adapt it for SNES ^^
#88
Discussions Générales / pstros:un emulateur java mobil...
Dernier message par gego51 - 14 Janvier 2013 à 21:53:54
voici un émulateur qui lance des jeux de téléphone .jar

http://www.volny.cz/molej/pstrosnds/

vu qu'il date de 2008 et qu'il semble ?tre abandonné,il ne supporte pas l'ecran tactile ni le son,les jeux dont la résolution est supérieur a 176/224 se lancent mais sont injouables

pour l'installation: mettre le fichier kvm.nds et le dossier nds (qui est dans l'archive classe.zip) ? la racine de la carte sd

pour lancer les jeux : le jeu .jar doit ?tre avec son extension .jad n,importe ou dans la carte sd, s'il n'y a pas le .jad, il est possible de le générer avec jadmaker :

http://www.clubic.com/telecharger-fiche126212-jadmaker.html

(glisser le(s) .jar dans la fen?tre de jadmaker,il créé automatiquement le(s) jad au m?me endroit)

pour les programmeur, les sources sont téléchargeable avec le jeu
#89
PVSnesLib English section / Re : Sprite between two Backgr...
Dernier message par faeldaniel - 12 Janvier 2013 à 04:11:18
I want to develop a game rpg, this technique with sprites between bgs who would want to put trees on top of the sprite thus creating a depth effect, i will make new test with this idea and will post the results
#90
Discussions Générales / Re : emulateur gba sur ds: gba...
Dernier message par gego51 - 10 Janvier 2013 à 20:40:36
je ne sais pas trop mais thoduv avait essayer d'en faire un d'emu gba (tgba) mais il a abandonner et a mis les sources en ligne sur son blog.

son site http://thoduv.drunkencoders.com/

en faite bonne année