{$CLEO .cs}
THREAD 'RACECPMARKER'
WAIT 5000 // WAIT UNTIL SAMP INIT??
WHILE TRUE
WAIT 0
IF
KEY_DOWN 77 // KEY "M"
THEN
IF
call @is_racecp_active 0
THEN
call @get_racecp_pos 0 X 0@ Y 1@ Z $NOT_USED
call @setTargetMarker 3 x 0@ y 1@ z 0.0
END
END
END
:is_racecp_active
// 0AB1: @is_racecp_active 0
IF 0AA2: 31@ = loadlib "samp.dll"
THEN
0AB1...
{$CLEO .cs}
0000: 'Author:'
// Function to check if player is making a job
function IsMakingJob()
local job_id, has_job
job_id = get_player_jobid($PLAYER_CHAR)
has_job = job_id != 0
return has_job
end
REPEAT
WAIT 0
UNTIL 0AFA:
// Register C + L key combination
0A93: key_hook key_press 0x43 0x4C to_label @MARK_CHECKPOINTS
WHILE TRUE
WAIT 0
// Check if player is making a job and pressed C + L
if IsMakingJob() and is_key_pressed(0x43) and is_key_pressed(0x4C) then
// Get all checkpoints on the map
local num_checkpoints, checkpoints
num_checkpoints = get_all_checkpoints_of_type(CHECKPOINT_TYPE_RACE, checkpoints)
// Loop through each checkpoint
for i = 0 to num_checkpoints - 1 do
local x, y, z
// Get checkpoint coordinates
get_checkpoint_pos(checkpoints[i], x, y, z)
// Check if checkpoint is red
if get_checkpoint_color(checkpoints[i]) == COLOR_RED then
// Set waypoint at checkpoint coordinates
set_player_waypoint($PLAYER_CHAR, x, y, z)
end
end
end
END
:MARK_CHECKPOINTS
0A95: return
Code:{$CLEO .cs} 0000: 'Author:' // Function to check if player is making a job function IsMakingJob() local job_id, has_job job_id = get_player_jobid($PLAYER_CHAR) has_job = job_id != 0 return has_job end REPEAT WAIT 0 UNTIL 0AFA: // Register C + L key combination 0A93: key_hook key_press 0x43 0x4C to_label @MARK_CHECKPOINTS WHILE TRUE WAIT 0 // Check if player is making a job and pressed C + L if IsMakingJob() and is_key_pressed(0x43) and is_key_pressed(0x4C) then // Get all checkpoints on the map local num_checkpoints, checkpoints num_checkpoints = get_all_checkpoints_of_type(CHECKPOINT_TYPE_RACE, checkpoints) // Loop through each checkpoint for i = 0 to num_checkpoints - 1 do local x, y, z // Get checkpoint coordinates get_checkpoint_pos(checkpoints[i], x, y, z) // Check if checkpoint is red if get_checkpoint_color(checkpoints[i]) == COLOR_RED then // Set waypoint at checkpoint coordinates set_player_waypoint($PLAYER_CHAR, x, y, z) end end end END :MARK_CHECKPOINTS 0A95: return
Its a shit code, im 99% percent he just prompted a request to chatgpt with your description of the script
Can you make it for race checkpoint?Still want? Send screenshot of what the checkpoint looks like and what it looks like on the minimap and I shall have a look into it for you.
{$CLEO .cs}
THREAD 'RACECPMARKER'
WAIT 5000 // WAIT UNTIL SAMP INIT??
WHILE TRUE
WAIT 0
IF
KEY_DOWN 77 // KEY "M"
THEN
IF
call @is_racecp_active 0
THEN
// SET MARKER
FOR 0@ = 0xBA86F0 TO 0xBA8EC0 STEP 40
0A8E: 1@ = 0@ + 37 // byteFlags
0A8D: 2@ = read_memory 1@ size 1 virtual_protect 0
IF AND
08B7: test 2@ bit 1 // Does blip exist?
88B7: test 2@ bit 2 // Is a long distance blip?
THEN
0A8E: 1@ = 0@ + 36 // byteIcon
0A8D: 2@ = read_memory 1@ size 1 virtual_protect 0
IF
2@ == 41 // TXT icon for marker
THEN
// COORDS
call @get_racecp_pos 0 X 3@ Y 4@ Z $NOT_USED
0A8E: 1@ = 0@ + 8 // X
0A8C: write_memory 1@ size 4 value 3@ virtual_protect 0
0A8D: 3@ = read_memory 1@ size 4 virtual_protect 0
0A8E: 1@ = 0@ + 12 // Y
0A8C: write_memory 1@ size 4 value 4@ virtual_protect 0
0A8D: 4@ = read_memory 1@ size 4 virtual_protect 0
END
END
END
END
END
END
:is_racecp_active
{
0.3.7 - R1
}
IF 0AA2: 0@ = loadlib "samp.dll"
THEN 0A8E: 1@ = 0@ + 0x21A10C // SAMP_MISC_INFO
0A8D: 1@ = readMem 1@ sz 4 vp 0
1@ += 0x49
0A8D: 1@ = readMem 1@ sz 4 vp 0
IF 1@ == TRUE
THEN 0485: return_true
ELSE 059A: return_false
END
0AA3: freelib 0@
END
0AB2: ret 0
:get_racecp_pos
{
0.3.7 - R1
}
IF 0AA2: 0@ = loadlib "samp.dll"
THEN 0A8E: 1@ = 0@ + 0x21A10C // SAMP_MISC_INFO
0A8D: 1@ = readMem 1@ sz 4 vp 0
1@ += 0x2C
0A8D: 2@ = readMem 1@ sz 4 vp 0
1@ += 0x4
0A8D: 3@ = readMem 1@ sz 4 vp 0
1@ += 0x4
0A8D: 4@ = readMem 1@ sz 4 vp 0
0AA3: freelib 0@
END
0AB2: ret 3 2@ 3@ 4@
I have some trouble here.PHP:{$CLEO .cs} THREAD 'RACECPMARKER' WAIT 5000 // WAIT UNTIL SAMP INIT?? WHILE TRUE WAIT 0 IF KEY_DOWN 77 // KEY "M" THEN IF call @is_racecp_active 0 THEN // SET MARKER FOR 0@ = 0xBA86F0 TO 0xBA8EC0 STEP 40 0A8E: 1@ = 0@ + 37 // byteFlags 0A8D: 2@ = read_memory 1@ size 1 virtual_protect 0 IF AND 08B7: test 2@ bit 1 // Does blip exist? 88B7: test 2@ bit 2 // Is a long distance blip? THEN 0A8E: 1@ = 0@ + 36 // byteIcon 0A8D: 2@ = read_memory 1@ size 1 virtual_protect 0 IF 2@ == 41 // TXT icon for marker THEN // COORDS call @get_racecp_pos 0 X 3@ Y 4@ Z $NOT_USED 0A8E: 1@ = 0@ + 8 // X 0A8C: write_memory 1@ size 4 value 3@ virtual_protect 0 0A8D: 3@ = read_memory 1@ size 4 virtual_protect 0 0A8E: 1@ = 0@ + 12 // Y 0A8C: write_memory 1@ size 4 value 4@ virtual_protect 0 0A8D: 4@ = read_memory 1@ size 4 virtual_protect 0 END END END END END END :is_racecp_active { 0.3.7 - R1 } IF 0AA2: 0@ = loadlib "samp.dll" THEN 0A8E: 1@ = 0@ + 0x21A10C // SAMP_MISC_INFO 0A8D: 1@ = readMem 1@ sz 4 vp 0 1@ += 0x49 0A8D: 1@ = readMem 1@ sz 4 vp 0 IF 1@ == TRUE THEN 0485: return_true ELSE 059A: return_false END 0AA3: freelib 0@ END 0AB2: ret 0 :get_racecp_pos { 0.3.7 - R1 } IF 0AA2: 0@ = loadlib "samp.dll" THEN 0A8E: 1@ = 0@ + 0x21A10C // SAMP_MISC_INFO 0A8D: 1@ = readMem 1@ sz 4 vp 0 1@ += 0x2C 0A8D: 2@ = readMem 1@ sz 4 vp 0 1@ += 0x4 0A8D: 3@ = readMem 1@ sz 4 vp 0 1@ += 0x4 0A8D: 4@ = readMem 1@ sz 4 vp 0 0AA3: freelib 0@ END 0AB2: ret 3 2@ 3@ 4@
Using 0.3.7 R1 offsets see this snippet for all different offsets from versions R1 onwards you may have to change (idk what version you are on). Key is "M" to mark your race checkpoint, just make sure you have a marker set somewhere (ik it's half-arsed but this script only MOVES your marker, if thats a problem we can look into marker memory and shit but it probably means doing some cheat engine shit).
Unknown directive KEY_DOWN 77.
I asume you are using some kind .asi which works when you mark on radar, please provide that asi in order to test and make code to work fully.I want him to automatically mark the red checkpoints that appear on the map with a way point by pressing the C + L combination while making a job.
PHP:{$CLEO .cs} THREAD 'RACECPMARKER' WAIT 5000 // WAIT UNTIL SAMP INIT?? WHILE TRUE WAIT 0 IF KEY_DOWN 77 // KEY "M" THEN IF call @is_racecp_active 0 THEN // SET MARKER FOR 0@ = 0xBA86F0 TO 0xBA8EC0 STEP 40 0A8E: 1@ = 0@ + 37 // byteFlags 0A8D: 2@ = read_memory 1@ size 1 virtual_protect 0 IF AND 08B7: test 2@ bit 1 // Does blip exist? 88B7: test 2@ bit 2 // Is a long distance blip? THEN 0A8E: 1@ = 0@ + 36 // byteIcon 0A8D: 2@ = read_memory 1@ size 1 virtual_protect 0 IF 2@ == 41 // TXT icon for marker THEN // COORDS call @get_racecp_pos 0 X 3@ Y 4@ Z $NOT_USED 0A8E: 1@ = 0@ + 8 // X 0A8C: write_memory 1@ size 4 value 3@ virtual_protect 0 0A8D: 3@ = read_memory 1@ size 4 virtual_protect 0 0A8E: 1@ = 0@ + 12 // Y 0A8C: write_memory 1@ size 4 value 4@ virtual_protect 0 0A8D: 4@ = read_memory 1@ size 4 virtual_protect 0 END END END END END END :is_racecp_active { 0.3.7 - R1 } IF 0AA2: 0@ = loadlib "samp.dll" THEN 0A8E: 1@ = 0@ + 0x21A10C // SAMP_MISC_INFO 0A8D: 1@ = readMem 1@ sz 4 vp 0 1@ += 0x49 0A8D: 1@ = readMem 1@ sz 4 vp 0 IF 1@ == TRUE THEN 0485: return_true ELSE 059A: return_false END 0AA3: freelib 0@ END 0AB2: ret 0 :get_racecp_pos { 0.3.7 - R1 } IF 0AA2: 0@ = loadlib "samp.dll" THEN 0A8E: 1@ = 0@ + 0x21A10C // SAMP_MISC_INFO 0A8D: 1@ = readMem 1@ sz 4 vp 0 1@ += 0x2C 0A8D: 2@ = readMem 1@ sz 4 vp 0 1@ += 0x4 0A8D: 3@ = readMem 1@ sz 4 vp 0 1@ += 0x4 0A8D: 4@ = readMem 1@ sz 4 vp 0 0AA3: freelib 0@ END 0AB2: ret 3 2@ 3@ 4@
Using 0.3.7 R1 offsets see this snippet for all different offsets from versions R1 onwards you may have to change (idk what version you are on). Key is "M" to mark your race checkpoint, just make sure you have a marker set somewhere (ik it's half-arsed but this script only MOVES your marker, if thats a problem we can look into marker memory and shit but it probably means doing some cheat engine shit).
I tried to change into it but it says "Unknown directive KEY_DOWN 77." when i compile it. How can I make it?Race Check Point:
[CLEO] Some multi-samp snippets
:SET_CHAT_INPUT_ENABLED { 0AB1: @SET_CHAT_INPUT_ENABLED 1 Status 0 // 1 = Enable, 0 = Disable } IF 0AA2: 31@ = "samp.dll" THEN 0AB1: @get_samp_version_id 0 _returned: ID 17@ IF 17@ > 0 THEN IF 17@ == 1 // 0.3.7 R1 THEN 0A8E: 30@ = 31@ + 0x21A0E8...ugbase.eu
download sanny sb data.I tried to change into it but it says "Unknown directive KEY_DOWN 77." when i compile it. How can I make it?
I tried to change into it but it says "Unknown directive KEY_DOWN 77." when i compile it. How can I make it?
PHP:{$CLEO .cs} THREAD 'RACECPMARKER' WAIT 5000 // WAIT UNTIL SAMP INIT?? WHILE TRUE WAIT 0 IF KEY_DOWN 77 // KEY "M" THEN IF call @is_racecp_active 0 THEN // SET MARKER FOR 0@ = 0xBA86F0 TO 0xBA8EC0 STEP 40 0A8E: 1@ = 0@ + 37 // byteFlags 0A8D: 2@ = read_memory 1@ size 1 virtual_protect 0 IF AND 08B7: test 2@ bit 1 // Does blip exist? 88B7: test 2@ bit 2 // Is a long distance blip? THEN 0A8E: 1@ = 0@ + 36 // byteIcon 0A8D: 2@ = read_memory 1@ size 1 virtual_protect 0 IF 2@ == 41 // TXT icon for marker THEN // COORDS call @get_racecp_pos 0 X 3@ Y 4@ Z $NOT_USED 0A8E: 1@ = 0@ + 8 // X 0A8C: write_memory 1@ size 4 value 3@ virtual_protect 0 0A8D: 3@ = read_memory 1@ size 4 virtual_protect 0 0A8E: 1@ = 0@ + 12 // Y 0A8C: write_memory 1@ size 4 value 4@ virtual_protect 0 0A8D: 4@ = read_memory 1@ size 4 virtual_protect 0 END END END END END END :is_racecp_active { 0.3.7 - R1 } IF 0AA2: 0@ = loadlib "samp.dll" THEN 0A8E: 1@ = 0@ + 0x21A10C // SAMP_MISC_INFO 0A8D: 1@ = readMem 1@ sz 4 vp 0 1@ += 0x49 0A8D: 1@ = readMem 1@ sz 4 vp 0 IF 1@ == TRUE THEN 0485: return_true ELSE 059A: return_false END 0AA3: freelib 0@ END 0AB2: ret 0 :get_racecp_pos { 0.3.7 - R1 } IF 0AA2: 0@ = loadlib "samp.dll" THEN 0A8E: 1@ = 0@ + 0x21A10C // SAMP_MISC_INFO 0A8D: 1@ = readMem 1@ sz 4 vp 0 1@ += 0x2C 0A8D: 2@ = readMem 1@ sz 4 vp 0 1@ += 0x4 0A8D: 3@ = readMem 1@ sz 4 vp 0 1@ += 0x4 0A8D: 4@ = readMem 1@ sz 4 vp 0 0AA3: freelib 0@ END 0AB2: ret 3 2@ 3@ 4@
Using 0.3.7 R1 offsets see this snippet for all different offsets from versions R1 onwards you may have to change (idk what version you are on). Key is "M" to mark your race checkpoint, just make sure you have a marker set somewhere (ik it's half-arsed but this script only MOVES your marker, if thats a problem we can look into marker memory and shit but it probably means doing some cheat engine shit).
Thanks, it works!Sanny Builder
MediaFire is a simple to use free service that lets you put all your photos, documents, music, and video in a single place so you can access them anywhere and share them everywhere.www.mediafire.com
Ready to use sanny builder.
Also make sure you have settings set to " As is "
I asume you are using some kind .asi which works when you mark on radar, please provide that asi in order to test and make code to work fully.
Check Point:
[CLEO] Some multi-samp snippets
:SET_CHAT_INPUT_ENABLED { 0AB1: @SET_CHAT_INPUT_ENABLED 1 Status 0 // 1 = Enable, 0 = Disable } IF 0AA2: 31@ = "samp.dll" THEN 0AB1: @get_samp_version_id 0 _returned: ID 17@ IF 17@ > 0 THEN IF 17@ == 1 // 0.3.7 R1 THEN 0A8E: 30@ = 31@ + 0x21A0E8...ugbase.eu
Race Check Point:
[CLEO] Some multi-samp snippets
:SET_CHAT_INPUT_ENABLED { 0AB1: @SET_CHAT_INPUT_ENABLED 1 Status 0 // 1 = Enable, 0 = Disable } IF 0AA2: 31@ = "samp.dll" THEN 0AB1: @get_samp_version_id 0 _returned: ID 17@ IF 17@ > 0 THEN IF 17@ == 1 // 0.3.7 R1 THEN 0A8E: 30@ = 31@ + 0x21A0E8...ugbase.eu
{$CLEO .cs}
THREAD 'RACECPMARKER'
WAIT 5000 // WAIT UNTIL SAMP INIT??
WHILE TRUE
WAIT 0
IF
KEY_DOWN 77 // KEY "M"
THEN
IF
call @is_racecp_active 0
THEN
call @get_racecp_pos 0 X 0@ Y 1@ Z $NOT_USED
call @setTargetMarker 3 x 0@ y 1@ z 0.0
END
END
END
:is_racecp_active
// 0AB1: @is_racecp_active 0
IF 0AA2: 31@ = loadlib "samp.dll"
THEN
0AB1: @get_samp_version_id 0 _returned: ID 17@
IF 17@ > 0
THEN
IF 17@ == 1 // 0.3.7 R1
THEN
0A8E: 30@ = 31@ + 0x21A10C // SAMP_MISC_INFO_OFFSET
0A8D: 30@ = readMem 30@ sz 4 vp 0
30@ += 0x49 // SAMP_CHECKPOINT_ACTIVE_OFFSET
0A8D: 30@ = readMem 30@ sz 4 vp 0
END
IF 17@ == 2 // 0.3.7 R2
THEN
0A8E: 30@ = 31@ + 0x21A114 // SAMP_MISC_INFO_OFFSET
0A8D: 30@ = readMem 30@ sz 4 vp 0
30@ += 0x29 // SAMP_CHECKPOINT_ACTIVE_OFFSET
0A8D: 30@ = readMem 30@ sz 4 vp 0
END
IF 17@ == 3 // 0.3.DL
THEN
0A8E: 30@ = 31@ + 0x2ACA3C // SAMP_MISC_INFO_OFFSET
0A8D: 30@ = readMem 30@ sz 4 vp 0
30@ += 0x29 // SAMP_CHECKPOINT_ACTIVE_OFFSET
0A8D: 30@ = readMem 30@ sz 4 vp 0
END
IF 17@ == 4 // 0.3.7 R3
THEN
0A8E: 30@ = 31@ + 0x26E8F4 // SAMP_MISC_INFO_OFFSET
0A8D: 30@ = readMem 30@ sz 4 vp 0
30@ += 0x29 // SAMP_CHECKPOINT_ACTIVE_OFFSET
0A8D: 30@ = readMem 30@ sz 4 vp 0
END
IF 17@ == 5 // 0.3.7 R4
THEN
0A8E: 30@ = 31@ + 0x26EA24 // SAMP_MISC_INFO_OFFSET
0A8D: 30@ = readMem 30@ sz 4 vp 0
30@ += 0x29 // SAMP_CHECKPOINT_ACTIVE_OFFSET
0A8D: 30@ = readMem 30@ sz 4 vp 0
END
IF 17@ == 6 // 0.3.7 R4 - v2
THEN
0A8E: 30@ = 31@ + 0x26EA24 // SAMP_MISC_INFO_OFFSET
0A8D: 30@ = readMem 30@ sz 4 vp 0
30@ += 0x4D // SAMP_CHECKPOINT_ACTIVE_OFFSET
0A8D: 30@ = readMem 30@ sz 4 vp 0
END
IF 17@ == 7 // 0.3.7 R5
THEN
0A8E: 30@ = 31@ + 0x26EBAC // SAMP_MISC_INFO_OFFSET
0A8D: 30@ = readMem 30@ sz 4 vp 0
30@ += 0x29 // SAMP_CHECKPOINT_ACTIVE_OFFSET
0A8D: 30@ = readMem 30@ sz 4 vp 0
END
IF 30@ == TRUE
THEN 0485: return_true
ELSE 059A: return_false
END
0AA3: freelib 31@
END
END
0AB2: ret 0
:get_racecp_pos
// 0AB1: @get_racecp_pos 0 XYZ 1@ 2@ 3@
IF 0AA2: 31@ = loadlib "samp.dll"
THEN
0AB1: @get_samp_version_id 0 _returned: ID 17@
IF 17@ > 0
THEN
IF 17@ == 1 // 0.3.7 R1
THEN
0A8E: 30@ = 31@ + 0x21A10C // SAMP_MISC_INFO_OFFSET
0A8D: 30@ = readMem 30@ sz 4 vp 0
0A8E: 29@ = 30@ + 0x2C // SAMP_CHECKPOINT_X_OFFSET
0A8D: 28@ = readMem 29@ sz 4 vp 0
0A8E: 27@ = 30@ + 0x30 // SAMP_CHECKPOINT_Y_OFFSET
0A8D: 26@ = readMem 27@ sz 4 vp 0
0A8E: 25@ = 30@ + 0x34 // SAMP_CHECKPOINT_Z_OFFSET
0A8D: 24@ = readMem 25@ sz 4 vp 0
END
IF 17@ == 2 // 0.3.7 R2
THEN
0A8E: 30@ = 31@ + 0x21A114 // SAMP_MISC_INFO_OFFSET
0A8D: 30@ = readMem 30@ sz 4 vp 0
0A8E: 29@ = 30@ + 0xC // SAMP_CHECKPOINT_X_OFFSET
0A8D: 28@ = readMem 29@ sz 4 vp 0
0A8E: 27@ = 30@ + 0x10 // SAMP_CHECKPOINT_Y_OFFSET
0A8D: 26@ = readMem 27@ sz 4 vp 0
0A8E: 25@ = 30@ + 0x14 // SAMP_CHECKPOINT_Z_OFFSET
0A8D: 24@ = readMem 25@ sz 4 vp 0
END
IF 17@ == 3 // 0.3.DL
THEN
0A8E: 30@ = 31@ + 0x2ACA3C // SAMP_MISC_INFO_OFFSET
0A8D: 30@ = readMem 30@ sz 4 vp 0
0A8E: 29@ = 30@ + 0xC // SAMP_CHECKPOINT_X_OFFSET
0A8D: 28@ = readMem 29@ sz 4 vp 0
0A8E: 27@ = 30@ + 0x10 // SAMP_CHECKPOINT_Y_OFFSET
0A8D: 26@ = readMem 27@ sz 4 vp 0
0A8E: 25@ = 30@ + 0x14 // SAMP_CHECKPOINT_Z_OFFSET
0A8D: 24@ = readMem 25@ sz 4 vp 0
END
IF 17@ == 4 // 0.3.7 R3
THEN
0A8E: 30@ = 31@ + 0x26E8F4 // SAMP_MISC_INFO_OFFSET
0A8D: 30@ = readMem 30@ sz 4 vp 0
0A8E: 29@ = 30@ + 0xC // SAMP_CHECKPOINT_X_OFFSET
0A8D: 28@ = readMem 29@ sz 4 vp 0
0A8E: 27@ = 30@ + 0x10 // SAMP_CHECKPOINT_Y_OFFSET
0A8D: 26@ = readMem 27@ sz 4 vp 0
0A8E: 25@ = 30@ + 0x14 // SAMP_CHECKPOINT_Z_OFFSET
0A8D: 24@ = readMem 25@ sz 4 vp 0
END
IF 17@ == 5 // 0.3.7 R4
THEN
0A8E: 30@ = 31@ + 0x26EA24 // SAMP_MISC_INFO_OFFSET
0A8D: 30@ = readMem 30@ sz 4 vp 0
0A8E: 29@ = 30@ + 0xC // SAMP_CHECKPOINT_X_OFFSET
0A8D: 28@ = readMem 29@ sz 4 vp 0
0A8E: 27@ = 30@ + 0x10 // SAMP_CHECKPOINT_Y_OFFSET
0A8D: 26@ = readMem 27@ sz 4 vp 0
0A8E: 25@ = 30@ + 0x14 // SAMP_CHECKPOINT_Z_OFFSET
0A8D: 24@ = readMem 25@ sz 4 vp 0
END
IF 17@ == 6 // 0.3.7 R4 - v2
THEN
0A8E: 30@ = 31@ + 0x26EA24 // SAMP_MISC_INFO_OFFSET
0A8D: 30@ = readMem 30@ sz 4 vp 0
0A8E: 29@ = 30@ + 0xC // SAMP_CHECKPOINT_X_OFFSET
0A8D: 28@ = readMem 29@ sz 4 vp 0
0A8E: 27@ = 30@ + 0x10 // SAMP_CHECKPOINT_Y_OFFSET
0A8D: 26@ = readMem 27@ sz 4 vp 0
0A8E: 25@ = 30@ + 0x14 // SAMP_CHECKPOINT_Z_OFFSET
0A8D: 24@ = readMem 25@ sz 4 vp 0
END
IF 17@ == 7 // 0.3.7 R5
THEN
0A8E: 30@ = 31@ + 0x26EBAC // SAMP_MISC_INFO_OFFSET
0A8D: 30@ = readMem 30@ sz 4 vp 0
0A8E: 29@ = 30@ + 0xC // SAMP_CHECKPOINT_X_OFFSET
0A8D: 28@ = readMem 29@ sz 4 vp 0
0A8E: 27@ = 30@ + 0x10 // SAMP_CHECKPOINT_Y_OFFSET
0A8D: 26@ = readMem 27@ sz 4 vp 0
0A8E: 25@ = 30@ + 0x14 // SAMP_CHECKPOINT_Z_OFFSET
0A8D: 24@ = readMem 25@ sz 4 vp 0
END
0AA3: freelib 31@
END
END
0AB2: ret 3 28@ 26@ 24@
:get_samp_version_id
// 0AB1: @get_samp_version_id 0 _returned: ID 0@
30@ = 0
IF 0AA2: 31@ = "samp.dll" // IF and SET
THEN
31@ += 0x128
0A8D: 29@ = read_memory 31@ size 4 virtual_protect 1
IF 29@ == 0x5542F47A
THEN // 0.3.7 R1
30@ = 1
END
IF 29@ == 0x59C30C94
THEN // 0.3.7 R2
30@ = 2
END
IF 29@ == 0x5A6A3130
THEN // 0.3.DL
30@ = 3
END
31@ -= 8 // reading samp.dll + 0x120
0A8D: 29@ = read_memory 31@ size 4 virtual_protect 1
IF 29@ == 0x5C0B4243
THEN // 0.3.7 R3
30@ = 4
END
IF 29@ == 0x5DD606CD
THEN // 0.3.7 R4
30@ = 5
END
IF 29@ == 0x6094ACAB
THEN // 0.3.7 R4 - v2
30@ = 6
END
IF 29@ == 0x6372C39E
THEN // 0.3.7 R5
30@ = 7
END
END
0AB2: ret 1 30@
:getTargetMarkerHandle
0A8D: 0@ = read_memory 0xBA6774 size 4 virtual_protect 0
ret 1 0@
:setTargetMarker
call @getTargetMarkerHandle 0 return: 3@
IF
875C: marker 3@ enabled
THEN
// CREATE MARKER
call @setStateTargetMarker 1 state 1
END
// MOVE MARKER
0B10: 4@ = 3@ AND 0xFFFF
0012: 4@ *= 40
0A8E: 5@ = 0xBA86F8 + 4@
0A8C: write_memory 5@ size 4 value 0@ virtual_protect 0
5@ += 4
0A8C: write_memory 5@ size 4 value 1@ virtual_protect 0
5@ += 4
0A8C: write_memory 5@ size 4 value 2@ virtual_protect 0
0AB2: ret 0
:setStateTargetMarker
call @getTargetMarkerHandle 0 return: 1@
if 1@ > 0
then
if 0@ == 0
then
0AA5: call_function 0x587CE0 num_params 1 pop 1 1@ // CRadar::removeBlip
0A8C: write_memory 0xBA6774 size 4 value 0 virtual_protect 0 // CMenuManager::m_targetMarker
end
else
if 0@ == 1
then
0AA7: call_function 0x583820 num_params 6 pop 6 2 0 0 0 0 4 1@ // CRadar::createBlip
0AA5: call_function 0x583D70 num_params 2 pop 2 41 1@ // CRadar::setBlipSprite
0A8C: write_memory 0xBA6774 size 4 value 1@ virtual_protect 0 // CMenuManager::m_targetMarker
end
end
ret 0