 |
Cheat Engine The Official Site of Cheat Engine
|
| View previous topic :: View next topic |
| Author |
Message |
bil autsaeder How do I cheat?
Reputation: 0
Joined: 04 Nov 2022 Posts: 1
|
Posted: Fri Nov 04, 2022 8:06 am Post subject: I want to do a fly hack but I don't know how |
|
|
| Found X Y Z but don't know how to make a fly hack
|
|
| Back to top |
|
 |
cooleko Grandmaster Cheater
Reputation: 11
Joined: 04 May 2016 Posts: 717
|
Posted: Fri Nov 04, 2022 2:37 pm Post subject: |
|
|
When you edit the x, y, or z value does it move you?
If so, you need to write values to those addresses to implement a teleportation script.
Next question is how are you going to know where you are teleporting? Odds are you need a script with storage that identifes the current coordinates (readmem) with a user supplied label and upon selecting to teleport performs a write. In a simple implementation, you can just hold a single teleport coordinates as a save point.
Now you have a gui that allows you to either store a single point, then teleport to it at the press of a button or key, or store a plurality of teleport locations which may also be selected, loaded, and then teleported to.
Questions for you to decide, are you building this in cheat engine with lua or are you building this in a programming language? Are you going all out or basic? And do you know how to store and use offsets and/or addresses, read memory and write memory, and build out a usable gui?
It's fairly basic and a great learning experience for you to work with!
Once you have made your decisions and put in effort to implement it, feel free to come back with more questions!
|
|
| Back to top |
|
 |
Frouk Grandmaster Cheater
Reputation: 5
Joined: 22 Jun 2021 Posts: 510
|
Posted: Sat Nov 05, 2022 2:14 am Post subject: |
|
|
With X Y Z only teleport is valid, but fly hack with player vector position is not, better to find velocity and then make fly hack (as i experienced, i made fly hack with player position and player was falling because it's not writing y velocity(height velocity), but there's was a solution for it, player flags which was including "DisableVelocity")
And yes it was in Cheat Engine lua, but if you want to make a real fly hack with Cheat Engine lua, there's must be examples for it, for me i take camera yaw and pitch and here's code that i wrote making it | Code: | {$lua}
if syntaxcheck then return end
local speedMultiplier = 2
[ENABLE]
local active
if Airbreak and Airbreak.Hotkey then Airbreak.Hotkey.destroy() Airbreak.Hotkey = nil end
Airbreak.Hotkey = createHotkey(function()
if IsAttached() and IsOnFocus() and not IsGamePaused() then
active = not active
local playerEntity = FindPlayerEntity()
local flags = playerEntity.physical:GetFlags(1)
flags[6] = active
playerEntity.physical:SetFlags(1, flags)
if Airbreak.SlowDownTime then
writeFloat(0xB7CB64, active and 0.001 or 1)
end
if Airbreak.IgnoredWhileActive then
writeByte(CWanted.Get()+0x1E, active and 4 or 0)
end
Airbreak.SetEnabled(active)
Util.SetInvulnerable(playerEntity, active)
Airbreak.Update()
end
end,VK_RSHIFT)
Airbreak.Hotkey.delayBetweenActivate = 99999
Airbreak.Timer.OnTimer = function()
if IsAttached() and IsOnFocus() and not IsGamePaused() then
local playerEntity = FindPlayerEntity()
local yaw = math.deg(-readFloat(0xB6F178))
local pos = playerEntity.physical.placeable:GetPos()
local cameraAngles = Vector2D.new(math.deg(readFloat(0xB6F258)),math.deg(readFloat(0xB6F248)))
local speed = Airbreak.Speed
if isKeyPressed(VK_LSHIFT) then
speed = Airbreak.Speed * speedMultiplier
end
if isKeyPressed(VK_W) then
pos.x = pos.x + speed * math.sin(-math.rad(yaw))
pos.y = pos.y + speed * math.cos(-math.rad(yaw))
pos.z = pos.z + speed * math.sin(math.rad(cameraAngles.y))
elseif isKeyPressed(VK_S) then
pos.x = pos.x - speed * math.sin(-math.rad(yaw))
pos.y = pos.y - speed * math.cos(-math.rad(yaw))
pos.z = pos.z - speed * math.sin(math.rad(cameraAngles.y))
end
if isKeyPressed(VK_A) then
pos.x = pos.x - speed * math.sin(-math.rad(yaw - 90))
pos.y = pos.y - speed * math.cos(-math.rad(yaw - 90))
elseif isKeyPressed(VK_D) then
pos.x = pos.x + speed * math.sin(-math.rad(yaw - 90))
pos.y = pos.y + speed * math.cos(-math.rad(yaw - 90))
end
playerEntity.physical.placeable:SetPos(pos)
writeBool(0xB73458+0x10E, active)
if active then
local _, entType = Entity.EntityType(playerEntity)
if entType == "VEHICLE" then
playerEntity.physical.placeable:SetHeading(math.rad(yaw))
end
end
if active and not FindPlayerPed().ped:InVehicle() then
local player = FindPlayerPed()
local pedFlags = player.ped:GetPedFlags(0)
pedFlags[1] = true
player.ped:SetPedFlags(0, pedFlags)
pedFlags = nil
local pedFlags = player.ped:GetPedFlags(1)
pedFlags[2] = false
pedFlags[3] = false
player.ped:SetPedFlags(1, pedFlags)
writeInteger(player.ped:Get()+0x530, 1)
end
end
end
[DISABLE]
if Airbreak and Airbreak.Hotkey then Airbreak.Hotkey.destroy() Airbreak.Hotkey = nil end
Airbreak.SetEnabled(false)
writeFloat(0xB7CB64, 1)
{$asm} |
|
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You cannot attach files in this forum You can download files in this forum
|
|