Code (Text): [4A] image=../Images/Pach/E6.png offset=-32,-32 [E6] image=../Images/Pach/E6.png offset=-8,-8 [E7] image=../Images/Pach/E6.png offset=-8,-8 [EC] image=../Images/Pach/EC.png offset=-32,-32 [ED] image=../Images/Pach/ED.png offset=-8,-8 SonLvl gives me an error when I try to open a level after editing the obj.ini Code (Text): Opening INI file "D:\Emulation\Gens\Sonic Retro Disassemblies\MegaDrive\Sonic & Knuckles Split Disassembly - Copy\S3KLVL INI Files\S3KLVL.ini"... Game type is S3K. Loading Angel Island Zone Act 1... Loading 8x8 tiles from file "../Levels/AIZ/Tiles/Act 1 Primary.bin", using compression KosinskiM... Loading 8x8 tiles from file "../Levels/AIZ/Tiles/Act 1 Main Level.bin", using compression KosinskiM... Loading 16x16 blocks from file "../Levels/AIZ/Blocks/Act 1 Primary.bin", using compression Kosinski... Loading 16x16 blocks from file "../Levels/AIZ/Blocks/Act 1 Main Level.bin", using compression Kosinski... Loading 128x128 chunks from file "../Levels/AIZ/Chunks/Act 1.bin", using compression Kosinski... Loading layout from file "../Levels/AIZ/Layout/1.bin", using compression Uncompressed... Loading palette file "../General/Sprites/Sonic/Palettes/SonicAndTails.bin"... Source: 0 Destination: 0 Length: 16 Loading palette file "../Levels/AIZ/Palettes/Main.bin"... Source: 0 Destination: 16 Length: 48 Loading palette file "../Levels/AIZ/Palettes/Water.bin"... Source: 0 Destination: 0 Length: 64 Loading object definition file "obj.ini". Loading S3K Ring Definition... Loading ObjectDefinition type S3KObjectDefinitions.Common.Monitor from "Common\Monitor.cs"... Loading type from cached assembly "dllcache\S3KObjectDefinitions.Common.Monitor.dll"... Loading ObjectDefinition type S3KObjectDefinitions.Common.PathSwapper from "Common\PathSwapper.cs"... Loading type from cached assembly "dllcache\S3KObjectDefinitions.Common.PathSwapper.dll"... System.ArgumentException: Value does not fall within the expected range. at SonicRetro.SonLVL.BitmapBits..ctor(Bitmap bmp) in C:\RetroSVN\Programs\SonLVL\SonLVL\BitmapBits.cs:line 49 at SonicRetro.SonLVL.DefaultObjectDefinition.Init(Dictionary'2 data) in C:\RetroSVN\Programs\SonLVL\SonLVL\ObjectDefinition.cs:line 91 at SonicRetro.SonLVL.MainForm.LoadObjectDefinitions(String file) in C:\RetroSVN\Programs\SonLVL\SonLVL\MainForm.cs:line 3527 at SonicRetro.SonLVL.MainForm.backgroundWorker1_DoWork(Object sender, DoWorkEventArgs e) in C:\RetroSVN\Programs\SonLVL\SonLVL\MainForm.cs:line 828 From the log.
I used Photoshop to make the icons. By another sprite, I did something like this. [EC] art=../General/Sprites/SS Entry/Entry Ring.bin artcmp=Uncompressed mapasm=../General/Sprites/SS Entry/Map - Entry Ring.asm dplcasm=../General/Sprites/SS Entry/DPLC - Special Stage Entry Ring.asm frame=8
Photoshop is probably optimizing the image by reducing it to 16 colors. Besides that, the image specifically needs to match the level's palette, so even if it did work, it'll be using colors from Sonic's palette line. The best way to make definitions is to just specify the art, mappings, palette, frame and optionally DPLCs.
Would using Paint work? Ha, got it to work. "The best way to make definitions is to just specify the art, mappings, palette, frame and optionally DPLCs. " So, would I go in the asm to do this? Or define it in the Obj.ini?
I go it work using IfranView. It was as what you said. Photoshop was saving them as automatic bitmap images. Most likely 16bit. "The best way to make definitions is to just specify the art, mappings, palette, frame and optionally DPLCs. " So, would I go in the asm to do this? Or define it in the Obj.ini?
How would I defined the palette so that it fits the stage? Do I have to look the the asm? I see something like "Pal=1". Do I change this?
Using an image or mappings? For an image, you have to specifically choose palette indexes to match the level (extract the palette as a PNG to help), for mappings change the pal number from 0 to 3 until it works.
I forgot to fix the saving when I fixed the loading earlier. I also added object definitions for the invisible objects and the bumper in the Pachinko bonus. Everything else uses art from the middle of an art file.
is there any special condition for importing art? I've tried to replace a random chunk with custom art from another stage and didn't seem to work, it doesn't load the image at all (it was a transparent png I made in PS)
It has to be a multiple of the size of the type of data you're importing, it has to be BMP, PNG, GIF or JPG, it can't use premultiplied alpha values (it probably doesn't), and you can only have 256 chunks. If all that's okay it should add it to the end of the list.