View unanswered posts | View active topics It is currently Sun Apr 28, 2024 5:56 pm



Reply to topic  [ 1 post ] 
 Palette in MOPixel Form 
Author Message
User avatar

Joined: Sun May 31, 2009 1:04 am
Posts: 308
Reply with quote
Post Palette in MOPixel Form
Now that Grif has released his constructor, I feel okay with releasing this. This is a simple java program I wrote to create an MOPixel for each color in the palette. Who knows, someone might find their own use for this :P

The way it works is it reads in the data from palette.txt (generated by TLB's BMPToArray program), formats the data as MOPixels, and then spits them all out into MOPixelData.ini. All you have to do is copy this file over to your mod folder and add an include for it.

To use it, simply double click MOPixelMaker.jar and make sure palette.txt is in the same folder as the .jar file. However, I've already included an MOPixelData.ini, so that isn't necessary if you just want the .ini file.

Code:
//Sample generated MOPixel.  Base Pixel is also generated by the program.
AddAmmo = MOPixel
   CopyOf = Base Pixel
   PresetName = 32,8,56
   Color = Color
      R = 32
      G = 8
      B = 56


Each MOPixel's PresetName is the same as it's RGB colors, for easy referencing. Using these MOPixels, some lua scripting, and TLB's BMPToArray.exe (get it from Grif's constructor) you can draw anything in game.

I've also included the java source code, in case anyone is curious on how to write a program to do something like this. You'll need to find a java compiler, though, if you want to make your own program.


Attachments:
MOPixelMaker.rar [15.02 KiB]
Downloaded 176 times
Sat Dec 05, 2009 11:07 am
Profile
Display posts from previous:  Sort by  
Reply to topic   [ 1 post ] 

Who is online

Users browsing this forum: No registered users


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 post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by STSoftware for PTF.
[ Time : 0.105s | 16 Queries | GZIP : Off ]