Login [Register]
Don't have an account? Register now to chat, post, use our tools, and much more.
So, Kerm was helping me out with this sprite thing I'm working on, and then he went to bed. The sprites I'm trying to extract are in a plaintext file, so I was able to deduce some things. I realized that every four numbers made up a row (a row is 16 pixels, each number is a short, so four shorts makes 16 4-bit pixels). The sprites use a 16 color palette, and blah blah blah. At first I assumed that each nibble was in fact that corresponding pixel. I was wrong. Through Kerm's help I was able to get it to a point where we could actually get something that looks right. Turns out they are interlaced. With this handy bit of code:

Code:
a = (ushort)(((((ushort)s1 >> n) & 1) << 3) | ((((ushort)s2 >> n) & 1) << 2) | ((((ushort)s3 >> n) & 1) << 1) | ((((ushort)s4>>n) & 1)));

We were able to get the sprite to look almost right:


This is, as the title suggest, supposed to be a clover. It almost looks like one, just like it was drawn on a taurus or something. So, now the two final bits are getting the palette down, and getting that to look right. I'd like to do it in a nice, clean way, as opposed to going into the drawing code and changing that. Any suggestions?
Looks like it's shifted eight pixels to the left/right. But other than that, good work!
Right, and that's exactly the issue. I think I have a fix, though.
That code in the above post is in a simple for loop from 0 to 15, and makes the pixels in that row. So right now it looks like:

Code:
for (int n = 0; n < 16; n++) { ... }

If I change it to:

Code:
for (int m  = 8; m < 24; m++} {int n = m%16; ... }

I think it should give the effect of shifting the pixels over.
I don't have to code with me here, so I can't test, but Kerm knows what my code looks like. Get in here and confirm it for me Smile
That's exactly the fix that I was going to suggest for that, Merth. Nicely done. Smile

Yeah, look at that sweet clover.
That's awesome! What's next, figuring out how exactly the palettes are set up?
The palette is hard coded in, so it's either disassembling it (something I really don't have to will to do), or just using ZScreen's color picker and getting the right color. There're only 15 of them, and I've got 4 or 5 already down, so it's not too hard.
After that I'll add an simple editor to it, and an importer/exporter. Then a save game editor. At that point I'll release those two tools out to anyone who cares (probably not a whole lot) and then start working on my XNA port of the game.
merthsoft wrote:
The palette is hard coded in, so it's either disassembling it (something I really don't have to will to do), or just using ZScreen's color picker and getting the right color. There're only 15 of them, and I've got 4 or 5 already down, so it's not too hard.
After that I'll add an simple editor to it, and an importer/exporter. Then a save game editor. At that point I'll release those two tools out to anyone who cares (probably not a whole lot) and then start working on my XNA port of the game.
Nifty! Can you share what game this is yet?
Old QuickBasic game called MinerVGA. I used to play it like it was my job.
merthsoft wrote:
Old QuickBasic game called MinerVGA. I used to play it like it was my job.
Ah, fun stuff. I look forward to seeing how it turns out then, and I hope you'll post again if you have more issues that I can help with.
Alrighty, here's the released product:
http://merthsoft.calcg.org/MVSE.zip

If there's anyone of this forum that actually used to play this game or ever liked it, this might appeal to him. Otherwise, um. Oh well?
merthsoft wrote:
Alrighty, here's the released product:
http://merthsoft.calcg.org/MVSE.zip

If there's anyone of this forum that actually used to play this game or ever liked it, this might appeal to him. Otherwise, um. Oh well?
Well, it's something cool, and I helped with it, so I really have no reason not to try it out. Smile
http://www.beachnet.com/~hstiles/bin/minervga.zip
Here's the actual game. You'll need this. And probably DosBox.

Also, I released the editor on the Facebook fan page for the game, which was started by the creator himself! (I didn't know that when I first became a fan of it). Let's see what he thinks Very Happy!
*Bump* Moved to the "Your Projects" section.

Also, the creator of the game did get back to me saying he was quite impressed. We're now Facebook friends Smile
merthsoft wrote:
*Bump* Moved to the "Your Projects" section.

Also, the creator of the game did get back to me saying he was quite impressed. We're now Facebook friends Smile
That's awesome! Did he suggest any new features you could add, or offer to somehow integrate it with the game package?
He didn't, mostly because the game is a billion years old.
merthsoft wrote:
He didn't, mostly because the game is a billion years old.
Ah yes, I forgot about that part. Razz Too bad though, it's pretty impressive. I bet there might be some modern games to which it's applicable? Maybe not though.
  
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.

» Go to Registration page
Page 1 of 1
» All times are GMT - 5 Hours
 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum