Sniper: Ghost Warrior 3 - Enable CryEngine Console

Upload your cheat tables here (No requests)
Post Reply
User avatar
STN
Founder
Founder
Posts: 4426
Joined: Thu Mar 02, 2017 7:48 pm
Reputation: 3423

Sniper: Ghost Warrior 3 - Enable CryEngine Console

Post by STN »

Hello folks.

Ever since SGW3 went out, soon followed by Prey, I became interested in CryEngine. So much, that I got to study it quite a bit, making use of the available free SDK and various online sources. In time, I've figured out that most games have a working console in release build, but there's a catch: the console is disabled via a BOOL and the rendering text is not processed as some auxiliary rendering functions are not compiled (they're available only in the debug build). However, with proper enabling, the console accepts input from the keyboard (you just won't see the text being typed on screen or the query's response -- e.g.: querying CVars for their status/value).

The reason no text is displayed in the console (although it's there) is GetIRenderAuxGeom member-function in IRenderer class doesn't return the appropriate pointer. Next after this call, another is executed, and the offset to the member-function points to a RETN (thus nothing gets executed, as opposed to the behavior seen while debugging the SDK demo game). The function that should've been executed is called DrawStringImmediate, declared in IRenderAuxGeom.h file. But, as mentioned, it's not compiled in release builds. Smarty developers, eh? :)

I've tried these days to emulate it (rip the SDK code, fix it to work with SGW3 -- although I don't have all sub-helper-functions available -- and call it from the CryFont reference making use of it), but there's too much dilly-dallying that I ended up using it as is.

In short, the attached script:

- disables sys_DeactivateConsole CVar in IConsole (sets it to 0)
- enables a BOOL (sets it to 1) in IConsole I named bUnrestrictCVars (this allows you to query/set CVars through the console -- e.g.: g_godMode 2 [Enter] -- no need to use my other table anymore for this :P)
- patches two locations dealing with console commands whitelisting and CVars considered VF_CHEATS
- allows you to see what you type in Cheat Engine in a referenced buffer (you'll have to use windowed mode to see what you're typing; if sure on your typing skills, don't need to look at it)
- note the console is and will always be "empty", looking like an Unix password input line (you can type, the text is there, but you won't see it)

Demo video of usage, including some nifty console commands/variables:



List of useful console commands/variables:
SpoilerShow
Let me know if you have any questions; I strongly encourage you to post feedback.

Soon to follow is the mini-SDK for this game ;) It's based on the logic of the work done here by daemonium, but applied to SGW3 on an x64 CryEngine: https://www.fearlessrevolution.com/forum/othe ... i-sdk.html. According to Wiki ([Link]), SGW2 is running on CryEngine 3 (it's actually 3.4.0 from investigating), x86, while SGW3 is running on CryEngine 4, x64. So yeah, it took a bit to figure out the mapping and order of the class members.

BR,
Sun

How to use this cheat table?
  1. Install Cheat Engine
  2. Double-click the .CT file in order to open it.
  3. Click the PC icon in Cheat Engine in order to select the game process.
  4. Keep the list.
  5. Activate the trainer options by checking boxes or setting values from 0 to 1
Attachments
SGW3.CT
(10.39 KiB) Downloaded 599 times

jonasbeckman
Expert Cheater
Expert Cheater
Posts: 307
Joined: Sat May 06, 2017 1:26 pm
Reputation: 22

Re: Sniper: Ghost Warrior 3 - Enable CryEngine Console

Post by jonasbeckman »

Nice, I've been using the remote console for Cry-Engine games ( [Link] ) but it's a bit flaky depending on just what the game you're using it against might be missing or have locked away in some form, also varies depending on the Cry-Engine version used since cvars and other functions can and will differ.

66Nemesis66
Noobzor
Noobzor
Posts: 5
Joined: Tue Aug 01, 2017 1:45 pm
Reputation: 0

Re: Sniper: Ghost Warrior 3 - Enable CryEngine Console

Post by 66Nemesis66 »

hi
I become a Lua Error

