Any chance someone could upload this to fileshare site? Mmowned seems pretty unstable at the moment and I get a white screen when trying to access the attachment![]()
Any chance someone could upload this to fileshare site? Mmowned seems pretty unstable at the moment and I get a white screen when trying to access the attachment![]()
Unless you have a problem with the character getting wrong results on rotation you don't need to change anything, but I just realized that my maths were wrong when I set UNIT_ROT and OBJECT_ROT (I'm not sure these are the exact names). Should in (my) theory be 0xA instead of 0x10
I can't get to the attachments from the forum either ... I just get a blank page like the previous poster. I bet it has to do with the recent forum troubles.
Could you please upload it somewhere else also?
Same Problem for me, can't get the attachment from first post.
I downloaded an earlier Version, just for learning! It's very nice and logical made, great job!
Thanks so long!
Hmm, guess that reupload didn't work.
http://tinyurl.com/39svzdv should work![]()
Thank you so much for this. Memory reading has been killing me the last few days and I'm sure I will be able to figure it out using your sample code, even if I don't know C#.
Hey, this is my first post on the forum. First, thank you very much for this awesome code, it's very nice and useful.
Second, I've starting playing with it a bit and managed to get some very basic things done, but still, very cool for me.
But I've hit a wall, and I've read many many posts and can't get through that wall and I've decided to post a question, risking a major flame, but anyhow, I'll give it a shot, worst case scenario, I get flamed like a lot of first time poster. At least I donated, so I ain't the worst kind of leecher.
The question is about facing, and yes I've read other thread, like this one http://www.mmowned.com/forums/world-...ry-writes.html.
I was wondering a few things. How do I find the facing or bearing of my character ? When I use your bearing property in the location class, it always returns me 1 as value, no matter what location I feed it.
Second, and the most important, I know it has to do with Apoc's whitemagic but still, I'll ask the question. How do I write the facing to the memory to make my toon turn toward the a waypoint ?
I've tried this but it did nothing, I think it should turn my character 180 degrees around because Pi is 180 degrees in radian, but still, nothing seems to work.
I think there may be something else I need to write to memory, as I read in the thread, but don't know what exactly.Code:magic.Write((Pointers.PositionPointers.UNIT_ROT), Math.PI);
I will keep looking, but if anyone has any pointers, it would be very kind. I'd like to be able to have my character face the direction of the next waypoint, and then I'll move on to finding a way to make the toon move. I've looked at a lot of CTM thread but they were mostly pre 4.0.1, does it still work the same way, because it looks different.
Hope I was kindda clear, bracing for flaming !
Thx
@Millow:
At the time i've opened that thread i thought it would be a good idea to stay out of process, but later i've decided to use injection. You can do alot of things really easily (movment, execute lua, ...).
Most "out of process"-bots i've seen use simple key-sends and wait until they are more or less at the orientation they want, or they use CTM.
Anyway: I suggest to inject and simply call SetFacing
Well, obviously you won't get the characters facing from the Location class. Have you checked WoWLocalPlayer.Facing? Regarding the facing, if you had read as many threads as you claim you'd realize that the UNIT_ROT offset has to be written relative to the objectpointer, but I never tried changing the facing like that, so I wouldn't know.
Yup, I tried getting Facing directly from the WowLocalPlayer usingwhere I try to update the facing with the timer at each tick but still, I always get a facing of 0 or close, like 1.000E-30 or something like that. Anyhow, I guess I'll just read some more and try to figure out how to inject and use the SetFacing like fish2k suggested (thx btw !). And also, I did read a lot of thread, I'm not just "claiming" to have read them. Understanding them is another thing.Code:flbl.Text = Me.Facing.ToString();
Thx ! It worked, I finally see the facing of my toon, very nice + Rep !
Also, if I might add, I couldn't get ur DistanceTo function working so I wrote this oneIt works, it's basically a double Pythagore's law (don't know if this is the english name, it's the french name).Code:public double DonneDistance(Location loc) { var MyPosition = ObjectMgr.LocalPlayer.Location; double distanceXY = Math.Sqrt((Math.Pow(loc.Y - MyPosition.Y, 2)) + (Math.Pow(loc.X - MyPosition.X, 2))); double distance = Math.Sqrt((Math.Pow(distanceXY, 2)) + (Math.Pow(loc.Z - MyPosition.Z, 2))); return distance; }
Thank you again for your code and the updated offset, now I gotta play around with Apoc's WhiteMagic to get memory writing working !
Oh, and I downloaded the code from the tinyurl link above.
Last edited by Millow; 11-06-2010 at 10:52 AM.
While this works it is quite inefficientYou are doing 2 square roots where only 1 is needed. And normal multiplication is slightly faster than using Math.Pow
Code:float delta_x = loc.X - MyPosition.X; float delta_y = loc.Y - MyPosition.Y; float delta_z = loc.Z - MyPosition.Y; return Math.Sqrt(delta_x * delta_x + delta_y * delta_y + delta_z * delta_z);