Quantcast

Jump to content

» «
Photo

EasyEdit

7 replies to this topic
Donny78
  • Donny78

    Zombie

  • Members
  • Joined: 18 Jul 2008

#1

Posted 06 December 2010 - 11:56 PM Edited by Donny78, 12 December 2010 - 12:23 AM.

EasyEdit

This library makes it easy to hook into the San Andreas process and manipulate it's memory values using the C# programming language (any .NET language should be ok though). It has various read/write functions along with a few other helpfull ones such as capturing key presses or editing files, they are all explained using intellisense and are pretty straight forward.

The zip contains a readme, the xml file with the explinations for the functions and the EasyEdit library itself, the readme explains how to use the library but I've also provided an example below.

Download(s)

2Shared
MediaFire
GTAGarage page

Changelog

1.3 - (12/12/2010):

Removed the executable name requirement for the constructors path parameter
Added "GetPlayerPointer" and "GetPlayerVehilePointer" functions for ease of use
Corrected some of the constant names to reflect the value more clearly


1.2 - (08/12/2010):

Added quite a few constants containing either a base or an offset for usefull addresses

1.1 - (07/12/2010):

Added "StopSanAndreas" - Kills the San Andreas process
Added "AreKeysPressed" - Checks if two keys are currently pressed, a wrapper around "IsKeyPressed" for ease of use
Added "WriteScmInt, WriteScmSingle, ReadScmInt, ReadScmSingle" - read/write global variable values from/to the SCM
Added a second constructor method which allows a path to be passed for applications outside the SA root folder
Updated all string functions with a boolean encoding setting
Updated the intellisense to include return types in all none void functions
Updated the intellisense to reflect the changes in 1.1

Example

An example console application which changes the players money value when pressing the keys or stops San Andreas:

CODE
using System;                  
using System.Threading;        
using System.Windows.Forms;    
using EasyEdit;

namespace z
{
   class Program
   {
       static void Main(string[] args)
       {
           Easy ee = new Easy();
           int money = Easy.ADDRESS_PLAYER_MONEY;

           while (true)
           {
               if (ee.GetPlayerPointer() != 0)
               {
                   if (ee.IsKeyPressed(Keys.F5)) ee.WriteInt(money, 55555);
                   else if (ee.IsKeyPressed(Keys.F6)) ee.WriteInt(money, 1);
                   else if (ee.IsKeyPressed(Keys.F7))
                   {
                       if (ee.StopSanAndreas())
                       {
                           Thread.Sleep(6000);
                           break;
                       }
                   }
               }
               Thread.Sleep(1000);
           }            
       }
   }
}


The above is a standard console appliation I made in Microsoft Visual C# 2010 Express, the references were like so:

CODE

EasyEdit
System
System.Core
System.Data
System.Windows.Forms
System.Xml


Please feel free to leave a comment, report any issues you come across, give feedback or suggest a feature etc.

Enjoy.

Edit:

@Mods and anyone wondering:

I've attempted to block EasyEdit while in multiplayer, I don't support cheating incase you wonder, this is aimed at singleplayer.

coin-god
  • coin-god

    High Roller

  • $outh $ide Hoodz
  • Joined: 18 Mar 2007
  • None

#2

Posted 07 December 2010 - 12:22 AM

This looks really interesting.

I recommend you to upload this to GTAGarage.com, under Tools section. That link will never expire, and you can check how many downloads it has. Its also a rule in this forum. tounge.gif

And for better feedback this could be moved to Tools section or III Coding in III Era Modding.

Donny78
  • Donny78

    Zombie

  • Members
  • Joined: 18 Jul 2008

#3

Posted 07 December 2010 - 12:31 AM

QUOTE (goin-god @ Dec 7 2010, 00:22)
This looks really interesting.

I recommend you to upload this to GTAGarage.com, under Tools section. That link will never expire, and you can check how many downloads it has. Its also a rule in this forum. tounge.gif

And for better feedback this could be moved to Tools section or III Coding in III Era Modding.


I've just uploaded it to GTAGarage under the tools section (didn't know that rule, my bad), was a good idea that for sure. I didn't know where to upload it here so I chose coding as it's used for that but I agree tools would of been a choice also.

Thanks for your input.

uNi
  • uNi

    Cyclop 9

  • Moderator
  • Joined: 14 May 2004
  • None

#4

Posted 07 December 2010 - 12:44 AM

I'll certainly play around with this, great work. icon14.gif

Donny78
  • Donny78

    Zombie

  • Members
  • Joined: 18 Jul 2008

#5

Posted 07 December 2010 - 12:54 AM

QUOTE (uni @ Dec 7 2010, 00:44)
I'll certainly play around with this, great work. icon14.gif

Thanks.

@All:

I've just had a thought about my title, it's a little misleading as the dll should be useable in any .NET language as it's written in one but I've only tested it with C#.

uNi
  • uNi

    Cyclop 9

  • Moderator
  • Joined: 14 May 2004
  • None

#6

Posted 07 December 2010 - 12:56 AM

I've just approved it at GTAGarage so is available there now.

Donny78
  • Donny78

    Zombie

  • Members
  • Joined: 18 Jul 2008

#7

Posted 07 December 2010 - 12:58 AM

Thanks for that dude, I apreciate it.

Donny78
  • Donny78

    Zombie

  • Members
  • Joined: 18 Jul 2008

#8

Posted 08 December 2010 - 10:43 PM Edited by Donny78, 12 December 2010 - 12:24 AM.

Bump.

It's version 1.2 now, I added the changes in the first post but this version without internal stuff is really just the constants, access them by using "Easy.ADDRESS*******".

Again any features or addresses you would like to have just let me know and I'll do my best to add them.

Edit:

Now version 1.3, changes are listed again in the first post.




1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users