Quick Modding/Hacking Answers Thread

Dec 16, 2010 at 9:47 PM
Senior Member
"Master using it, and you can have this!"
Join Date: Oct 18, 2010
Location:
Posts: 85
Noxid said:
Should be data/bullet.pbm

Thanks. I'm amazed I didn't see this the first time.
 
Dec 17, 2010 at 4:30 AM
Senior Member
"This is the greatest handgun ever made! You have to ask yourself, do I feel lucky?"
Join Date: Oct 30, 2010
Location: New Zealand
Posts: 112
Age: 28
Hey guys, I was wondering where I could find the Organya Viewer 1.34? According to Noxid's modding beginner's guide, the version 2 one can have some errors, if I remember correctly.
 
Dec 17, 2010 at 4:48 AM
Not anymore
"Run, rabbit run. Dig that hole, forget the sun."
Join Date: Jan 28, 2010
Location: Internet
Posts: 1369
Age: 34
Pronouns: he/him
Shadow Major said:
Hey guys, I was wondering where I could find the Organya Viewer 1.34? According to Noxid's modding beginner's guide, the version 2 one can have some errors, if I remember correctly.

http://www.cavestory.org/downloads_musictools.php

In the music tools page, at the top left corner. You'll need to patch it yourself.

Noxid's guide doesn't say that OrgMaker v2.05 has errors. It just says that Org v02 files are not compatible with Cave Story unless you stick to the original drums of the older version (which is what people do).

There is a way to use the new drums for Org v2 inside Cave Story, and that's by installing the WAV-org hack (also made by Noxid).
 
Dec 19, 2010 at 3:04 AM
I don't anymore.
"I'm sorry Mario, but your princess is in another castle."
Join Date: Aug 9, 2010
Location: Greener Pastures
Posts: 1188
Age: 30
About those background effects I asked about earlier, I decided that for the darkness effect, it would be easieer to edit the frame errects of Curly when carried. As for the water that kills you while still being the same background effect, I'm still trying to figure it out.

Coukd anyony give me a brief explanation om frame errects? I didn't quite understand them in the guide. :mahin:
 
Dec 19, 2010 at 3:29 AM
Been here way too long...
"Life begins and ends with Nu."
Join Date: Jan 4, 2008
Location: Lingerie, but also, like, fancy curtains
Posts: 3052
A frame rect is four different values that describe the shape of a rectangle. This rectangle stretches from point (x1,y1) to point (x2,y2), each being locations on the mother graphic. This rectangle is passed to a graphics drawing function, where the insides are drawn. In almost all cs entities, the rects are local variables, say [ebp-1c], [ebp-18], [ebp-14] and [ebp-10]. Again, four different vals. when it comes to calling a graphics function the highest of these values is lea'd and pushed. This gives a perma offset that a non-local function can access. However, many entities have multiple frames, so you'll see some code like lea ecx,[ebp-10-eax*4] where eax is the frame number.

btw all the frame rects are generally listed inna hunk at the start of a npc/bullet. I forget the order, but it either goes yxyx or xyxy, I'd say the first one off a hunch, cuz that's the way pixel normally rolls, but I can't say w/o looking at my exe.
 
Dec 19, 2010 at 3:34 AM
In my body, in my head
Forum Moderator
"Life begins and ends with Nu."
Join Date: Aug 28, 2009
Location: The Purple Zone
Posts: 5998
Pronouns: he/him
Frame rects are actually fairly simple once you know what's going on.

A framerect is stored as four DWORD-size variables, each representing a side of a rectangle - Left, Up, Right, Down. For entities, they're typically initialized as local variables in the beginning of the code, and then later on they're transferred to the entity's variables (the ones in [ecx+whatever]).

Local variables are [ebp-whatever], and the four values of a framerect usually go like this:

Frame 1:
mov [ebp-20], L1
mov [ebp-1C], U1
mov [ebp-18], R1
mov [ebp-14], D1
Frame 2:
mov [ebp-10], L2
mov [ebp-0C], U2
mov [ebp-08], R2
mov [ebp-04], D2

The values MOV'd are the hex version of the values on the bitmap, in pixels, that make up the 'rectangle' for the sprite, so just change each of those in turn and you can change the rects to whatever.

edit: IRC makes me slow ]:
 
Dec 19, 2010 at 10:54 PM
Senior Member
"Master using it, and you can have this!"
Join Date: Aug 19, 2009
Location: UK
Posts: 85
Age: 30
Hey everyone.

Why does this:

