Hey Guys,
So i've been coding this for a while now it is a mw3 external console that sends commands to the game, but when i test it out it doesn't work on my mw3 theater mode could someone tell me whats wrong i would love them <3
not giving the code anymore..
(Jan 21, 2015 03:35 PM)Corios Wrote: ... you should probably say what part isn't working, we're not just going to guess and check every single part to see what isn't doing what it should, also, this would be good debugging practice non-the less.
This part doesn't work properly thanks :P
Code 'SEND COMMAND Code
Public Sub Send(ByVal cmd As String)
Try
If (Process.GetProcessesByName("iw5sp").Length <> 0) Then
Me.callBytes = BitConverter.GetBytes(&H457C90)
End If
If (cmd Is Nothing) Then
MessageBox.Show("nigguh you gotta type in the command before sending it...", "nigguh error", MessageBoxButtons.OK)
End If
If (mw3main._cBuf_addTextFuncAddress = IntPtr.Zero) Then
Dim ptr As IntPtr
mw3main._cBuf_addTextFuncAddress = mw3main.VirtualAllocEx(mw3main.ProcessHandle, IntPtr.Zero, Convert.ToUInt32(Stubs.WrapperTocBuf_AddText.Length), &H3000, &H40)
Me.cmdBytes = Encoding.ASCII.GetBytes((cmd + Convert.ToChar(0)))
mw3main.cmdAddress = mw3main.VirtualAllocEx(mw3main.ProcessHandle, IntPtr.Zero, Convert.ToUInt32(Me.cmdBytes.Length), &H3000, &H40)
Dim lpNumberOfBytesWritten As Integer = 0
mw3main.WriteProcessMemory(mw3main.ProcessHandle, mw3main.cmdAddress, Me.cmdBytes, Convert.ToUInt32(Me.cmdBytes.Length), lpNumberOfBytesWritten)
Array.Copy(BitConverter.GetBytes(mw3main.cmdAddress.ToInt32), 0, Stubs.WrapperTocBuf_AddText, 9, 4)
Array.Copy(Me.callBytes, 0, Stubs.WrapperTocBuf_AddText, &H10, 4)
mw3main.WriteProcessMemory(mw3main.ProcessHandle, mw3main._cBuf_addTextFuncAddress, Stubs.WrapperTocBuf_AddText, Convert.ToUInt32(Stubs.WrapperTocBuf_AddText.Length), lpNumberOfBytesWritten)
mw3main.CreateRemoteThread(mw3main.ProcessHandle, IntPtr.Zero, 0, mw3main._cBuf_addTextFuncAddress, IntPtr.Zero, 0, ptr)
If ((mw3main._cBuf_addTextFuncAddress <> IntPtr.Zero) AndAlso (mw3main.cmdAddress <> IntPtr.Zero)) Then
mw3main.VirtualFreeEx(mw3main.ProcessHandle, mw3main._cBuf_addTextFuncAddress, UIntPtr.op_Explicit(Convert.ToUInt32(Stubs.WrapperTocBuf_AddText.Length)), &H8000)
mw3main.VirtualFreeEx(mw3main.ProcessHandle, mw3main.cmdAddress, UIntPtr.op_Explicit(Convert.ToUInt32(Me.cmdBytes.Length)), &H8000)
End If
mw3main._cBuf_addTextFuncAddress = IntPtr.Zero
End If
Catch exception As Exception
MessageBox.Show(exception.ToString, " Nigguh Error", MessageBoxButtons.OK)
End Try
End Sub
(Jan 21, 2015 03:31 PM)nathan72389 Wrote: lol, nobody is going to recreate your whole app just to fix it for you.
how about you do some of the work on your own and then come back when you have narrowed down the problem.
lool in the posts bellow i just commented which section seems wrong ;)
(Jan 21, 2015 04:53 PM)nathan72389 Wrote: you do realize that i posted that before you posted your code?
anyway.,
all of those native calls have a reason why they failed.
I would suggest that you learn to debug your app and find out which line or call is failing and the reason why.
not pasting a wall of text and expecting other people to "find" the problem in (potentially) a program or application that we do not have.
it is easier for us to tell you what the problem is when you say something like :]
"my openprocess call is failing with the error of "no access" here is my code (insert the 1 line here)"
not just "here this does not work, fix it."
edit..
oh yeah, anyone that writes garbage like this:
Code MessageBox.Show("nigguh you gotta type in the command before sending it...", "nigguh error", MessageBoxButtons.OK)
deserves all the broken garbage code you get.
why you mad about a message box bruh... I can write the hell i want in them, the codes i wrote are working but the problem is i got a problem in the mw3 addresses now if you are here to be annoying af then you can leave pls.
(Jan 22, 2015 05:16 AM)$lick Wrote: He's the only one offering help you dense fuck.
If the error has nothing to do with VB then why post here?
I suggest learning how to get addresses from games.
Good start would be learning these stuff;
http://www.cheatengine.org/ http://www.ollydbg.de/
Also "problem in the mw3 addresses " doesn't help us at all diagnose the issue, what's the problem? What address is not working? Help us to help you.
ill try to figure it out i guess and sorry but the way he "offers" help is rude.
(Jan 22, 2015 11:45 AM)SаNk Wrote: +1
I tried to help him and he wouldn't even explain what he actually wanted. Literally all he told me is "I want the code for the send button.".
I got the convo bro, so don't lie. What happend was i told him 50 times to not use the code i coded and i also said. I need to figure out the code for the SendCommand function. Which he doesn't understand cause he doesn't know how to code for games...
(Jan 22, 2015 12:44 PM)nathan72389 Wrote: you just agreed with what he is saying
![[Image: Bdl9FXI.png]](https://i.imgur.com/Bdl9FXI.png)
SendCommand is a mw2 memory class address, if you knew what i was coding u would know.
(Jan 22, 2015 12:44 PM)nathan72389 Wrote: you just agreed with what he is saying
![[Image: Bdl9FXI.png]](https://i.imgur.com/Bdl9FXI.png)
SendCommand is a mw2 memory class address, if you knew what i was coding u would know.
(Jan 22, 2015 05:18 PM)Menalix Wrote: Looks like copy-paste, you should learn coding that would help you a huge step. btw are you using Windows XP?
its not copy paste I wrote this all by myself and i use windows 7 and i know coding :P
(Jan 23, 2015 10:52 PM)Menalix Wrote: Outdated addresses.
You use an accessflag for OpenProcess which is for XP.
The source is a mess
You don't know how to use breakpoints and do proper debugging.
And more..
Smells much of copy-paste.
Thanks I appreciate the love... But Idc think what you want :P
|