Ana's fixed worked perfectly, I was able to go out of borders, too.
I took some clips with FRAPS of some interesting sights I found, rendering them together in Sony Vegas right now.
Meh, the demo won't even start for me, it just says Just Cause 2 demo has stopped working.
Ana's thing does not stop the timer
So I am now updating my driver, hopefully that fixes alot of it. I have it even on the lowest settings.
Erm, the demo doesn't run on XP????? what the actual fucking fuck are they thinking?
What the hell. Yesterday it was working like a charm, but now that I try to play it, it just crashes to desktop on startup. Doesn't even give a error message.
What should I do?
[editline]07:17AM[/editline]
[QUOTE=Cheesedragon;20586296]Erm, the demo doesn't run on XP????? what the actual fucking fuck are they thinking?[/QUOTE]
It doesn't work on Windows 98 either! WHAT THE FUCK WERE THEY THINKING!
[QUOTE=Cheesedragon;20586296]Erm, the demo doesn't run on XP????? what the actual fucking fuck are they thinking?[/QUOTE]
They were thinking that most people weren't using an old operating system anymore. :eng101:
Took a small plane at a nearby racing place, flew up and aimed it to a far off city so it would go there. Stunt Jumped.
Instant buy.
[media]http://www.youtube.com/watch?v=KKr5fxTOc_w[/media]
I love it so much.
Crash on startup, no error message. Worked great yesterday.
Solution?
[QUOTE=Cheesedragon;20586296]Erm, the demo doesn't run on XP????? what the actual fucking fuck are they thinking?[/QUOTE]
It uses DX10. XP does not support DX10. Ergo, no XP support.
I'm sad there isn't coop for this game, would be a blast to play with friends.
But whatever, this game has so much awesome irrelevant shit in it, therefore, it's AWESOME.
Oh it was the Anas modified exe that fucked shit up.
Anyone else had this?
Has anyone actually managed to jump out of a helicopter at a high altitude, and get back in it as you were falling down?
I keep getting knocked off, but I'm assuming that's only because I'm hitting the rotors. Maybe if you come up from the bottom...
I jammed the shift key while in a helicopter for a few minutes, then flew down for several minutes, then my helicopter hit me and exploded. What the fuck.
[QUOTE=FunnyBunny;20586432]Has anyone actually managed to jump out of a helicopter at a high altitude, and get back in it as you were falling down?
I keep getting knocked off, but I'm assuming that's only because I'm hitting the rotors. Maybe if you come up from the bottom...[/QUOTE]
Apparently it's impossible. However, the devs did very briefly allude to "catching" the chopper they jumped out of. Though I have yet to see one successful re-entry to your air vehicles (the idea that you are hitting your rotors could be a good explanation, and with planes the plane may need to still be upright to get into the proper stunt position)
[QUOTE=FunnyBunny;20586432]Has anyone actually managed to jump out of a helicopter at a high altitude, and get back in it as you were falling down?
I keep getting knocked off, but I'm assuming that's only because I'm hitting the rotors. Maybe if you come up from the bottom...[/QUOTE]
Tried it as well but I keep on getting detached, I might try it with the plane later on.
I managed to get back in my heli as it was falling. You have to get it from the tail. It's really difficult to regain control though
[QUOTE=Zatharon;20585443][url]http://rapidshare.com/files/359600867/JustCause2.CT.html[/url]
I got it to work, anyone who cant get it to work, get cheat engine, load up this config, freeze the three values, first is time, second is grenade ammo, 3rd is C4, freeze 'nades and c4 and you'll have unlimited.[/QUOTE]
[quote]This file is neither allocated to a Premium Account, or a Collector's Account, and can therefore only be downloaded 10 times.
This limit is reached.
To download this file, the uploader either needs to transfer this file into his/her Collector's Account, or upload the file again. The file can later be moved to a Collector's Account. The uploader just needs to click the delete link of the file to get further information.[/quote]
well still new to this: how do I make my demo unlimited?
gonna try this:
[QUOTE=Nioreh83;20578365]Hi all!
Just wanted to tell you how to stop the REAL timer with Cheat Engine and not just the displayed counter.
Probably why noone found the correct value in Cheat Engine before is because the timer actually does not decrease, it increases! It seems Avalanche was a bit tricky on this one
The adress seems to change every time so there is no definite adress to lock. It always seems to begin in 1A5 though.
1) Start Just Cause 2, trigger the timer by jumping off the platform. Open the PDA by pressing F1 and check what the timer says. Memorize it, or write it down.
2) Alt-tab out and start CheatEngine. In CheatEngine, browse the processes and select JustCause2.exe. Choose 'Unknown initial value' from the 'Scan type' drop-down list, '4 Bytes', and hit the 'First Scan' button.
3) Go in-game again, un-pause and let some time go by.
4) Again, open the PDA and check how many seconds have gone by. Alt-tab back to CheatEngine and search for a new value, this time a 'Value increased by...' (or, as listed by the program, 'Increased value by...'), and enter the appropriate value (the time in seconds that passed) in the 'Value:' box. Hit 'Next Scan'.
5) Repeat steps 3 and 4 until you find the correct value, usually an address starting with '1A5'.
6) When found, double-click it to add it to the box below. Freeze it and play for as long as you want.
I can assure you that it works. I have played through the demo for many hours and finished 100% of all the settlements.
[img]http://img156.imageshack.us/img156/4778/democomplete.png[/img][/QUOTE]
hope it works...
I hate it when you jump out of a helicopter, it automatically goes into, "crash and burn," mode.
In other words, it doesn't just fall out of the sky and get damaged by the in-game physics; it just sorts of spirals out of control.
[QUOTE=The Vman;20586562]Apparently it's impossible. However, the devs did very briefly allude to "catching" the chopper they jumped out of. Though I have yet to see one successful re-entry to your air vehicles (the idea that you are hitting your rotors could be a good explanation, and with planes the plane may need to still be upright to get into the proper stunt position)[/QUOTE]
I've done it before. I jumped out of a chopper, got below it, then grappled on and pressed E.
My name is Bolo Santosi. I am the leader of the revolutionary army known as the Reapers.
Our goal is for the people of Facepunch to break the time and map limit of the Just Cause 2 demo... and have unlimited fun.
I have found an able bodied... comrade. He is the G, and I am the H. They say we are the best...
Instructions:
Install Autoit.
Run the demo.
When you get to the main menu:
Launch Scite (autoit editor).
Paste this:
[code]
;;================================================================================
;; Includes
;;================================================================================
#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>
#RequireAdmin
#NoTrayIcon
;;================================================================================
;; Main
;;================================================================================
Opt("WinTitleMatchMode", 4)
SetPrivilege("SeDebugPrivilege", 1)
Global $ProcessID = WinGetProcess("Just Cause 2 Demo", "")
Dim $ProcessFound = 0
While $ProcessFound = 0
If $ProcessID = -1 Then
MsgBox(4096, "Error", "No process found.")
Exit(1)
EndIf
$ProcessFound = 1
WEnd
WinActivate("Just Cause 2 Demo")
$wc = WinGetPos("Just Cause 2 Demo")
$x = $wc[0] + ($wc[2] / 2) - 149/2
$y = $wc[1] + ($wc[3] / 2) - 42/2
GUICreate("BOLOPatch", 149, 42, $x, $y, BitOR($WS_SYSMENU,$WS_CAPTION,$WS_POPUP,$WS_POPUPWINDOW,$WS_BORDER))
GUICtrlCreateLabel("Status:", 0, 0, 37, 17, $SS_CENTER)
$status = GUICtrlCreateLabel("", 40, 0, 107, 17, $SS_CENTER, $WS_EX_CLIENTEDGE)
GUICtrlCreateLabel("Coding by G&H Productions", 0, 24, 148, 17, BitOR($SS_CENTER,$SS_NOPREFIX), $WS_EX_CLIENTEDGE)
GUISetState()
Patch()
While 1
$msg = GUIGetMsg()
Switch $msg
Case $GUI_EVENT_CLOSE
Exit
EndSwitch
WEnd
;;================================================================================
;; Patch
;;================================================================================
Func Patch()
$DLL = _MemoryOpen($ProcessID)
If @Error Then
GUICtrlSetData($status, "Patching failure.")
EndIf
_MemoryWrite(0x004FE17D, $DLL, 0x90, "byte");;;
_MemoryWrite(0x004FE17E, $DLL, 0x90, "byte");;; TIME LIMIT DISABLE
_MemoryWrite(0x004FE17F, $DLL, 0x90, "byte");;;
_MemoryWrite(0x007F2C95, $DLL, 0x90, "byte");;;
_MemoryWrite(0x007F2C96, $DLL, 0x90, "byte");;;
_MemoryWrite(0x007F2C97, $DLL, 0x90, "byte");;; MAP LIMIT DISABLE
_MemoryWrite(0x007F2C98, $DLL, 0x90, "byte");;;
_MemoryWrite(0x007F2C99, $DLL, 0x90, "byte");;;
_MemoryClose($DLL)
GUICtrlSetData($status, "Patching success!")
EndFunc
;;;
;; NOMADMEMORY EXTRACT
;;;
Func _MemoryOpen($iv_Pid, $iv_DesiredAccess = 0x1F0FFF, $iv_InheritHandle = 1)
If Not ProcessExists($iv_Pid) Then
SetError(1)
Return 0
EndIf
Local $ah_Handle[2] = [DllOpen('kernel32.dll')]
If @Error Then
SetError(2)
Return 0
EndIf
Local $av_OpenProcess = DllCall($ah_Handle[0], 'int', 'OpenProcess', 'int', $iv_DesiredAccess, 'int', $iv_InheritHandle, 'int', $iv_Pid)
If @Error Then
DllClose($ah_Handle[0])
SetError(3)
Return 0
EndIf
$ah_Handle[1] = $av_OpenProcess[0]
Return $ah_Handle
EndFunc
Func _MemoryWrite($iv_Address, $ah_Handle, $v_Data, $sv_Type = 'dword')
If Not IsArray($ah_Handle) Then
SetError(1)
Return 0
EndIf
Local $v_Buffer = DllStructCreate($sv_Type)
If @Error Then
SetError(@Error + 1)
Return 0
Else
DllStructSetData($v_Buffer, 1, $v_Data)
If @Error Then
SetError(6)
Return 0
EndIf
EndIf
DllCall($ah_Handle[0], 'int', 'WriteProcessMemory', 'int', $ah_Handle[1], 'int', $iv_Address, 'ptr', DllStructGetPtr($v_Buffer), 'int', DllStructGetSize($v_Buffer), 'int', '')
If Not @Error Then
Return 1
Else
SetError(7)
Return 0
EndIf
EndFunc
Func _MemoryClose($ah_Handle)
If Not IsArray($ah_Handle) Then
SetError(1)
Return 0
EndIf
DllCall($ah_Handle[0], 'int', 'CloseHandle', 'int', $ah_Handle[1])
If Not @Error Then
DllClose($ah_Handle[0])
Return 1
Else
DllClose($ah_Handle[0])
SetError(2)
Return 0
EndIf
EndFunc
Func SetPrivilege( $privilege, $bEnable )
Const $MY_TOKEN_ADJUST_PRIVILEGES = 0x0020
Const $MY_TOKEN_QUERY = 0x0008
Const $MY_SE_PRIVILEGE_ENABLED = 0x0002
Local $hToken, $SP_auxret, $SP_ret, $hCurrProcess, $nTokens, $nTokenIndex, $priv
$nTokens = 1
$LUID = DLLStructCreate("dword;int")
If IsArray($privilege) Then $nTokens = UBound($privilege)
$TOKEN_PRIVILEGES = DLLStructCreate("dword;dword[" & (3 * $nTokens) & "]")
$NEWTOKEN_PRIVILEGES = DLLStructCreate("dword;dword[" & (3 * $nTokens) & "]")
$hCurrProcess = DLLCall("kernel32.dll","hwnd","GetCurrentProcess")
$SP_auxret = DLLCall("advapi32.dll","int","OpenProcessToken","hwnd",$hCurrProcess[0], _
"int",BitOR($MY_TOKEN_ADJUST_PRIVILEGES,$MY_TOKEN_QUERY),"int*",0)
If $SP_auxret[0] Then
$hToken = $SP_auxret[3]
DLLStructSetData($TOKEN_PRIVILEGES,1,1)
$nTokenIndex = 1
While $nTokenIndex <= $nTokens
If IsArray($privilege) Then
$priv = $privilege[$nTokenIndex-1]
Else
$priv = $privilege
EndIf
$ret = DLLCall("advapi32.dll","int","LookupPrivilegeValue","str","","str",$priv, _
"ptr",DLLStructGetPtr($LUID))
If $ret[0] Then
If $bEnable Then
DLLStructSetData($TOKEN_PRIVILEGES,2,$MY_SE_PRIVILEGE_ENABLED,(3 * $nTokenIndex))
Else
DLLStructSetData($TOKEN_PRIVILEGES,2,0,(3 * $nTokenIndex))
EndIf
DLLStructSetData($TOKEN_PRIVILEGES,2,DllStructGetData($LUID,1),(3 * ($nTokenIndex-1)) + 1)
DLLStructSetData($TOKEN_PRIVILEGES,2,DllStructGetData($LUID,2),(3 * ($nTokenIndex-1)) + 2)
DLLStructSetData($LUID,1,0)
DLLStructSetData($LUID,2,0)
EndIf
$nTokenIndex += 1
WEnd
$ret = DLLCall("advapi32.dll","int","AdjustTokenPrivileges","hwnd",$hToken,"int",0, _
"ptr",DllStructGetPtr($TOKEN_PRIVILEGES),"int",DllStructGetSize($NEWTOKEN_PRIVILEGES), _
"ptr",DllStructGetPtr($NEWTOKEN_PRIVILEGES),"int*",0)
$f = DLLCall("kernel32.dll","int","GetLastError")
EndIf
$NEWTOKEN_PRIVILEGES=0
$TOKEN_PRIVILEGES=0
$LUID=0
If $SP_auxret[0] = 0 Then Return 0
$SP_auxret = DLLCall("kernel32.dll","int","CloseHandle","hwnd",$hToken)
If Not $ret[0] And Not $SP_auxret[0] Then Return 0
return $ret[0]
EndFunc
[/code]
Save it as anyfilenameyouwant.au3
Press F5 to run the script.
Now you won't have the time / map limit.
Enjoy.
NB: Bolo Santosi is not responsible if you fuck this shit up. The code is visible, so no, it doesn't have any viruses.
NB2: If you run this before the main menu loads (press enter to ...) the game WILL crash.
[QUOTE=BOLOPatch;20586852]My name is Bolo Santosi. I am the leader of the revolutionary army known as the Reapers.
Our goal is for the people of Facepunch to break the time and map limit of the Just Cause 2 demo... and have unlimited fun.
I have found an able bodied... comrade. He is the G, and I am the H. They say we are the best...
Instructions:
Install Autoit.
Run the demo.
When you get to the main menu:
Launch Scite (autoit editor).
Paste this:
[code]
;;================================================================================
;; Includes
;;================================================================================
#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>
#RequireAdmin
#NoTrayIcon
;;================================================================================
;; Main
;;================================================================================
Opt("WinTitleMatchMode", 4)
SetPrivilege("SeDebugPrivilege", 1)
Global $ProcessID = WinGetProcess("Just Cause 2 Demo", "")
Dim $ProcessFound = 0
While $ProcessFound = 0
If $ProcessID = -1 Then
MsgBox(4096, "Error", "No process found.")
Exit(1)
EndIf
$ProcessFound = 1
WEnd
WinActivate("Just Cause 2 Demo")
$wc = WinGetPos("Just Cause 2 Demo")
$x = $wc[0] + ($wc[2] / 2) - 149/2
$y = $wc[1] + ($wc[3] / 2) - 42/2
GUICreate("BOLOPatch", 149, 42, $x, $y, BitOR($WS_SYSMENU,$WS_CAPTION,$WS_POPUP,$WS_POPUPWINDOW,$WS_BORDER))
GUICtrlCreateLabel("Status:", 0, 0, 37, 17, $SS_CENTER)
$status = GUICtrlCreateLabel("", 40, 0, 107, 17, $SS_CENTER, $WS_EX_CLIENTEDGE)
GUICtrlCreateLabel("Coding by G&H Productions", 0, 24, 148, 17, BitOR($SS_CENTER,$SS_NOPREFIX), $WS_EX_CLIENTEDGE)
GUISetState()
Patch()
While 1
$msg = GUIGetMsg()
Switch $msg
Case $GUI_EVENT_CLOSE
Exit
EndSwitch
WEnd
;;================================================================================
;; Patch
;;================================================================================
Func Patch()
$DLL = _MemoryOpen($ProcessID)
If @Error Then
GUICtrlSetData($status, "Patching failure.")
EndIf
_MemoryWrite(0x004FE17D, $DLL, 0x90, "byte");;;
_MemoryWrite(0x004FE17E, $DLL, 0x90, "byte");;; TIME LIMIT DISABLE
_MemoryWrite(0x004FE17F, $DLL, 0x90, "byte");;;
_MemoryWrite(0x007F2C95, $DLL, 0x90, "byte");;;
_MemoryWrite(0x007F2C96, $DLL, 0x90, "byte");;;
_MemoryWrite(0x007F2C97, $DLL, 0x90, "byte");;; MAP LIMIT DISABLE
_MemoryWrite(0x007F2C98, $DLL, 0x90, "byte");;;
_MemoryWrite(0x007F2C99, $DLL, 0x90, "byte");;;
_MemoryClose($DLL)
GUICtrlSetData($status, "Patching success!")
EndFunc
;;;
;; NOMADMEMORY EXTRACT
;;;
Func _MemoryOpen($iv_Pid, $iv_DesiredAccess = 0x1F0FFF, $iv_InheritHandle = 1)
If Not ProcessExists($iv_Pid) Then
SetError(1)
Return 0
EndIf
Local $ah_Handle[2] = [DllOpen('kernel32.dll')]
If @Error Then
SetError(2)
Return 0
EndIf
Local $av_OpenProcess = DllCall($ah_Handle[0], 'int', 'OpenProcess', 'int', $iv_DesiredAccess, 'int', $iv_InheritHandle, 'int', $iv_Pid)
If @Error Then
DllClose($ah_Handle[0])
SetError(3)
Return 0
EndIf
$ah_Handle[1] = $av_OpenProcess[0]
Return $ah_Handle
EndFunc
Func _MemoryWrite($iv_Address, $ah_Handle, $v_Data, $sv_Type = 'dword')
If Not IsArray($ah_Handle) Then
SetError(1)
Return 0
EndIf
Local $v_Buffer = DllStructCreate($sv_Type)
If @Error Then
SetError(@Error + 1)
Return 0
Else
DllStructSetData($v_Buffer, 1, $v_Data)
If @Error Then
SetError(6)
Return 0
EndIf
EndIf
DllCall($ah_Handle[0], 'int', 'WriteProcessMemory', 'int', $ah_Handle[1], 'int', $iv_Address, 'ptr', DllStructGetPtr($v_Buffer), 'int', DllStructGetSize($v_Buffer), 'int', '')
If Not @Error Then
Return 1
Else
SetError(7)
Return 0
EndIf
EndFunc
Func _MemoryClose($ah_Handle)
If Not IsArray($ah_Handle) Then
SetError(1)
Return 0
EndIf
DllCall($ah_Handle[0], 'int', 'CloseHandle', 'int', $ah_Handle[1])
If Not @Error Then
DllClose($ah_Handle[0])
Return 1
Else
DllClose($ah_Handle[0])
SetError(2)
Return 0
EndIf
EndFunc
Func SetPrivilege( $privilege, $bEnable )
Const $MY_TOKEN_ADJUST_PRIVILEGES = 0x0020
Const $MY_TOKEN_QUERY = 0x0008
Const $MY_SE_PRIVILEGE_ENABLED = 0x0002
Local $hToken, $SP_auxret, $SP_ret, $hCurrProcess, $nTokens, $nTokenIndex, $priv
$nTokens = 1
$LUID = DLLStructCreate("dword;int")
If IsArray($privilege) Then $nTokens = UBound($privilege)
$TOKEN_PRIVILEGES = DLLStructCreate("dword;dword[" & (3 * $nTokens) & "]")
$NEWTOKEN_PRIVILEGES = DLLStructCreate("dword;dword[" & (3 * $nTokens) & "]")
$hCurrProcess = DLLCall("kernel32.dll","hwnd","GetCurrentProcess")
$SP_auxret = DLLCall("advapi32.dll","int","OpenProcessToken","hwnd",$hCurrProcess[0], _
"int",BitOR($MY_TOKEN_ADJUST_PRIVILEGES,$MY_TOKEN_QUERY),"int*",0)
If $SP_auxret[0] Then
$hToken = $SP_auxret[3]
DLLStructSetData($TOKEN_PRIVILEGES,1,1)
$nTokenIndex = 1
While $nTokenIndex <= $nTokens
If IsArray($privilege) Then
$priv = $privilege[$nTokenIndex-1]
Else
$priv = $privilege
EndIf
$ret = DLLCall("advapi32.dll","int","LookupPrivilegeValue","str","","str",$priv, _
"ptr",DLLStructGetPtr($LUID))
If $ret[0] Then
If $bEnable Then
DLLStructSetData($TOKEN_PRIVILEGES,2,$MY_SE_PRIVILEGE_ENABLED,(3 * $nTokenIndex))
Else
DLLStructSetData($TOKEN_PRIVILEGES,2,0,(3 * $nTokenIndex))
EndIf
DLLStructSetData($TOKEN_PRIVILEGES,2,DllStructGetData($LUID,1),(3 * ($nTokenIndex-1)) + 1)
DLLStructSetData($TOKEN_PRIVILEGES,2,DllStructGetData($LUID,2),(3 * ($nTokenIndex-1)) + 2)
DLLStructSetData($LUID,1,0)
DLLStructSetData($LUID,2,0)
EndIf
$nTokenIndex += 1
WEnd
$ret = DLLCall("advapi32.dll","int","AdjustTokenPrivileges","hwnd",$hToken,"int",0, _
"ptr",DllStructGetPtr($TOKEN_PRIVILEGES),"int",DllStructGetSize($NEWTOKEN_PRIVILEGES), _
"ptr",DllStructGetPtr($NEWTOKEN_PRIVILEGES),"int*",0)
$f = DLLCall("kernel32.dll","int","GetLastError")
EndIf
$NEWTOKEN_PRIVILEGES=0
$TOKEN_PRIVILEGES=0
$LUID=0
If $SP_auxret[0] = 0 Then Return 0
$SP_auxret = DLLCall("kernel32.dll","int","CloseHandle","hwnd",$hToken)
If Not $ret[0] And Not $SP_auxret[0] Then Return 0
return $ret[0]
EndFunc
[/code]
Save it as anyfilenameyouwant.au3
Press F5 to run the script.
Now you won't have the time / map limit.
Enjoy.
NB: Bolo Santosi is not responsible if you fuck this shit up. The code is visible, so no, it doesn't have any viruses.
NB2: If you run this before the main menu loads (press enter to ...) the game WILL crash.[/QUOTE]
Wait... we can make scripts for this game?!
Someone script some grappling hook upgrades.
No, the script is Autoit script. It's a relatively high level programming language for noobs (you).
[QUOTE=BOLOPatch;20586883]No, the script is Autoit script. It's a relatively high level programming language for noobs (you).[/QUOTE]
Ohhhhhhhhhhhhhhhhhhhhhh
I see you joined just to give us that message... you been lurking on fp for long?
[url]http://i49.tinypic.com/20jsltu.jpg[/url]
And some proof for the skeptic.
(Img is now a URL because it was too large.)
gmaster: every now and then :P
[QUOTE=BOLOPatch;20586929][img]http://i49.tinypic.com/20jsltu.jpg[/img]
And some proof for the skeptic.[/QUOTE]
Yeah, we've been leaving the map boundaries for about 5 pages now.
Thanks very much. I'll test it out after I'm done in bad company 2.
[editline]08:43AM[/editline]
[QUOTE=Foogooman;20586936]Yeah, we've been leaving the map boundaries for about 5 pages now.[/QUOTE]
Not with the timer off... notice the time limit: 00:30:30
[QUOTE=BOLOPatch;20586852]My name is Bolo Santosi. I am the leader of the revolutionary army known as the Reapers.
Our goal is for the people of Facepunch to break the time and map limit of the Just Cause 2 demo... and have unlimited fun.
I have found an able bodied... comrade. He is the G, and I am the H. They say we are the best...
Instructions:
Install Autoit.
Run the demo.
When you get to the main menu:
Launch Scite (autoit editor).
Paste this:
[code]
;;================================================================================
;; Includes
;;================================================================================
#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>
#RequireAdmin
#NoTrayIcon
;;================================================================================
;; Main
;;================================================================================
Opt("WinTitleMatchMode", 4)
SetPrivilege("SeDebugPrivilege", 1)
Global $ProcessID = WinGetProcess("Just Cause 2 Demo", "")
Dim $ProcessFound = 0
While $ProcessFound = 0
If $ProcessID = -1 Then
MsgBox(4096, "Error", "No process found.")
Exit(1)
EndIf
$ProcessFound = 1
WEnd
WinActivate("Just Cause 2 Demo")
$wc = WinGetPos("Just Cause 2 Demo")
$x = $wc[0] + ($wc[2] / 2) - 149/2
$y = $wc[1] + ($wc[3] / 2) - 42/2
GUICreate("BOLOPatch", 149, 42, $x, $y, BitOR($WS_SYSMENU,$WS_CAPTION,$WS_POPUP,$WS_POPUPWINDOW,$WS_BORDER))
GUICtrlCreateLabel("Status:", 0, 0, 37, 17, $SS_CENTER)
$status = GUICtrlCreateLabel("", 40, 0, 107, 17, $SS_CENTER, $WS_EX_CLIENTEDGE)
GUICtrlCreateLabel("Coding by G&H Productions", 0, 24, 148, 17, BitOR($SS_CENTER,$SS_NOPREFIX), $WS_EX_CLIENTEDGE)
GUISetState()
Patch()
While 1
$msg = GUIGetMsg()
Switch $msg
Case $GUI_EVENT_CLOSE
Exit
EndSwitch
WEnd
;;================================================================================
;; Patch
;;================================================================================
Func Patch()
$DLL = _MemoryOpen($ProcessID)
If @Error Then
GUICtrlSetData($status, "Patching failure.")
EndIf
_MemoryWrite(0x004FE17D, $DLL, 0x90, "byte");;;
_MemoryWrite(0x004FE17E, $DLL, 0x90, "byte");;; TIME LIMIT DISABLE
_MemoryWrite(0x004FE17F, $DLL, 0x90, "byte");;;
_MemoryWrite(0x007F2C95, $DLL, 0x90, "byte");;;
_MemoryWrite(0x007F2C96, $DLL, 0x90, "byte");;;
_MemoryWrite(0x007F2C97, $DLL, 0x90, "byte");;; MAP LIMIT DISABLE
_MemoryWrite(0x007F2C98, $DLL, 0x90, "byte");;;
_MemoryWrite(0x007F2C99, $DLL, 0x90, "byte");;;
_MemoryClose($DLL)
GUICtrlSetData($status, "Patching success!")
EndFunc
;;;
;; NOMADMEMORY EXTRACT
;;;
Func _MemoryOpen($iv_Pid, $iv_DesiredAccess = 0x1F0FFF, $iv_InheritHandle = 1)
If Not ProcessExists($iv_Pid) Then
SetError(1)
Return 0
EndIf
Local $ah_Handle[2] = [DllOpen('kernel32.dll')]
If @Error Then
SetError(2)
Return 0
EndIf
Local $av_OpenProcess = DllCall($ah_Handle[0], 'int', 'OpenProcess', 'int', $iv_DesiredAccess, 'int', $iv_InheritHandle, 'int', $iv_Pid)
If @Error Then
DllClose($ah_Handle[0])
SetError(3)
Return 0
EndIf
$ah_Handle[1] = $av_OpenProcess[0]
Return $ah_Handle
EndFunc
Func _MemoryWrite($iv_Address, $ah_Handle, $v_Data, $sv_Type = 'dword')
If Not IsArray($ah_Handle) Then
SetError(1)
Return 0
EndIf
Local $v_Buffer = DllStructCreate($sv_Type)
If @Error Then
SetError(@Error + 1)
Return 0
Else
DllStructSetData($v_Buffer, 1, $v_Data)
If @Error Then
SetError(6)
Return 0
EndIf
EndIf
DllCall($ah_Handle[0], 'int', 'WriteProcessMemory', 'int', $ah_Handle[1], 'int', $iv_Address, 'ptr', DllStructGetPtr($v_Buffer), 'int', DllStructGetSize($v_Buffer), 'int', '')
If Not @Error Then
Return 1
Else
SetError(7)
Return 0
EndIf
EndFunc
Func _MemoryClose($ah_Handle)
If Not IsArray($ah_Handle) Then
SetError(1)
Return 0
EndIf
DllCall($ah_Handle[0], 'int', 'CloseHandle', 'int', $ah_Handle[1])
If Not @Error Then
DllClose($ah_Handle[0])
Return 1
Else
DllClose($ah_Handle[0])
SetError(2)
Return 0
EndIf
EndFunc
Func SetPrivilege( $privilege, $bEnable )
Const $MY_TOKEN_ADJUST_PRIVILEGES = 0x0020
Const $MY_TOKEN_QUERY = 0x0008
Const $MY_SE_PRIVILEGE_ENABLED = 0x0002
Local $hToken, $SP_auxret, $SP_ret, $hCurrProcess, $nTokens, $nTokenIndex, $priv
$nTokens = 1
$LUID = DLLStructCreate("dword;int")
If IsArray($privilege) Then $nTokens = UBound($privilege)
$TOKEN_PRIVILEGES = DLLStructCreate("dword;dword[" & (3 * $nTokens) & "]")
$NEWTOKEN_PRIVILEGES = DLLStructCreate("dword;dword[" & (3 * $nTokens) & "]")
$hCurrProcess = DLLCall("kernel32.dll","hwnd","GetCurrentProcess")
$SP_auxret = DLLCall("advapi32.dll","int","OpenProcessToken","hwnd",$hCurrProcess[0], _
"int",BitOR($MY_TOKEN_ADJUST_PRIVILEGES,$MY_TOKEN_QUERY),"int*",0)
If $SP_auxret[0] Then
$hToken = $SP_auxret[3]
DLLStructSetData($TOKEN_PRIVILEGES,1,1)
$nTokenIndex = 1
While $nTokenIndex <= $nTokens
If IsArray($privilege) Then
$priv = $privilege[$nTokenIndex-1]
Else
$priv = $privilege
EndIf
$ret = DLLCall("advapi32.dll","int","LookupPrivilegeValue","str","","str",$priv, _
"ptr",DLLStructGetPtr($LUID))
If $ret[0] Then
If $bEnable Then
DLLStructSetData($TOKEN_PRIVILEGES,2,$MY_SE_PRIVILEGE_ENABLED,(3 * $nTokenIndex))
Else
DLLStructSetData($TOKEN_PRIVILEGES,2,0,(3 * $nTokenIndex))
EndIf
DLLStructSetData($TOKEN_PRIVILEGES,2,DllStructGetData($LUID,1),(3 * ($nTokenIndex-1)) + 1)
DLLStructSetData($TOKEN_PRIVILEGES,2,DllStructGetData($LUID,2),(3 * ($nTokenIndex-1)) + 2)
DLLStructSetData($LUID,1,0)
DLLStructSetData($LUID,2,0)
EndIf
$nTokenIndex += 1
WEnd
$ret = DLLCall("advapi32.dll","int","AdjustTokenPrivileges","hwnd",$hToken,"int",0, _
"ptr",DllStructGetPtr($TOKEN_PRIVILEGES),"int",DllStructGetSize($NEWTOKEN_PRIVILEGES), _
"ptr",DllStructGetPtr($NEWTOKEN_PRIVILEGES),"int*",0)
$f = DLLCall("kernel32.dll","int","GetLastError")
EndIf
$NEWTOKEN_PRIVILEGES=0
$TOKEN_PRIVILEGES=0
$LUID=0
If $SP_auxret[0] = 0 Then Return 0
$SP_auxret = DLLCall("kernel32.dll","int","CloseHandle","hwnd",$hToken)
If Not $ret[0] And Not $SP_auxret[0] Then Return 0
return $ret[0]
EndFunc
[/code]Save it as anyfilenameyouwant.au3
Press F5 to run the script.
Now you won't have the time / map limit.
Enjoy.
NB: Bolo Santosi is not responsible if you fuck this shit up. The code is visible, so no, it doesn't have any viruses.
NB2: If you run this before the main menu loads (press enter to ...) the game WILL crash.[/QUOTE]
Show us your tits.
Sorry, you need to Log In to post a reply to this thread.