You must be logged in to post messages.
Please login or register

Scenario Design and Discussion
Moderated by Sebastien, Mr Wednesday

Hop to:    
loginhomeregisterhelprules
Bottom
Topic Subject: New find: hex editing .cpx files
posted 12-20-05 08:22 AM CT (US)   
Yeah I know, I just can't stop hex editing things. This time I decided to take a look at the .cpx file format. I haven't done much yet, only spent about half an hour on the .cpx code, but have already found some interesting stuff related to the campaign and scenario names.

The thing is you can add "forbidden" symbols to the campaign name and/or the scenario name(s), such as < . \ / > and so on. In fact all symbols avaible in the font (I think it's Georgia) can be used. You can also use spaces. I tried to center the text in the scenario box and succeeded, and did likewise with the text in the campaign box. I know it's a pretty lame trick, but I found it quite interesting nonetheless. There are more uses for this kind of hex editing, but I'm saving the best for my campaign.

Anyway, comments?

Replies:
posted 12-20-05 10:44 AM CT (US)     1 / 35  
Hey, go get a life.

Just kidding, I enjoy reading your new discoveries, but then again I'll never implement them.

posted 12-20-05 11:26 AM CT (US)     2 / 35  
I've always thought about that, having opened some .cpx and .scx files with word pad myself. I'de like to see what you come up with.

MoX_MiThRaNdIr
Current Project: A Battle for Peace - 45% Complete-(Reopened)

"You won't feel better until you get this thing off your chest"- Patrick Star (Spongebob Squarepants)
92% of teens have moved on to rap. If you are part of the 8% who still listen to real music, copy and paste this into your sig.
posted 12-20-05 12:28 PM CT (US)     3 / 35  

Quote:

Hey, go get a life.


Hey, it's not my fault. I just open the game and all the new discoveries sort of jump up in front of me. They're abusing my love for the game. I'm fading away. Help!

Quote:

I'de like to see what you come up with.


I'll see if I can compile and hex edit a campaign for you to see what I'm talking 'bout.
posted 12-20-05 05:08 PM CT (US)     4 / 35  
You've got to stop doing this Oliver, it's too much already. I've given up designing because it all seems so pointless. There's no point now to a scenario without any hex-edited invisible flying bananas.

Well done, I suppose.

posted 12-20-05 05:12 PM CT (US)     5 / 35  
Agreed, you've turned SD from something manageable into something that cannot be given above a 2.0 without all of your stupid tricks.
posted 12-20-05 05:17 PM CT (US)     6 / 35  
Colo, you always come across as if you're full of anger and itching for a fight! I hope it's just an act.
posted 12-20-05 05:22 PM CT (US)     7 / 35  

Quote:

Colo, you always come across as if you're full of anger and itching for a fight!


Um... I don't think of it that way... I guess sarcasm doesn't work on the internet.
posted 12-20-05 05:25 PM CT (US)     8 / 35  
You spoilt it with that smiley. Should have kept us all guessing...
posted 12-20-05 07:21 PM CT (US)     9 / 35  
Oliver: Argh.

[This message has been edited by Colo the Great (edited 12-20-2005 @ 07:22 PM).]

posted 12-20-05 07:49 PM CT (US)     10 / 35  
Hex editing is evil! Burn!

"A lot of fellows nowadays have a B.A., M.D., or Ph.D. Unfortunately, they don't have a J.O.B."-Salvadore Dali
posted 12-21-05 04:22 AM CT (US)     11 / 35  
Alright, next time I find a way to revolutionize scenario designing with hex editing I promise to keep my mouth shut.
posted 12-21-05 10:44 AM CT (US)     12 / 35  
Hex editing is evil! The world is flat!

[OOC]Actually, the best solution to all of this is to make a user-friendly app (like aokts) that will take advantage of all these new discoveries.[/OOC]

All hail AOKTS!


Creator of the AOK Trigger Studio, a work not in progress.
Wise men still seek Him.
posted 12-21-05 07:34 PM CT (US)     13 / 35  
Well I love reading Oliver's hexing endeavors, so you keep up the great work Oliver, and keep us all enlightened.

P.S. Have you ever hexed one of the campaigns on the disk to see how they get the Objectives screen to pop up at the start of a scenario?

posted 12-21-05 11:02 PM CT (US)     14 / 35  
I thought of that myself, Berserker, a while ago, but I seem to remember someone saying that renaming a campaign cam#.cpn and going through the special AOK menu would make the ojectives open. Never tested it, though.

Creator of the AOK Trigger Studio, a work not in progress.
Wise men still seek Him.
posted 12-22-05 06:09 AM CT (US)     15 / 35  
It's just fear, we're scared of what we don't understand. It reminds me of the bit in Frankenstein when the simple village folk descend on Dr Frankenstein armed with blazing torches and pitchforks. Although I live in a big city and I don't have any agricultural implements.
posted 12-22-05 06:30 AM CT (US)     16 / 35  
Oliver, are you a Hexa freak to?
posted 12-22-05 07:32 AM CT (US)     17 / 35  

Quote:

renaming a campaign cam#.cpn and going through the special AOK menu would make the ojectives open

Yes that’s true, I’ve done that myself leading me to the conclusion that is was/is coded in to the game and not the campaign file. Still, I know there are a few things that have never been answered in those cam#.cpx files, like how you get string tables in a change object name effect.

posted 12-22-05 08:39 AM CT (US)     18 / 35  

Quote:

P.S. Have you ever hexed one of the campaigns on the disk to see how they get the Objectives screen to pop up at the start of a scenario?


I tried to find out if there were any numbers in those campaigns which activated the pop-up objectives effect, but found nothing. I'm almost sure that it is hard-coded into the .exe file (but I'm not surprised if scenario_t_c soon enters this thread and prove me wrong ).

