Command & Conquer Communications Center

keeping the classics alive!

Recent Posts

Pages: [1] 2 3 ... 10
1
Dune 2000 / Re: Window change and dual monitor bugs
« Last post by FunkyFr3sh on Today at 01:23:20 PM »
this is windows8, right? try to play skirmish/online (do not use the singleplayer button in the launcher)

the window mode is not done yet, it works somewhat but you cannot move the window/lock the cursor
2
Dune 2000 / Re: Window change and dual monitor bugs
« Last post by Nyerguds on Today at 12:05:12 PM »
isn't there a windowed mode mod for d2k yet?
3
CnCNet Discussion / Re: Chat ban
« Last post by Nyerguds on Today at 12:00:37 PM »
And you're surprised they don't want to give you the opportunity to pull that crap here?
4
The Tech Center / Re: Introduction to modding/hacking
« Last post by Nyerguds on Today at 11:58:18 AM »
You missed the entire point of the exercise.  Nothing gets them excited to learn quite like seeing what you can do with the game.  Fixing game bugs and adding features will be covered in future tutorials, and consider this is an intro to modding/hacking.  What I've shown is perfectly in the bounds of that.

I'm just joking, man ;)

Though I guess, at the moment, this indeed the only way to mod C&C95.

They might want to take a look at my ini files to see what options are identified for each type so far ;)
5
The Tech Center / Re: Introduction to modding/hacking
« Last post by peterthepigeon on Today at 11:01:37 AM »
So we had fun right?  Those parlor tricks were neat no?  Thats peas compared to the power of what you can do.  For now however, we need to get back to learning, but I hope it inspired you to dig and learn on your own in addition to what I've been posting here.

Let's learn how to encode a x86 instruction shall we?

So everybody and his grandma knows that a x86 instruction has a few parts

prefix(es)
opcode
opcode2
modrm
sib
relative
displacement
immediate

There are a total of four prefixes, lock prefix/repeat, segment override, and 2 size override prefixes.

Your lock and repeat prefixes start at 0xF0 -> 0xF3, excluding 0xF1.

Your segment overrides:

Code: [Select]
#define PREFIX_SEGMENT_CS   0x2e
#define PREFIX_SEGMENT_SS   0x36
#define PREFIX_SEGMENT_DS   0x3e
#define PREFIX_SEGMENT_ES   0x26
#define PREFIX_SEGMENT_FS   0x64
#define PREFIX_SEGMENT_GS   0x65

Your size overrides are 0x66 and 0x67. 

0x66 overrides the operand size
0x67 overrides the address size.

We could discuss the opcode/opcode2, but I feel that it's wiser to save it for another time.

Let's move onto the modrm and sib now.  How do we intrepret the modrm and sib?

Well think back to the first tutorial, remember I stressed how important understanding bitmasking was?  Well here is why.

http://pdos.csail.mit.edu/6.828/2006/readings/i386/fig17-2.gif

Notice the register is packed into the byte using 3 bits, with the least most significant bit specifying if it is a register or a memory operation.  THe most significant bit, bit 7 is the mode.

The SIB is largely self explanatory, where bits 6-7 specify the scale, 1, 2, 4, 8.  The index and the base are registers usually, otherwise it could happen to be the immediate.

Seem familiar and visible from the last tutorial?  I hope so.

We use the relative when doing calls/jumps.  We'll cover this in the future.

The displacement can be a memory address or an offset from a memory address.

The immediate can be any value, 8 bit, 16 bit and 32 bit thereof.

The only nuance I can recall about 64 bit is that aside from the rex prefix, the only difference is that the immediates are 64 bit whereas displacements/relatives are stuck to 32 bit.

I'll edit this post to give a few nice examples of this so it's easier to comprehend.

6
Modding Discussion / Re: New Team Colours (RA1)
« Last post by Nyerguds on Today at 10:51:13 AM »
Well, you can't force the game into using remap differently, so the way to do what you describe IS putting two shorter remap ranges on one row in the palette.cps.
7
Modding Discussion / Re: New Team Colours (RA1)
« Last post by White on Today at 10:44:27 AM »
Well, I was talking about not just replacing a remap with a non remap, but actually using a conversion to make each SHP use LESS of the remap than it's already using. Like, see how your green colour scheme is essensually using less colours but still using all of the indices? well, convert SHPs to be using only that, and then use the now unused extra indices as a totally new colour, so that buildings and units can have a small range of extra colour.
   -Liam
8
The Tech Center / Re: Introduction to modding/hacking
« Last post by peterthepigeon on Today at 10:38:25 AM »
lol. Here we go out of our way to prove hacking is a tool we can use to do nice things like fixing game bugs and adding features, and what do you use as example for this? Cheating in the game :D

You missed the entire point of the exercise.  Nothing gets them excited to learn quite like seeing what you can do with the game.  Fixing game bugs and adding features will be covered in future tutorials, and consider this is an intro to modding/hacking.  What I've shown is perfectly in the bounds of that.
9
Modding Discussion / Re: New Team Colours (RA1)
« Last post by Nyerguds on Today at 10:36:01 AM »
well, C&C1's betas are seen doing something similar with 2 house colours on buildings. The question is, though, what colours you'd use... the yellow fade on the palette is kind of... there already. I used the orange fade near the end of the palette as remap source for this experiment.

Maybe the blue/brown row above the orange could work.
10
CnCNet Discussion / Re: dc from games
« Last post by Xforce on Today at 10:30:48 AM »
yep when  i come back i dc from lobby too then i have to restart my router but it only happens when playing cncnet not downloading orsurfing so i dont thing its my internet problem  :( :( :( :( :( :( :(
Pages: [1] 2 3 ... 10