Dear HTS...

Discuss how to write good code, break bad code, your current pet projects, or the best way to approach novel problems

Dear HTS...

Post by Casval on Tue Jun 02, 2009 10:54 am
([msg=24763]see Dear HTS...[/msg])

Our class has been instructed to write a chess game in java with fully functional AI. We're nearing the part where the AI is to be implemented and our professor is going to harness our games together using a program he built in WPF. It's basically random student's AI vs another random student's AI. Our professor has posed an interesting alternative plan: Hack his program.

I've never done any sort of program hacking before and I'm wondering if anyone has a push in the right direction. The source code for my game and his harness is available, the only variable is the opponent's chess game which has to conform to a standard in order to relay messages back and forth between the individual game and the harness. Flow goes something like this:


Game --------> Harness <--------- Game

All of the output is handled by the harness, the game is responsible for the back-end (move processing, validation, etc). Not sure where to get started on this one, or if it's even possible at all, but it's a pretty interesting concept. Let's see what we can come up with.
Casval
New User
New User
 
Posts: 24
Joined: Mon Apr 14, 2008 7:05 am
Blog: View Blog (0)


Re: Dear HTS...

Post by godofcereal on Tue Jun 02, 2009 11:06 am
([msg=24765]see Re: Dear HTS...[/msg])

You want us to hack your game am I right?

Disclaimer :
HackThisSite does not support illegal activities.
Im off, last year of school and all, I had something longer but char limit fucked that up. So yeah, had a good run here. Thanks for the memories. Thanks to the staff and users.

Best regards, your posting whore,
godofcereal

p.s. Defience, you the man ;)
User avatar
godofcereal
Addict
Addict
 
Posts: 1068
Joined: Wed Aug 20, 2008 6:11 pm
Location: ireland
Blog: View Blog (0)


Re: Dear HTS...

Post by BhaaL on Tue Jun 02, 2009 11:32 am
([msg=24766]see Re: Dear HTS...[/msg])

This doesnt look that bad at all tho, since their teacher offered it as alternative.

You might want to look into Reflection, and check out how it can modify stuff you shouldnt be able to see (that is, non-public stuff).
The rest is on google, or the MSDN.

Edit: Oh, wait a second. How is that supposed to work? AI in Java, plugged into a WPF (.NET) application?
Java also has Runtime Type Reflection capabilities, but I'm not that sure if it could do the same stuff, or in the same way.
BhaaL
Poster
Poster
 
Posts: 270
Joined: Sun Apr 13, 2008 11:16 am
Blog: View Blog (0)


Re: Dear HTS...

Post by Casval on Tue Jun 02, 2009 2:15 pm
([msg=24770]see Re: Dear HTS...[/msg])

godofcereal wrote:You want us to hack your game am I right?

Disclaimer :
HackThisSite does not support illegal activities.


No, I don't want you to hack my game. I want you to give me ideas as to how I can get this done. This isn't exactly hacking since it's acknowledged on both ends and the scope is a simple game. I'm not asking for help on hacking a bank or anything...

BhaaL wrote:This doesnt look that bad at all tho, since their teacher offered it as alternative.

You might want to look into Reflection, and check out how it can modify stuff you shouldnt be able to see (that is, non-public stuff).
The rest is on google, or the MSDN.

Edit: Oh, wait a second. How is that supposed to work? AI in Java, plugged into a WPF (.NET) application?
Java also has Runtime Type Reflection capabilities, but I'm not that sure if it could do the same stuff, or in the same way.


Yea, we asked him the same thing when he presented it to us. He told us the program ran a lot smoother when written in WPF. The source code is available to us but the programs will run on his machine. It loads two .jar files and runs from there. I'm thinking this is a lost cause between Java and WPF but it's always worth a try.
Casval
New User
New User
 
Posts: 24
Joined: Mon Apr 14, 2008 7:05 am
Blog: View Blog (0)


Re: Dear HTS...

Post by Spectre557 on Tue Jun 02, 2009 4:33 pm
([msg=24773]see Re: Dear HTS...[/msg])

Casval wrote:This isn't exactly hacking since it's acknowledged on both ends and the scope is a simple game.

Yes it is! It certainly doesn't need to be illegal to be hacking...

Sorry I can't be any help with your question though :(
Current obsession: Minecraft
User avatar
Spectre557
Poster
Poster
 
Posts: 215
Joined: Wed Apr 29, 2009 4:04 am
Blog: View Blog (0)


Re: Dear HTS...

Post by Casval on Tue Jun 02, 2009 5:03 pm
([msg=24776]see Re: Dear HTS...[/msg])

Spectre557 wrote:
Casval wrote:This isn't exactly hacking since it's acknowledged on both ends and the scope is a simple game.

Yes it is! It certainly doesn't need to be illegal to be hacking...

Sorry I can't be any help with your question though :(


I meant hacking in more of a mainstream "derp press here to hax" context.
Also, you made me cry. :<
Casval
New User
New User
 
Posts: 24
Joined: Mon Apr 14, 2008 7:05 am
Blog: View Blog (0)


Re: Dear HTS...

Post by Nines on Wed Jun 03, 2009 1:03 am
([msg=24794]see Re: Dear HTS...[/msg])

godofcereal wrote:You want us to hack your game am I right?

Disclaimer :
HackThisSite does not support illegal activities.


Sometimes I think you post this just to boost your post count >_>

In response to the OP. Write a socket class to play against an online chess computer with expert AI. Use the moves that your student opponent uses against the expert computer AI and play the expert computer AI's moves back at the student. If he wins, then he deserved to ;)
User avatar
Nines
Poster
Poster
 
Posts: 191
Joined: Sun Apr 13, 2008 5:57 pm
Blog: View Blog (0)


Re: Dear HTS...

Post by myhexhax on Wed Jun 03, 2009 8:17 am
([msg=24806]see Re: Dear HTS...[/msg])

bookmarking topic.

Sometimes I think you post this just to boost your post count >_>

Agreed, haha.
gniripsni ewa si rehte eht morf cisum siht
myhexhax
Poster
Poster
 
Posts: 217
Joined: Tue Sep 16, 2008 2:19 pm
Location: Between the ether and the information superhighway
Blog: View Blog (0)


Re: Dear HTS...

Post by Casval on Wed Jun 03, 2009 4:01 pm
([msg=24820]see Re: Dear HTS...[/msg])

I think we can all agree this is a bit of a lost cause now.
Given a week, I'm pretty positive I can't get this done. I can always do this in my free time, but the odds of it getting done then are pretty low as well.

ITT: Easy chess AI algorithms
Discuss.
Casval
New User
New User
 
Posts: 24
Joined: Mon Apr 14, 2008 7:05 am
Blog: View Blog (0)


Re: Dear HTS...

Post by zobier on Wed Jun 03, 2009 9:15 pm
([msg=24839]see Re: Dear HTS...[/msg])

I wouldn't call it easy, but it's the world's smallest chess engine.
{B:[1,2,3,4,5,6,7,8,9,10,11],R:[1,2,3,4,5,6,7,8,9,10,11,12,13,14],A:[1,2,3,4,5,6],P:[1,2],J:[1,2,3,4,5,6,7],E:[1,2,3,4,5,6,7,8,9,10,11,12,13]}
User avatar
zobier
New User
New User
 
Posts: 30
Joined: Tue Apr 21, 2009 6:46 am
Blog: View Blog (0)


Next

Return to Programming

Who is online

Users browsing this forum: No registered users and 0 guests