Output
Error:Failure determining what SSystemGlobalEnvironment_AOB means
Error:Failure determining what SSystemGlobalEnvironment_AOB means

angelotti
Noobzor
Noobzor
Posts: 9
Joined: Wed Sep 06, 2017 10:35 am
Reputation: 1

Re: Sniper: Ghost Warrior 3 - Enable CryEngine Console

Post by angelotti »

SunBeam wrote:
Sun Aug 06, 2017 7:02 pm
...
66Nemesis66 wrote:
Sun Aug 06, 2017 6:47 pm
hi
I become a Lua Error

Output
Error:Failure determining what SSystemGlobalEnvironment_AOB means
Error:Failure determining what SSystemGlobalEnvironment_AOB means
Open game (let it load fully till main menu), then run the table. If you have CE open and load table manually, you'll have to run the Lua code and manually select SGW3.exe, in this order; else Lua code will get stuck in a loop, waiting for SGW3.exe process on attach. So: game first, run table afterwards.
I'm getting this error too. I'm executing the table with the game fully loaded (ex: inside a safe house). I also tried loading it manually with CE opened first. But the thing is, it worked when I first tested it, back when you released it. But now, on a new save (and a game update later) I get this error. It might be a conflict of some sorts..

jonasbeckman
Expert Cheater
Expert Cheater
Posts: 307
Joined: Sat May 06, 2017 1:26 pm
Reputation: 22

Re: Sniper: Ghost Warrior 3 - Enable CryEngine Console

Post by jonasbeckman »

Perhaps a compatibility issue with 1.04 which was released a few days ago. (Finally improved the loading times in addition to compatibility with a newly released DLC.)

I haven't tested the table myself yet though with the new version of the game but I'll give it a try to see what happens.

EDIT: Yep, same error as soon as the game is started.

EDIT: Guessing CE can't locate the address for this version of the game even if it's using AOB.
Last edited by jonasbeckman on Wed Sep 13, 2017 9:27 am, edited 1 time in total.

diabloamezon
Cheater
Cheater
Posts: 45
Joined: Fri Mar 03, 2017 3:55 am
Reputation: 1

Re: Sniper: Ghost Warrior 3 - Enable CryEngine Console

Post by diabloamezon »

I'm using CPY (1.04) and also got this error. Maybe it because CPY ver.

My order was run the game till main menu, go to desktop and run SGW3.CT and let the table run. After that it get Error:Failure determining what SSystemGlobalEnvironment_AOB means. Re-select the game exe process get the same error.

angelotti
Noobzor
Noobzor
Posts: 9
Joined: Wed Sep 06, 2017 10:35 am
Reputation: 1

Re: Sniper: Ghost Warrior 3 - Enable CryEngine Console

Post by angelotti »

SunBeam wrote:
Wed Sep 13, 2017 8:35 am
...
P.S.: You're not required to be anywhere in-game for table to work - safe house or whatever - just run the table and that's that.
I only mentioned the safe house for it to be clear I was in-game and not at the intro videos, so you'll know not to repeat the previous answer. I know the (very) basics of cheat engine, I'm a long time user.
That being said, I am aware how stupid some people are, and what retarded questions they often ask, so your answer was to be expected.

Sorry for the off topic post.

diabloamezon
Cheater
Cheater
Posts: 45
Joined: Fri Mar 03, 2017 3:55 am
Reputation: 1

Re: Sniper: Ghost Warrior 3 - Enable CryEngine Console

Post by diabloamezon »

Thanks for the update sir!

Edit : Maybe I did something wrong. The table enable and in-game console enable, but it seems I can't type anything to work (resource hook works fine). I'm reassure that I'm typing in English but nothing work.

EDIT2 : I use universal remote console with this table and works fine now :D

User avatar
pino44io
Cheater
Cheater
Posts: 48
Joined: Thu May 25, 2017 9:59 am
Reputation: 5

Re: Sniper: Ghost Warrior 3 - Enable CryEngine Console

Post by pino44io »

SunBeam wrote:
Sat Aug 05, 2017 11:53 pm

