Jump to content

game server mod

- - - - -

This topic has been archived. This means that you cannot reply to this topic.
8 replies to this topic

#1
John

John

    Writes binary right handed and hex left handed

  • Moderators
  • 6,321 posts
Well ive read about 5 chapters in my C++ book. Im comfortable working with the dev environment and i pretty much know the basic C++ stuff. However like I did when I first started php, i'm going to start with a project that is way over my head.

I want to make a simple server mod for this game I play. Basically what i want to do is (since the game is pretty old and there are a lot of cheaters playing) create a "Punt/Ban mod." Currently only the administrator of the server can punt/ban a player (can only be done server side.) I would like to create a mod that would allow players to punt a player after a certian ammount of votes. For example, I would type "punt kick 16" and then the server would reply "Vote 1 of 5 to kick player 16" then if 4 other people did that, it would have the server execute the punt command.


I guess the first step is to find out what the players are saying in the game, and therefor when the "punt kick" command is typed, the server can recogonize it and do what its suppose to do. So, when ever a player says something it is sent to the server and stored in these hex addresses (i think, at least thats what TSearch found):
0007EEC1C
0007EEC2C
0007EEC3C

The second part would be to execute the actual punt command. To do that, when it is "Vote 5 of 5" the server would punt the player. Ive seen some VB tutorials where u can just tell the server to press ~ and type "punt 16" like this:
Private Sub WriteText(Text As String)

   

    SendAMessage (Asc("~")) 'Press's ~ *brings up the chat propmt*.

   

    Sleep (50) 'Gives the chat propmt some time to initialize.

     

    Call WriteAscii(something goes here, Text) 'Writes text to the  prompt.


    Sleep (50) 'Gives sometime to the writing to finish.


    SendAMessage (vbKeyReturn) 'Press's ENTER *submits message*.


End Sub 
but im not sure how to do that in C++. So if anyone can tell me some functions or things i should look into, i would appreciate it.

Thank You.

#2
Ronin

Ronin

    Programming Professional

  • Members
  • PipPipPipPipPip
  • 309 posts
Are you using just C++ or Visual C++? What IDE are you using?

Sounds like a neat mod. I've seen that event in some games I've played. What game is this one for?

#3
John

John

    Writes binary right handed and hex left handed

  • Moderators
  • 6,321 posts
the mod is for Delta Force: Black Hawk Down

and im using Visual C++ w/(Microsoft Visual Studio 2005)

#4
Lop

Lop

    Speaks fluent binary

  • Members
  • PipPipPipPipPipPipPipPip
  • 1,172 posts
I'm not sure about accessing those addresses you give above.

The only thing I'm unsure about in porting your code to C++ is the SendAMessage (Asc("~")) line. SendAMessage is usually a winproc process or imported dll process. Do you see any imported dlls?

#5
John

John

    Writes binary right handed and hex left handed

  • Moderators
  • 6,321 posts

Lop said:

I'm not sure about accessing those addresses you give above.

The only thing I'm unsure about in porting your code to C++ is the SendAMessage (Asc("~")) line. SendAMessage is usually a winproc process or imported dll process. Do you see any imported dlls?

no there are no dll's, but the forum i got that code from made their own VB Module, perhaps SendAMessage is just a built in function of that module that the compiler resogonizes, but anyway i just used that as a psuedo code to try and get the point of what i want to do accrost.

#6
Guest_Kaabi_*

Guest_Kaabi_*
  • Guests
I hope I can make something like that someday, but it will be hard since I'm not studying C++, ha.

#7
John

John

    Writes binary right handed and hex left handed

  • Moderators
  • 6,321 posts

Kaabi said:

I hope I can make something like that someday, but it will be hard since I'm not studying C++, ha.

I hope i can make something like this too :P

#8
Ronin

Ronin

    Programming Professional

  • Members
  • PipPipPipPipPip
  • 309 posts
Where did you get that code? Is there no tutorials for making game mods?

#9
Sionofdarkness

Sionofdarkness

    Programming Expert

  • Members
  • PipPipPipPipPipPip
  • 384 posts
Delta Force, aye? At first when I was reading it sounded a lot like a game I play, and I was excited because I thought it was going to be it, but I can see I was wrong.