Hex editing the .cpx/cpn is just a matter of guessing. All I've found except for the stuff mentioned above is the byte that controls how many scenarios a campaign consists of. I'm also guessing that there are shorts controlling the length of the campaign and scenario names, since scenarios simply "disappear" from the scenario selection meny if you exceed the original amount of characters when changing the campaign name.

Anyway, maybe the feller who made the campaign manager knows more?

Quote:

It's just fear, we're scared of what we don't understand. It reminds me of the bit in Frankenstein when the simple village folk descend on Dr Frankenstein armed with blazing torches and pitchforks.


While reading that, I imagined an angry mob of scenario designers knocking at my back door and shouting stuff definitely not accepted by the CoC.

Quote:

Oliver, are you a Hexa freak to?


I wouldn't call myself a "freak". I knew nothing about hex editing less than three months ago. No, it's not a joke.

[This message has been edited by Oliver (edited 12-22-2005 @ 08:47 AM).]

posted 12-22-05 08:56 AM CT (US)     19 / 35  
Ohh...
Did you started hex editing in the "frame number and resource graphic editing" where I came in as the new forummer?

EDIT: Would my sig be a good one for the forummer of the year contest?

[This message has been edited by Ancient Warrior (edited 12-22-2005 @ 08:57 AM).]

posted 12-22-05 11:18 AM CT (US)     20 / 35  

Quoted from Berserker:

Still, I know there are a few things that have never been answered in those cam#.cpx files, like how you get string tables in a change object name effect.


Only one way: ES had a more powerful editor. It's actually been a long time since I've worked on AOKTS, but I believe you can do this in the version I'm working on now. Can you point me to a trigger that uses a string table for that effect?

Creator of the AOK Trigger Studio, a work not in progress.
Wise men still seek Him.
posted 12-22-05 11:59 AM CT (US)     21 / 35  

Quote:

Can you point me to a trigger that uses a string table for that effect?

Attila, scenario 1, trigger “E – Hun Commander”, they changed the name of a Tarkan to “Hun commander” yet it doesn’t show the “%” when selected with other units. If you look at the trigger, and then test, the “%” sign shows like any other unit that has been renamed. There is also an entry for Hun Commander in the language file.

posted 12-22-05 04:34 PM CT (US)     22 / 35  
I was under the impression that the Hun Commander/Old Hermit were special units... There's something really strange with them, because I'm fairly certain that I map copied them onto another scenario years ago and they kept their names...

zyxomma100- Age of Kings Heaven forumer
Proudly thwarting Dark_Aro's evil plans since 2002
"There is nothing more sad than watching a teutonic knight chasing a petard."
posted 12-23-05 08:48 AM CT (US)     23 / 35  
Not sure which unit you are thinking of zyx, but the Hun Commander in the Attila campaign is definitely a standard Tarkan re-named.
posted 12-23-05 12:05 PM CT (US)     24 / 35  
Yep.


Creator of the AOK Trigger Studio, a work not in progress.
Wise men still seek Him.
posted 12-29-05 06:38 AM CT (US)     25 / 35  

Quote:

Have you ever hexed one of the campaigns on the disk to see how they get the Objectives screen to pop up at the start of a scenario?


Oliver, further to BJ's question, would it be possible to alter the "Objectives have changed" message - change the wording or get rid of it?
posted 12-29-05 07:07 AM CT (US)     26 / 35  
The "Objectives has changed" message is definitely hard coded into the game, but you can get rid of it or change it by hex editing the language_x1.dll file: string table 195/1033, resource 3117. Never tested it myself though.
posted 12-29-05 07:25 AM CT (US)     27 / 35  
OK, thanks.
posted 12-29-05 10:11 AM CT (US)     28 / 35  
Another thing you might look for is if there is any way to manipulate the scenario order.