Code:
PUSH EBP
MOV EBP,ESP
SUB ESP,10
MOV DWORD PTR SS:[EBP-10],0F0              Store framerect in local vars
MOV DWORD PTR SS:[EBP-0C],60
MOV DWORD PTR SS:[EBP-8],100
MOV DWORD PTR SS:[EBP-4],70
MOV EAX,DWORD PTR SS:[EBP+8]
ADD EAX,54
MOV ECX,DWORD PTR SS:[EBP-10]               Store framerect in ECX/EDX
MOV DWORD PTR DS:[EAX],ECX                    Final data in EAX
MOV EDX,DWORD PTR SS:[EBP-0C]
MOV DWORD PTR DS:[EAX+4],EDX
MOV ECX,DWORD PTR SS:[EBP-8]
MOV DWORD PTR DS:[EAX+8],ECX
MOV EDX,DWORD PTR SS:[EBP-4]
MOV DWORD PTR DS:[EAX+0C],EDX
MOV ESP,EBP
POP EBP
RETN

display the sprite, whereas this:

Code:
PUSH EBP
MOV EBP,ESP
SUB ESP,10
ADD EAX,54
MOV DWORD PTR DS:[EAX],0F0
MOV DWORD PTR DS:[EAX+4],60
MOV DWORD PTR DS:[EAX+8],100
MOV DWORD PTR DS:[EAX+0C],70
MOV ESP,EBP
POP EBP
RETN

just halts the program??

I'm new to assembly, but I can't quite understand this.
 
Dec 19, 2010 at 11:01 PM
In my body, in my head
Forum Moderator
"Life begins and ends with Nu."
Join Date: Aug 28, 2009
Location: The Purple Zone
Posts: 5998
Pronouns: he/him
Access violation. The key thing you're missing is
MOV EAX, [ebp+8]. This sets eax to the pointer to the entity's own data.
Now, [eax+54] or,
add eax, 54
[eax]
points to the start of the entity's framerect data.
 
Dec 19, 2010 at 11:02 PM
Lvl 1
Forum Moderator
"Life begins and ends with Nu."
Join Date: May 28, 2008
Location: PMMM MMO
Posts: 3713
Age: 32
hammil said:
Code:
PUSH EBP
MOV EBP,ESP
SUB ESP,10 
ADD EAX,54
MOV DWORD PTR DS:[EAX],0F0
MOV DWORD PTR DS:[EAX+4],60
MOV DWORD PTR DS:[EAX+8],100
MOV DWORD PTR DS:[EAX+0C],70
MOV ESP,EBP
POP EBP
RETN
I'm new to assembly, but I can't quite understand this.

Try this:
Code:
PUSH EBP
MOV EBP,ESP
SUB ESP,10  <- this line is unnecessary btw.
[B]MOV EAX,DWORD PTR SS:[EBP+8][/B]
ADD EAX,54
MOV DWORD PTR DS:[EAX],0F0
MOV DWORD PTR DS:[EAX+4],60
MOV DWORD PTR DS:[EAX+8],100
MOV DWORD PTR DS:[EAX+0C],70
MOV ESP,EBP
POP EBP
RETN


MOV EAX,DWORD PTR SS:[EBP+8]
this line is very important.
 
Dec 19, 2010 at 11:10 PM
Senior Member
"Master using it, and you can have this!"
Join Date: Aug 19, 2009
Location: UK
Posts: 85
Age: 30
D'oh! Curse my unobservant eyes!

But it worked great, thanks all!
 
Dec 20, 2010 at 12:29 AM
Senior Member
"This is the greatest handgun ever made! You have to ask yourself, do I feel lucky?"
Join Date: Oct 30, 2010
Location: New Zealand
Posts: 112
Age: 28
Is it possible to subtract from your max health?
Eg: If your max health is 50, is it possible to lower it to 40?
 
Dec 20, 2010 at 12:31 AM
In my body, in my head
Forum Moderator
"Life begins and ends with Nu."
Join Date: Aug 28, 2009
Location: The Purple Zone
Posts: 5998
Pronouns: he/him
Try <LI+00!0
If that doesn't work, then you'd need Hax
 
Dec 20, 2010 at 12:35 AM
graters gonna grate
"Heavy swords for sale. Suitable for most RPG Protagonists. Apply now!"
Join Date: Jul 2, 2008
Location: &
Posts: 1886
Age: 32
Pronouns: he/him
You mean <ML+ right?

Edit: I don't think your number is right either. 00!0 would be -150 (since ! is 15 less than 0). Try either <ML+000& or <ML+00/0
 
Dec 20, 2010 at 12:39 AM
In my body, in my head
Forum Moderator
"Life begins and ends with Nu."
Join Date: Aug 28, 2009
Location: The Purple Zone
Posts: 5998
Pronouns: he/him
Ah, yes, that's right. I was just going by memory...
<ML+000& or <ML+00/0 is correct.
 
