GameShark Plugin + ...
 
Notifications
Clear all

GameShark Plugin + Tutorial

Page 1 / 3

Cain532
Posts: 1280
Topic starter
(@cain532)
Noble Member
Joined: 10 years ago

Ok, so in light of my original plugin which was very much.....incomplete..... I am now releasing version 2.0.0 of my GameShark Plugin for anybody who wants to use it 🙂

I gave the ENTIRE plugin a massive, and very much needed overhaul;

You will now be able to use this however you please, you can either tie them to a button, or even use a RichTextBox to dump your favorite codes into and it'll all work! (hopefully)

So, the original setup is going to be the same, you will need to add the GameShark.dll as a reference to your project like this

This process is the same as it was, be sure to use the PSXConnect function or else it won't attach to the PS1 process, currently this is supported on CCAPI 2.60. the switch to 2.70 shouldn't be too difficult, but I haven't tested it.

This is still the most important part! Adding this to your Program.cs

Essentially this runs the GameShark command in the background, so it's constantly running and won't bog down your program no matter how many codes you use!

As with anything there are definitely going to be bugs, and I desperately need you all (however few of you there are that use my stuff :p ) to give me much needed feedback on how to make it work better, and even more importantly bug reports to tell me what's broken.

Code using GameShark plugin

	        private void button1_Click(object sender, EventArgs e)
	        {
	            GameShark.CodeList = richTextBox1.Text.Splid('n'); //this will grab all the codes from your richTextBox
	        }
	

That's literally it! You can also set it to richTextBox_TextChanged or put it on a timer. Whatever works :p

Much easier eh?

If you want to do it yourself and tweak things a bit, or just want to snag the offset for yourself, you can use the

GameShark.GSC(string GameSharkCode); function. it spits out as a uint, so you can call it using

PS3.Extension.WriteBytes(GameShark.GSC("80456789"), new byte[] {0xFF, 0xFF}); Be sure to chip off the second part of the GS Code when using that uint function or else you'll get an error. you can use a simple StringToByteArray function to convert that part to a usable byte array :p That's how I do it; by the way, that function is also included, call it like so GameShark.StringToByteArray("1234"); So, if you have a full code, you can set it up like this

	// if the GameShark Code is 80456789 1234
	uint[] Address = GameShark.GSC("80456789");
	byte[] Value = GameShark.StringToByteArray("1234");
	Array.Reverse(Value)
	PS3.Extension.WriteBytes(Address, Value);
	

[hide]
Fixing some issues,
Sorry for the trouble!
[/hide]

Current supported code formats:

codes starting with "80"
Codes starting with "D0" (with second line containing "80")
Codes starting with "50" (with second line containing "80")

More to come!

Reply
Name of the Video Game, and any other Tags
13 Replies
Cyb3r
Posts: 1598
(@cyb3r)
Noble Member
Joined: 10 years ago

Good job bro, this is really nice to see PSX games taken care of. 😀

I might use this once I get the time. 😉

Reply
Cain532
Posts: 1280
Topic starter
(@cain532)
Noble Member
Joined: 10 years ago

Good job bro, this is really nice to see PSX games taken care of. 😀

I might use this once I get the time. 😉

Thanks! Super excited to have finally gotten it working

Reply
UGz-
Posts: 113
 UGz-
(@UGz-)
Estimable Member
Joined: 9 years ago

Well done Cain keep the hard work up 🙂

Reply
Posts: 0
(@Eddie Mac)
New Member
Joined: 1 second ago

Again nice job bro, keep the unique stuff coming man.

Reply
Page 1 / 3