Program GUI Thread
- Click16
- Posts: 1941
- Joined: Mon Dec 31, 2007 4:36 am
- Location: United States
Re: Program GUI Thread
Yeah its just a simple app, here's a short version of how it works: I get the Hue Saturation and Brightness values from a pixel, I then use those to calculate the color deficiencies hue, and use both the Brightness and Saturation to determine how saturated, dark, and light the color appears, and set the color of the pixel to the new value.
The hardest part about this, is that some of the colors that are 100% saturated for us appear desaturated, or darker when converted. This lead to some issues, but I managed to get most (if not all) of the bugs sorted out.
If any of you were wondering,
Protanopia (Pro - tan - opia) is Long Wavelength cone deficiency. Protanopes can't see see the red component in colors, therefor Cyan appears very light, like sort of off-white, Yellow and green are exactly the same, and purple and blue are hard to distinguish.
Deuteranopia (Due - ter - an - opia) is Medium Wavelength cone deficiency. Deuteranopes can't see the green component in colors.
Tritanopia (Try - tan - opia) is Short Wavelength cone deficiency. Trianopes can't see the blue component in colors.
It was a lot of fun to do research with my friend. Basically every time I test the program, I just ask "Click the button, and tell me if you notice the image change." and after a lot of trial and error, he finally can't tell that the images change. (At least when it's set to protanopia)
The hardest part about this, is that some of the colors that are 100% saturated for us appear desaturated, or darker when converted. This lead to some issues, but I managed to get most (if not all) of the bugs sorted out.
If any of you were wondering,
Protanopia (Pro - tan - opia) is Long Wavelength cone deficiency. Protanopes can't see see the red component in colors, therefor Cyan appears very light, like sort of off-white, Yellow and green are exactly the same, and purple and blue are hard to distinguish.
Deuteranopia (Due - ter - an - opia) is Medium Wavelength cone deficiency. Deuteranopes can't see the green component in colors.
Tritanopia (Try - tan - opia) is Short Wavelength cone deficiency. Trianopes can't see the blue component in colors.
It was a lot of fun to do research with my friend. Basically every time I test the program, I just ask "Click the button, and tell me if you notice the image change." and after a lot of trial and error, he finally can't tell that the images change. (At least when it's set to protanopia)
Last edited by Click16 on Fri Jan 16, 2015 10:18 pm, edited 3 times in total.
- NotZachary82
- Posts: 1846
- Joined: Thu Dec 20, 2007 8:39 pm
Re: Program GUI Thread
My dad has this
- DoorM4n
- Posts: 2154
- Joined: Sun Dec 09, 2007 3:01 am
- Location: Houston
- Click16
- Posts: 1941
- Joined: Mon Dec 31, 2007 4:36 am
- Location: United States
Re: Program GUI Thread
Decided to just use my free time to make a 2d Overworld game engine. As stated, this more or less an engine, so there isn't much to this other than making these "levels". Its more so just for fun than anything. Not really planning a full game on here, just want to put something together that works.
Oh, also, ignore the Pokémon overworld sprite, it's just a placeholder until I make my own.
Click for full-size images.
Map Maker:
In-game:
Its being programmed in MonoGame which is an Open Source implementation of Microsoft's XNA Framework.
Oh, also, ignore the Pokémon overworld sprite, it's just a placeholder until I make my own.
Click for full-size images.
Map Maker:
In-game:
Its being programmed in MonoGame which is an Open Source implementation of Microsoft's XNA Framework.
- troymac1ure
- Keeper of Entity
- Posts: 1282
- Joined: Sat Aug 09, 2008 4:16 am
- Location: British Columbia, Canada, eh
- Contact:
Re: Program GUI Thread
I think I made the exact same one in DOS years ago (except I had the tools on the right side). lol. I still have the world map depending on how you save yours
Always loved games like these. My actual game made it as far as being able to walk around the map and have others over LAN (IPX I think) walk on the same map. Never got around to building in code for towns or fighting though.
Always loved games like these. My actual game made it as far as being able to walk around the map and have others over LAN (IPX I think) walk on the same map. Never got around to building in code for towns or fighting though.
- CaptainPoopface
- Posts: 714
- Joined: Sat Feb 16, 2008 5:47 am
Re: Program GUI Thread
It looks like Legend of Zelda: A Link to the Past. Classic game. I don't understand the appeal of making a 2D world that will not be used... Just come up with some simple RPG construct. You have to interview everyone in the town to find where the cave is where the old man lives who can tell you where the mystic sword is buried that you must use to chop the enchanted vine that seals the bridge guarded by the angry troll who stands between you and the next castle.
- Click16
- Posts: 1941
- Joined: Mon Dec 31, 2007 4:36 am
- Location: United States
Re: Program GUI Thread
Well, used a lot of my existing code with Abide to start another project. Its a map builder. I hope to hard code all of the plugins to reduce the risk of error. Thankfully, JacksonCougar's plugins are mapped with padding alignment and max chunk sizes to make rebuilding the meta block easier. But who knows where this will go. I am just trying to get a map to rebuild from the decompiled state for right now.
- JacksonCougar
- Huurcat
- Posts: 2460
- Joined: Thu Dec 06, 2007 11:30 pm
- Location: Somewhere in Canada
Re: Program GUI Thread
one of us. one of us.
So how are you planning on decompiling and compiling the maps/assets anyways?
Have you had a look through my old Sunder code that did this stuff? You should take a look at it anyways because it has some useful things you need to make work for the map to load.
All in all it is pretty cool to see others still messing about with this kind of stuff
So how are you planning on decompiling and compiling the maps/assets anyways?
Have you had a look through my old Sunder code that did this stuff? You should take a look at it anyways because it has some useful things you need to make work for the map to load.
All in all it is pretty cool to see others still messing about with this kind of stuff
- Click16
- Posts: 1941
- Joined: Mon Dec 31, 2007 4:36 am
- Location: United States
Re: Program GUI Thread
So I am taking advantage of the BinaryFormatter class and creating nicely laid-out serializable classes. Here's what the program does in a nutshell
It creates a solution instance, adds ProjectFileReferences which tells it where to look for the project files. (This is similar to how Visual Studio does it if you ever looked at a solution file as a text doc)
In the project file, I specify an Enum for the Map Type, and compile a list of StringIDs. It loops through each IndexEntry and builds properly mapped meta reference, and checks for raw data blocks. It will create a "holder" for the raw types. It will grab the raw data appropriate for the class, and will grab the instances regardless of being internal or not (I do store the location for the compiler so you don't waste space, but you still have the option of localizing raw for overwriting purposes) All of the reference files store a copy of the original data, so if you fuck something up, or the compiler fails, it will default to the original, or you can revert the file by hand. (An appropriate warning, and an existing backup option is to be implemented)
So I have 2 problems right now, some lengths for the sound raw doesn't make sense, and since "ReadBytes(int length)" takes an int parameter and not an unsigned int or long value some sound raw doesn't get extracted. I'll show an example
Sound Raw Chunk 7
As you can see, that number is way too large to be a positive length (as a signed int32)
Also, I'm not sure how the Unicode stuff is handled... Like say you go to the Unicode Index in hex, how is that stuff read?
It creates a solution instance, adds ProjectFileReferences which tells it where to look for the project files. (This is similar to how Visual Studio does it if you ever looked at a solution file as a text doc)
In the project file, I specify an Enum for the Map Type, and compile a list of StringIDs. It loops through each IndexEntry and builds properly mapped meta reference, and checks for raw data blocks. It will create a "holder" for the raw types. It will grab the raw data appropriate for the class, and will grab the instances regardless of being internal or not (I do store the location for the compiler so you don't waste space, but you still have the option of localizing raw for overwriting purposes) All of the reference files store a copy of the original data, so if you fuck something up, or the compiler fails, it will default to the original, or you can revert the file by hand. (An appropriate warning, and an existing backup option is to be implemented)
So I have 2 problems right now, some lengths for the sound raw doesn't make sense, and since "ReadBytes(int length)" takes an int parameter and not an unsigned int or long value some sound raw doesn't get extracted. I'll show an example
Sound Raw Chunk 7
As you can see, that number is way too large to be a positive length (as a signed int32)
Also, I'm not sure how the Unicode stuff is handled... Like say you go to the Unicode Index in hex, how is that stuff read?
- Grimdoomer
- Admin
- Posts: 1835
- Joined: Sun Dec 09, 2007 9:09 pm
Re: Program GUI Thread
It looks like you have the offset and size switched. Your offset looks like a size and your size looks like an offset.
Don't snort the magic, we need it for the network.
- JacksonCougar
- Huurcat
- Posts: 2460
- Joined: Thu Dec 06, 2007 11:30 pm
- Location: Somewhere in Canada
Re: Program GUI Thread
Grim you should know this one lol... you did make the sound extractor after all. Click there is a 1 bit flag on the size value of the sound raw reference. It is a flag for true == WAV format, I think. So the solution would be to just mask the value to clip the MSBit
As for Unicode there is a reflexive in match globals (it might be in the tag root for all I know too) that has pointers to all the different Unicode tables (languages). These are linked by the unicode collection tag
As for Unicode there is a reflexive in match globals (it might be in the tag root for all I know too) that has pointers to all the different Unicode tables (languages). These are linked by the unicode collection tag
- Grimdoomer
- Admin
- Posts: 1835
- Joined: Sun Dec 09, 2007 9:09 pm
Re: Program GUI Thread
OH I completely forgot about the bit(ch). It's been a long time...JacksonCougar wrote:Grim you should know this one lol... you did make the sound extractor after all. Click there is a 1 bit flag on the size value of the sound raw reference. It is a flag for true == WAV format, I think. So the solution would be to just mask the value to clip the MSBit
As for Unicode there is a reflexive in match globals (it might be in the tag root for all I know too) that has pointers to all the different Unicode tables (languages). These are linked by the unicode collection tag
Don't snort the magic, we need it for the network.
- Click16
- Posts: 1941
- Joined: Mon Dec 31, 2007 4:36 am
- Location: United States
Re: Program GUI Thread
I'd like to know how you made those moonfish plugins jackson. I am converting them to C# types for building / decompiling. I'm finding the "maxelement" and "padalign" attributes to be infinitely useful .
Heres a sample of what one of my plugins looks like in C#
http://pastebin.com/SYUJTzL4
I had to use a handful of XZodia's plugins for the ones you didn't convert, and I would like to know how you got the info such as the pad alignment and max count. Unless you figured all of that through trial and error, but that seems a little insane xD
Heres a sample of what one of my plugins looks like in C#
http://pastebin.com/SYUJTzL4
I had to use a handful of XZodia's plugins for the ones you didn't convert, and I would like to know how you got the info such as the pad alignment and max count. Unless you figured all of that through trial and error, but that seems a little insane xD
- XZodia
- Staff
- Posts: 2208
- Joined: Sun Dec 09, 2007 2:09 pm
- Location: UK
- Contact:
Re: Program GUI Thread
not sure about pad alignment but max count is from grim's extracted info from guerilla
- JacksonCougar
- Huurcat
- Posts: 2460
- Joined: Thu Dec 06, 2007 11:30 pm
- Location: Somewhere in Canada
Re: Program GUI Thread
moonfish has a shitty build system in it for building its tags directly from the guerilla executable. So my plugins are just a variant on that to convert into the entity layout.
Credit where it is due though; its all grim's codebase that made that possible (mangled and mutilated though by me :p)
If you are looking through the moonfish source you'll find the relavent code in the ./Guerilla directory. Some tricks are used to manually convert things from the vista format to the xbox one, but generally most things seem to map out very accurately back and forth. Things get a little hazy when dealing with any tags that are post- or pre- processed
Credit where it is due though; its all grim's codebase that made that possible (mangled and mutilated though by me :p)
If you are looking through the moonfish source you'll find the relavent code in the ./Guerilla directory. Some tricks are used to manually convert things from the vista format to the xbox one, but generally most things seem to map out very accurately back and forth. Things get a little hazy when dealing with any tags that are post- or pre- processed
- JacksonCougar
- Huurcat
- Posts: 2460
- Joined: Thu Dec 06, 2007 11:30 pm
- Location: Somewhere in Canada
- XZodia
- Staff
- Posts: 2208
- Joined: Sun Dec 09, 2007 2:09 pm
- Location: UK
- Contact:
Re: Program GUI Thread
What are you up to?
- JacksonCougar
- Huurcat
- Posts: 2460
- Joined: Thu Dec 06, 2007 11:30 pm
- Location: Somewhere in Canada
- JacksonCougar
- Huurcat
- Posts: 2460
- Joined: Thu Dec 06, 2007 11:30 pm
- Location: Somewhere in Canada
Re: Program GUI Thread
Normal mapping, blending with diffuse map, blending with specular highlight pulled from environment map...
missing detail maps
alpha channel mapped to specular
- XZodia
- Staff
- Posts: 2208
- Joined: Sun Dec 09, 2007 2:09 pm
- Location: UK
- Contact:
Re: Program GUI Thread
Snazzy...
Did your write your own shader for that?
Did your write your own shader for that?
- JacksonCougar
- Huurcat
- Posts: 2460
- Joined: Thu Dec 06, 2007 11:30 pm
- Location: Somewhere in Canada
Re: Program GUI Thread
Yea, I plan on implementing all the shaders in some form. When it comes to actually reversing code from the binaries that's more up Grims alley.
- Grimdoomer
- Admin
- Posts: 1835
- Joined: Sun Dec 09, 2007 9:09 pm
Re: Program GUI Thread
I made this. Full size: http://i.imgur.com/WsCme1E.jpg
It loads all the tag layouts from the pc toolset and my layouts from Mutation, and lets me compare them side by side.
It loads all the tag layouts from the pc toolset and my layouts from Mutation, and lets me compare them side by side.
Don't snort the magic, we need it for the network.
- XZodia
- Staff
- Posts: 2208
- Joined: Sun Dec 09, 2007 2:09 pm
- Location: UK
- Contact:
Re: Program GUI Thread
Nice syntax highlighter, link please?
- Grimdoomer
- Admin
- Posts: 1835
- Joined: Sun Dec 09, 2007 9:09 pm
Re: Program GUI Thread
http://www.codeproject.com/Articles/161 ... ghlighting
It's really good, one of the best custom controls I've ever seen.
It's really good, one of the best custom controls I've ever seen.
Don't snort the magic, we need it for the network.