Dec 20, 2010 at 4:46 AM
I don't anymore.
"I'm sorry Mario, but your princess is in another castle."
Join Date: Aug 9, 2010
Location: Greener Pastures
Posts: 1188
Age: 30
I got the camara thing to work for the most part. Now I just need to get it centered around quote, and put it in the foreground. How would I put it in the foreground?
 
Dec 20, 2010 at 4:54 AM
In my body, in my head
Forum Moderator
"Life begins and ends with Nu."
Join Date: Aug 28, 2009
Location: The Purple Zone
Posts: 5998
Pronouns: he/him
It all depends when you call 40C3C0.
Every frame, the game runs through 410400 and when it comes across a call to 40C3C0, it draws that to the screen. To get something to draw on top of something else, you draw the bottom thing first and then the top thing; stuff overwrites other stuff.

The call format for 40C3C0 is:
push graphicsid
push rects ; lea [ebp-xx]
push y
push x
push FullScreenRect [48F91c]
call 0040C3C0
add esp,14

So let's say your rects are at [ebp-20] and you want to draw from bitmap object 0x16 (Map NPC Set 2)
Push 16
lea eax, [ebp-20]
push eax
push y
push x
push [48F91C]
call 40C3C0
add esp, 14

You'll have to make a bit in the code that JMPs to somewhere else, calls that function, and then returns to where it was without interrupting the flow. This is known as "branching" I believe but it's not so much a branch really as it is like a tumor, except tumors don't make for such nice visual analogies.
 
Dec 21, 2010 at 2:38 AM
I don't anymore.
"I'm sorry Mario, but your princess is in another castle."
Join Date: Aug 9, 2010
Location: Greener Pastures
Posts: 1188
Age: 30
GIRakaCHEEZER said:
It sounds more like you need a tutorial on basic composition (which would include musical theory) rather than one specific for orgmaker.

There are no tutorials on this site that I know of.

Now that I think about it, while knowing musical theory is a big part of making music, shouldn't there be a guide for all the functions of OrgMaker? Not with tune or anything, but with the copy paste functions and the pan speed settings and whatnot. I think my skills at org making would have improved much faster if I'd known some of that stuff to start instead of by experimenting alot. And if anyone really needs help music making shouldn't there also be some tips on how to make 8-bit sounding music sound good, as it is different that using actual instruments?
 
Dec 21, 2010 at 3:44 AM
Lvl 1
Forum Moderator
"Life begins and ends with Nu."
Join Date: May 28, 2008
Location: PMMM MMO
Posts: 3713
Age: 32
HyMyNameIsMatt said:
And if anyone really needs help music making shouldn't there also be some tips on how to make 8-bit sounding music sound good, as it is different that using actual instruments?

Not really. Music is music, and if you can make music on one instrument, then chances are you can make it on different instruments. 8-bit chiptunes are no exceptions.

I doubt anyone will make a guide for orgmaker anytime soon though, since the program is pretty much self explanatory.
 
Dec 21, 2010 at 4:26 AM
graters gonna grate
"Heavy swords for sale. Suitable for most RPG Protagonists. Apply now!"
Join Date: Jul 2, 2008
Location: &
Posts: 1886
Age: 32
Pronouns: he/him
GIRakaCHEEZER said:
Not really. Music is music, and if you can make music on one instrument, then chances are you can make it on different instruments. 8-bit chiptunes are no exceptions.

There are some differences in the skills needed. Like, when making chiptune music, you don't have to worry about making it "playable", but with real instruments, the best song ever would be useless if it's so damn hard that nobody can play it. Also, with real instruments, you don't have to be as detailed, since the performers are humans with their own artistic sense, and will fill in all the subtle details of volume/tone/timing, while with chiptune music, the computer just blindly plays whatever you give it, so you have to be much more precise/detailed. Heck, just learning to use the volume envelope in Organya effectively is practically an art form unto itself (and one that isn't involved with real instruments at all). If you listen to some of my earlier orgs (like Dragzelire Fist, Titan of Thunder, Elemenion), you'll notice that I don't use the volume envelope very well, since I was so used to composing for the piano, where you don't need to worry about that.

That being said, you're basically right, in that the similarities between composing for humans and composing for computers far outweigh the differences (though there are some noteworthy differences).
 
Dec 21, 2010 at 11:12 AM
Senior Member
"This is the greatest handgun ever made! You have to ask yourself, do I feel lucky?"
Join Date: Oct 30, 2010
Location: New Zealand
Posts: 112
Age: 28
Noxid said:
Ah, yes, that's right. I was just going by memory...
<ML+000& or <ML+00/0 is correct.

May I ask what these characters (& and /) mean?
 
Back
Top