"I take it that this is the Anastasia Scud pines for?" - Epic Commander
"What Ana said. Use sugar and the whip." - aka the Pilot
"I think you will realize the emphasis was on Ana and Cake." - Monk
posted 12-29-05 10:41 AM CT (US)     29 / 35  
Interesting topic!

I have unnoticely made a discover at those string table numbers that you can set at the message tab in the editor of age of empire 2. Also i have found that you can do the same at the player tab. The creators of age of empire used this way to set the correct language. But i suppose that it is a way to detect the language for the desire player. This means that if you look in the language file you will find yourself a string code this string code is related to a specified language. Note: This is not a language like english, german and so. No, its some language the language.dll speaks.

I can let you see some of the string table codes that effect the player name in the player tab. Or a string table code that makes a text appear in the scenario instruction, the hints, loss victory and so on.

And yes, i was very curious at the idea to pop up the objectives in the start, as the campaigns does:
Attila the Hun, Joan of Arc, you surely know all of them by name. Because every well-known age of empire player have played all of the campaign scenario's at least once, aren't you?

That was all for now.


(_(_(_ World of Warcraft _)_)_)
(_(_(_(_(_( = [|]Level: 85 Pierce [|] = )_)_)_)_)_)
(_(_(_(_(_(_(_(_( = [|] Class: Warrior[|] = )_)_)_)_)_)_)_)_)
(_(_(_(_(_(_(_(_( = [|]Race: Human [|] = )_)_)_)_)_)_)_)_)
(_(_(_( = WizardBoy: | Proud member of AOK = Click to add population = )_)_)_)
posted 12-29-05 11:32 AM CT (US)     30 / 35  
I barely understood a word of that.

And I'm pretty sure there is no way to manipulate scenario order in a campaign from a scenario if that was what you were asking, Ana. There's not trigger to do it and no AI command to do it, so I just don't see any way. If only there was a Hex Edit effect.

And how come my image tag changed into a link? I'd like to see the poor 28.8 dialup user that can't handle a 7kB image.


Creator of the AOK Trigger Studio, a work not in progress.
Wise men still seek Him.

[This message has been edited by DiGiT (edited 12-29-2005 @ 11:38 AM).]

posted 12-29-05 11:54 AM CT (US)     31 / 35  

Quote:

And how come my image tag changed into a link? I'd like to see the poor 28.8 dialup user that can't handle a 7kB image.

http://www.heavengames.com/


Mace
posted 12-29-05 07:16 PM CT (US)     32 / 35  

Quoted from topic subject:

New find: hex editing .cpx files


Quoted from DiGiT:

If only there was a Hex Edit effect.


Yes dear...

"I take it that this is the Anastasia Scud pines for?" - Epic Commander
"What Ana said. Use sugar and the whip." - aka the Pilot
"I think you will realize the emphasis was on Ana and Cake." - Monk
posted 12-29-05 10:47 PM CT (US)     33 / 35  
I'd believe that, but then why is it that if we rename a unit to "Hun Commander" we will still get the "%s." in the grey info box. Same with the old hermit. Even if a units name is changed to something that already exists in language files (such as "Knight" or "Villager") we still get the %s. Is that related to string table numbers?
posted 12-30-05 05:06 PM CT (US)     34 / 35  
no, if you change the name in the language file the name is accepted and won't be assigned with a % if you point your mouse on the unit while playing on the map. But yes, those string table number can make you see some of the ES names they used... I can show you some if you want to???

(_(_(_ World of Warcraft _)_)_)
(_(_(_(_(_( = [|]Level: 85 Pierce [|] = )_)_)_)_)_)
(_(_(_(_(_(_(_(_( = [|] Class: Warrior[|] = )_)_)_)_)_)_)_)_)
(_(_(_(_(_(_(_(_( = [|]Race: Human [|] = )_)_)_)_)_)_)_)_)
(_(_(_( = WizardBoy: | Proud member of AOK = Click to add population = )_)_)_)
posted 12-31-05 01:25 PM CT (US)     35 / 35  
It displays the %s if you use the text field for the effect. It doesn't if you use a string table ID.

Creator of the AOK Trigger Studio, a work not in progress.
Wise men still seek Him.
Age of Kings Heaven » Forums » Scenario Design and Discussion » New find: hex editing .cpx files
Top
You must be logged in to post messages.
Please login or register
Hop to:    
Age of Kings Heaven | HeavenGames