SRL Archive - Archive

Silentwolf = SRL Member... ?


Sir R. M8gic1an

2010-01-14 12:23:14

Rasta Magician has reported a post.

Reason:
I'd consider him for Auto-Membership soon.

~RM

Post: Hooking openGL functions for new style reflection
Forum: General Dump
Assigned Moderators: N/A

Posted by: silentwolf
Original Content:
Hi,

This is just an idea I've been thinking about for a while, since Jagex started using the jOGL library to do its graphics.

I'm not sure if any of you are aware of the FPS (e.g. counterstrike, CoD etc) cheating scene. There are two style of hacks - one hooks the game functions directly (similar to the way RS client hacks work) and the others hook at the openGL/D3D level.

As RS can now use openGL to render (only in high gfx settings?) it it now trivial to hook openGL and perform standard model detection. (see http://forum.gamedeception.net/forumdisplay.php?f=261 for some general examples of what can be done in other games).

As a proof of concept I used GLIntercept (http://glintercept.nutty.org/) to log OGL calls and make sure this is plausible.

Here's an example of what I believe is a 3D model being rendered:

glGenBuffersARB(1,0x2320add4)
glBindBufferARB(GL_ARRAY_BUFFER,1028)
glBufferDataARB(GL_ARRAY_BUFFER,3168,0x23783ffc,GL_STATIC_DRAW) //0x23783ffc points to the vertex buffer... read this for model recognition
glEnableClientState(GL_VERTEX_ARRAY)
glVertexPointer(3,GL_FLOAT,24,0x0000)
glEnableClientState(GL_NORMAL_ARRAY)
glNormalPointer(GL_FLOAT,24,0x000c)
glEnableClientState(GL_COLOR_ARRAY)
glBindBufferARB(GL_ARRAY_BUFFER,171)
glColorPointer(4,GL_UNSIGNED_BYTE,28,0x000c)
glEnableClientState(GL_TEXTURE_COORD_ARRAY)
glBindBufferARB(GL_ARRAY_BUFFER,135)
glTexCoordPointer(2,GL_FLOAT,36,0x001c)
glBindTexture(GL_TEXTURE_2D,145)
glBindBufferARB(GL_ELEMENT_ARRAY_BUFFER,136)
glDrawElements(GL_TRIANGLES,168,GL_UNSIGNED_SHORT,0x0000) Textures[ (0,145) ]
glBindTexture(GL_TEXTURE_2D,144)
glDrawElements(GL_TRIANGLES,138,GL_UNSIGNED_SHORT,0x0150) Textures[ (0,144) ]
glPopMatrix()
glMatrixMode(GL_PROJECTION)
glLoadMatrixf([1.183333,0.000000,0.000000,0.000000,0.000000,2.453564,0.000000,0.000000,0.000000,0.000000,-1.027477,-1.000000,0.000000,0.000000,-96.387375,0.000000])
glMatrixMode(GL_MODELVIEW)
glMatrixMode(GL_PROJECTION)
glLoadMatrixf([1.183333,0.000000,0.000000,0.000000,0.000000,2.453564,0.000000,0.000000,0.000000,0.000000,-1.026092,-1.000000,0.000000,0.000000,-87.635582,0.000000])
glMatrixMode(GL_MODELVIEW)
glPushMatrix()
glMultMatrixf([1.000000,0.000000,0.000000,0.000000,0.000000,1.000000,0.000000,0.000000,0.000000,0.000000,1.000000,0.000000,7360.000000,-320.000000,5952.000000,1.000000])

Once you can copy out the vertex array, you can generate a unique ID for each model (e.g. devise an algorithm to generate a unique id based on vertex positions) and do a WorldToScreen conversion to get the 2D coords of the model. This can then be passed to scar.

Similar methods would allow things such as map recognition etc.

The advantage over the SMART reflection is that it doesn't need to be updated every time RS is updated, only if they change the models.

Thoughs, ideas, suggestions? I could code up a small proof of concept if people are interested.

Sir R. M8gic1an

2010-01-14 12:24:58

I suggest you read the whole thread. Quite interesting and the guy is puttin a lot ofeffrt into it :)

~RM

Wanted

2010-01-14 12:37:05

I would say not yet… he needs to show more work on SCAR/SRL and/or a lot more about this openGL before he gets auto members.

mastaraymond

2010-01-14 13:12:19

We shouldn't rush this, but yes after he comes up with some decent code instant members.. His knowledge about runescape cheating is already 3x bigger than another srl member :p

Boreas

2010-01-14 13:49:52

What about promising newcomer?

senrath

2010-01-14 14:22:59

From: Boreas
What about promising newcomer?


Agreed. While he's doing some awesome stuff, he hasn't done anything with SRL yet. But he's definitely a Promising Newcomer.

mixster

2010-01-14 14:36:43

I can understand wanting to keep skilled programmers in the community, but it seems that there is no proof of his Scar/Simba or SRL related knowledge or the like. It is suggested that he has his origins in aimbots in other games as he specifically mentioned them, so I would say this is just a bit of overspill from that.

In regards to the actual idea, as he seems quite happy to keep at it and I don't want to hurt that, so I'll say it here - I don't think it has much of a future. First of all, because it's easy to break as he mentions an "OpenGL hook" insinuating a weekly break when hooks change. Secondly, because reflection offers just as good, if not better, accuracy and if you're going to go through the effort of controlling what is rendered etc. you may as well just use reflection, but this is just my opinion to give you something to think about before people start claiming this as the future of SRL or the like.

Widget

2010-01-14 15:05:55

An "OpenGL hook" isn't the same as a Reflection hook, hooking OpenGL just means that you look at what's being rendered, and there's (apparently) nothing Jagex can do to stop it, although there's ways of seeing if someone has it hooked and there's (apparently) also ways of getting around being seen. What would make this harder is that we'd be basing this off models, which means we need to make a big database of the models first, and then an algorithm to match them up.

I think RSBot can actually access the 3D models though, so making a database could be as simple as walking around Runescape while running an RSBot script (I don't think SMART could do this because of the non-OOPness when it goes back through SCAR/Simba).

Personally, I say if he starts writing some real SCAR/Delphi/Plugin code, give him a promising newcomer and then instant-member once it finishes he he contributed a lot to it :)

mastaraymond

2010-01-14 16:01:38

From: mixster
I can understand wanting to keep skilled programmers in the community, but it seems that there is no proof of his Scar/Simba or SRL related knowledge or the like. It is suggested that he has his origins in aimbots in other games as he specifically mentioned them, so I would say this is just a bit of overspill from that.

In regards to the actual idea, as he seems quite happy to keep at it and I don't want to hurt that, so I'll say it here - I don't think it has much of a future. First of all, because it's easy to break as he mentions an "OpenGL hook" insinuating a weekly break when hooks change. Secondly, because reflection offers just as good, if not better, accuracy and if you're going to go through the effort of controlling what is rendered etc. you may as well just use reflection, but this is just my opinion to give you something to think about before people start claiming this as the future of SRL or the like.

Might not be the future, but it's always good to expand our horizon isn't it? We must always be open to new ideas and give them a chance. Even if it might just be for learning purposes only..

WT-Fakawi

2010-01-14 16:23:00

Make him promising newcomer.

mixster

2010-01-14 17:11:21

From: mastaraymond
Might not be the future, but it's always good to expand our horizon isn't it? We must always be open to new ideas and give them a chance. Even if it might just be for learning purposes only..


I agree, but I just don't want him to built up more than he should be because people think it will be an amazing innovation in macroing.

Method

2010-01-14 20:31:02

From: Widget
I think RSBot can actually access the 3D models though, so making a database could be as simple as walking around Runescape while running an RSBot script (I don't think SMART could do this because of the non-OOPness when it goes back through SCAR/Simba).


Any bot can access the models RuneScape renders using the model index/vertex fields. Quite a few of the classes in the client store references to their current models (players, npcs, objects, etc.).

I don't think RSBot has those fields hooked, though.

EDIT: Oh, and I don't think he needs to be a member right now.

The Claw

2010-01-14 22:08:53

Agreed with promising newcomer and SRL Member depending on where this project goes.