List of useful console commands/variables:
Spoiler
Commands:

pl_health (usage: pl_health value -> e.g.: pl_health 1000)
lock_all_skills ("Locks all skills.")
give_skill_points (usage: give_skill_points path(sniper/ghost/warrior) number(max available points == 255) -> e.g.: give_skill_points sniper 12)
replenish_stamina (e.g.: replenish_stamina 1)
takeDamage (e.g.: takeDamage 10; works with negative values too, as heal -> takeDamage -10)
revive ("Revives player".)
v_kill ("Kills player vehicle.")
kill ("Kills the player.")
unlock_safehouse_and_fasttravel ("Unlocks all safehouses and fast travel points.")
show_loot_items_on_map ("Show all items from Loot category on map.")
items_in_weaponcache_unlock ("Unlock all items in weapon cache.")
complete_current_mission ("Completes current active mission.")
unlock_all_characters_and_factions ("Unlocks all characters and factions.")
unlock_all_missions ("Unlocks all regions, chapters and missions.")
unlock_all_collectibles ("Unlocks all collectibles.")
drone_upgrade ("Add drone upgrade.")
drone_remove ("Remove drone upgrade.")
items_in_weaponcache_reset ("Reset weapon cache.")
pl_unlockSkills ("Unlock all skills.")

CVars:

pl_movement.speedScale (default is 1.200000048)
pl_movement.strafe_SpeedScale (default is 0.8999999762)
pl_movement.sprint_SpeedScale (default is 1.700000048)
pl_movement.crouch_SpeedScale (default is 1.0)
pl_movement.acceleration (default is 13.0)
pl_health.normal_regeneration_rateSP (default is 250.0)
pl_drownRecoveryTime (default is 1)
ai_ignorePlayer (default is 0; set to 1 to make AI ignore the player)
ai_ignoreDrone (default is 0; set to 1 to make the AI ignore the drone)
g_godMode (default is 0; set to 2 to enable)
g_infiniteAmmo (default is 0; set to 1 to enable)
g_infiniteDroneBattery (default is 0; set to 1 to enable)
g_instantKillDamageThreshold (set to 0.1 for instant kill -- untested)

i_staminaConsumptionScale 0 (default is )
i_zoom_sway_scale 0 (default is )
i_enable_aim_assist (default is 1 in normal mode; can be 0 in hard)
i_enable_hb_slomo (default is )
i_enable_red_dot (default is 1; can be 0 in hard
i_enable_ricochet (default is )
g_killstreakTimeLimit (default is )

Enable File Logging:

log_Verbosity 3
log_WriteToFileVerbosity 3
log_VerbosityOverridesWriteToFile 1

Testing:

i_giveammo (and params: e.g.: i_giveammo PistolBullet 999)
i_givedebugitems
i_giveallitems
i_giveitem
p_fly_mode 0/1
p_collision_mode
p_gravity_z
flycam_movedown
flycam_speedup
flycam_turbo
check spread/recoil cvars
recoil_holdBreathActive_m
spread_holdBreathActive_m
Thank you very much for this mr. Sunbeam!;) Don`t you know any commands for noclip or higher jump?

VirgilSouth
Expert Cheater
Expert Cheater
Posts: 158
Joined: Tue May 02, 2017 3:25 pm
Reputation: 65

Re: Sniper: Ghost Warrior 3 - Enable CryEngine Console

Post by VirgilSouth »

can u update script for latest game version?

stevieshae
What is cheating?
What is cheating?
Posts: 3
Joined: Sat Feb 17, 2018 3:47 am
Reputation: 1

Re: Sniper: Ghost Warrior 3 - Enable CryEngine Console

Post by stevieshae »

Can we get an update please?

Post Reply

Who is online

Users browsing this forum: 2610mason, 321313asdasdaasd, apollo1, Audience3339, BigBear743, Bing [Bot], Bochief, Dan_Lyle, Google [Bot], Irre33, kalotus, nl2336, NotAFedBoy, SemrushBot, Sogou, StarkSint, Vincentzz, zdd1234, ZoDDeL