Comments for Pern Tools http://pern.drunkencoders.com Just another Drunken Coders weblog Wed, 27 Mar 2013 09:53:16 +0000 hourly 1 http://wordpress.org/?v=3.5.1 Comment on Pern Bug Reports by dovotohttp://pern.drunkencoders.com/pern-bug-reports/comment-page-1/#comment-21607 dovoto Wed, 27 Mar 2013 09:53:16 +0000 http://pern.drunkencoders.com/?page_id=238#comment-21607 Okay, couple of things.

First, there is no need to include the .c file on line 8. The .c file will be compiled simply by placing it in your source directory.

Second, your .h file is missing both the graphics and the palette and looking at your grit export options above I can see that your “Tiles” and “Palette” options are set to “none”.

I am actually on a fresh computer here so I downloaded and installed the map editor and created a map named “Dungeon” with a single layer map called “Floor”.

After setting my path to grit.exe in the Tools->Configuration->PathToGrit to “C:\devkitPro\devkitARM\bin\grit.exe” and then choosing export using GRIT and then all default options (except I checked the .c as apposed to .asm box) I get a header and a c file that contain a map, tile graphics, and a palette.

Is this roughly the process you followed to create your .c and .h file?

Finally, your use of dma to copy in the necessary components of the map is somewhat off. You need to copy three separate parts to make your map:

Assuming you have initialized a background layer as follows:

	
//           bgInit(layer index, type, size, map offset, tile offset)
int layer0 = bgInit(2, BgType_Text8bpp, BgSize_T_256x256, 0, 1);

First, the maps tile graphics must be copied into background tile memory:

//         source,           destination,            length
dmaCopy(DungeonSharedTiles, bgGetGfxPtr(layer0), DungeonSharedTilesLen);

Then, the palette needs copied in:

dmaCopy(DungeonSharedPal, BG_PALETTE, DungeonSharedPalLen); 

Finally, you need to copy in the map itself:

dmaCopy(FloorMap, bgGetMapPtr(layer0), FloorMapLen);

(the actual order you do these copies is not important only that all three are completed).

If this did not clear it up then there likely is a bug. If it did then I really need to install a forum :)

]]>
Comment on Pern Bug Reports by shoyrumaster11http://pern.drunkencoders.com/pern-bug-reports/comment-page-1/#comment-21606 shoyrumaster11 Wed, 27 Mar 2013 06:26:19 +0000 http://pern.drunkencoders.com/?page_id=238#comment-21606 Here the codes are, Dovoto:

http://www.drunkencoders.com/pastebin/p/CkAVtb.html

]]>
Comment on Pern Bug Reports by dovotohttp://pern.drunkencoders.com/pern-bug-reports/comment-page-1/#comment-21605 dovoto Tue, 26 Mar 2013 09:32:07 +0000 http://pern.drunkencoders.com/?page_id=238#comment-21605 I dont suppose you could paste the main.c file on http://www.drunkencoders.com/pastebin ?

And the .h file…

It would help. Hopefully we can get this thing straitened out.

]]>
Comment on Pern Bug Reports by shoyrumaster11http://pern.drunkencoders.com/pern-bug-reports/comment-page-1/#comment-21604 shoyrumaster11 Tue, 26 Mar 2013 05:51:48 +0000 http://pern.drunkencoders.com/?page_id=238#comment-21604 The errors don’t directly happen to the .c and .h files I mentioned, but my main.c file and here they are:

MAIN.C errors:

warning: passing argument 1 of ‘dmaCopy’ makes pointer from integer without a cast [enabled by default]
In file included from c:/devkitPro/libnds/include/nds.h:233:0,
note: expected ‘const void *’ but argument is of type ‘int’
error: ‘Layer_1Pal’ undeclared (first use in this function)
note: each undeclared identifier is reported only once for each function it appears in
warning: implicit declaration of function ‘scroll’ [-Wimplicit-function-declaration]

]]>
Comment on Pern Bug Reports by dovotohttp://pern.drunkencoders.com/pern-bug-reports/comment-page-1/#comment-21603 dovoto Mon, 25 Mar 2013 10:03:18 +0000 http://pern.drunkencoders.com/?page_id=238#comment-21603 hmm, ill take a look at this. Can you tell me what error the c and h files are giving you with any more detail?

]]>
Comment on Pern Bug Reports by shoyrumaster11http://pern.drunkencoders.com/pern-bug-reports/comment-page-1/#comment-21600 shoyrumaster11 Sat, 23 Mar 2013 22:55:23 +0000 http://pern.drunkencoders.com/?page_id=238#comment-21600 Whenever I try use use the GRIT compiler with this software, my .h and .c files do not compile properly (incomplete .h and missing .c files) and when I try to click export grit script, the following message appears:

“export script not supported currently” this appears TWICE.

My GRIT export settings: Map=All, Layer=All, Map=None, Tiles=None, Palette=None, exported as a .c and 8 bit index is turned off.

]]>
Comment on screenshots and features wiz by dovotohttp://pern.drunkencoders.com/screenshots-and-features-wiz/comment-page-1/#comment-21467 dovoto Wed, 13 Mar 2013 13:53:27 +0000 http://pern.drunkencoders.com/?page_id=31#comment-21467 I had noticed that issue as well (it doesn’t seem to affect the full version of visual studio). If you are using express 2k12 then it seems to be missing something from 2k8/10 that normally allows it to work. I should look into it.

]]>
Comment on screenshots and features wiz by Lucashttp://pern.drunkencoders.com/screenshots-and-features-wiz/comment-page-1/#comment-21399 Lucas Tue, 12 Mar 2013 02:38:05 +0000 http://pern.drunkencoders.com/?page_id=31#comment-21399 I tried changing the version to 11.0 for Visual Express 2012 for Windows 8 and it doesn’t recognize it the template. I had to install Visual Express 2008 or 2010. Anybody else having this problem and know any solutions?

]]>
Comment on screenshots and features wiz by dovotohttp://pern.drunkencoders.com/screenshots-and-features-wiz/comment-page-1/#comment-10300 dovoto Mon, 03 Sep 2012 00:49:18 +0000 http://pern.drunkencoders.com/?page_id=31#comment-10300 Thanks, havnt had a chance to try it out on VS 2012 yet. Good to see its still working

]]>
Comment on screenshots and features wiz by ILOVEPIEhttp://pern.drunkencoders.com/screenshots-and-features-wiz/comment-page-1/#comment-10298 ILOVEPIE Sun, 02 Sep 2012 21:58:57 +0000 http://pern.drunkencoders.com/?page_id=31#comment-10298 This is how you convert it to different visual studio versions:

Visual Studio 2005:
– VsWizard.VsWizardEngine.8.0
Visual Studio 2008:
– VsWizard.VsWizardEngine.9.0
Visual Studio 2010:
– VsWizard.VsWizardEngine.10.0
Visual Studio 2012 and Visual Studio 11 Beta:
– VsWizard.VsWizardEngine.11.0

]]>