Jump to content
    1. Welcome to GTAForums!

    1. GTANet.com

    1. GTA Online

      1. Los Santos Drug Wars
      2. Updates
      3. Find Lobbies & Players
      4. Guides & Strategies
      5. Vehicles
      6. Content Creator
      7. Help & Support
    2. Red Dead Online

      1. Blood Money
      2. Frontier Pursuits
      3. Find Lobbies & Outlaws
      4. Help & Support
    3. Crews

    1. Grand Theft Auto Series

      1. Bugs*
      2. St. Andrews Cathedral
    2. GTA VI

    3. GTA V

      1. Guides & Strategies
      2. Help & Support
    4. GTA IV

      1. The Lost and Damned
      2. The Ballad of Gay Tony
      3. Guides & Strategies
      4. Help & Support
    5. GTA San Andreas

      1. Classic GTA SA
      2. Guides & Strategies
      3. Help & Support
    6. GTA Vice City

      1. Classic GTA VC
      2. Guides & Strategies
      3. Help & Support
    7. GTA III

      1. Classic GTA III
      2. Guides & Strategies
      3. Help & Support
    8. Portable Games

      1. GTA Chinatown Wars
      2. GTA Vice City Stories
      3. GTA Liberty City Stories
    9. Top-Down Games

      1. GTA Advance
      2. GTA 2
      3. GTA
    1. Red Dead Redemption 2

      1. PC
      2. Help & Support
    2. Red Dead Redemption

    1. GTA Mods

      1. GTA V
      2. GTA IV
      3. GTA III, VC & SA
      4. Tutorials
    2. Red Dead Mods

      1. Documentation
    3. Mod Showroom

      1. Scripts & Plugins
      2. Maps
      3. Total Conversions
      4. Vehicles
      5. Textures
      6. Characters
      7. Tools
      8. Other
      9. Workshop
    4. Featured Mods

      1. Design Your Own Mission
      2. OpenIV
      3. GTA: Underground
      4. GTA: Liberty City
      5. GTA: State of Liberty
    1. Rockstar Games

    2. Rockstar Collectors

    1. Off-Topic

      1. General Chat
      2. Gaming
      3. Technology
      4. Movies & TV
      5. Music
      6. Sports
      7. Vehicles
    2. Expression

      1. Graphics / Visual Arts
      2. GFX Requests & Tutorials
      3. Writers' Discussion
      4. Debates & Discussion
    1. Announcements

    2. Forum Support

    3. Suggestions

Translating CLEO changed some variables to "D"


TeReviento89
 Share

Recommended Posts

TeReviento89

Hello, let's start.

 

NOTE: This mod requires some SAMPFuncs opcodes

 

Ok, i just translated Afisaj Status to spanish and all "PING" and "FPS" variables changed to "D", like this:

 

"Verdant Bluffs"

"PING: D"

"FPS: D"

 

But in original code is like this:

 

"Verdant Bluffs"

"PING: Ping number"

"FPS: Frames per second number"

 

Can anyone help me?

 

Original code:

 

 

{$CLEO}
0000:

const
FONT = [email protected]
ID = [email protected]
PING = [email protected]
STR_PING = [email protected]
STR_ZONE = [email protected]
STR_FPS = [email protected]
PLAYER_POS_X = [email protected]
PLAYER_POS_Y = [email protected]
PLAYER_POS_Z = [email protected]
FPS_COUNT = [email protected]
FPS_COUNT_COPY = [email protected]
SYSTEM_TICK_COUNT = [email protected]
DISPLAY_POS_X = [email protected]
DISPLAY_POS_Y = [email protected]
DISPLAY_POS_Y_BUFF = [email protected]
TOGGLE_MODE_ADJUSTPOS = [email protected]
TOGGLE_PING = [email protected]
TOGGLE_FPS = [email protected]
TOGGLE_ZONE = [email protected]
STR_FONT_NAME = [email protected]
MOD_SWITCH = [email protected]
FONT_SIZE = [email protected]
FONT_FLAGS = [email protected]
TOGGLE_MODE_ADJUSTSIZE = [email protected]
TOGGLE_MODE_ADJUSTFLAGS = [email protected]
FONT_SIZE_BUFF = [email protected]
TEXT_LENGTH = [email protected]
DISPLAY_POS_X_BUFF = [email protected]
ALIGNMENT = [email protected]

GTX_ZONENAME = s$93
end

alloc STR_PING 64
alloc STR_ZONE 64
alloc STR_FPS 64
alloc STR_FONT_NAME 64

repeat
wait 200
until 0AFA: is_samp_available
0B34: samp register_client_command "as" to_label @toggle
0B34: samp register_client_command "aspoz" to_label @adjustpos
0B34: samp register_client_command "ascomenzi" to_label @help
0B34: samp register_client_command "asping" to_label @tog_ping
0B34: samp register_client_command "asfps" to_label @tog_fps
0B34: samp register_client_command "aszona" to_label @tog_zone
0B34: samp register_client_command "asfont" to_label @adjustflags
0B34: samp register_client_command "asmarime" to_label @adjustsize
0B34: samp register_client_command "asalin" to_label @changeAlignment
0AF8: samp add_message_to_chat "{F7F694}Afisaj Status. Foloseste {FF4800}/ascomenzi {F7F694}pentru a vedea comenzile. Edited By Sebi_Jr"

/* flags
FCR_NONE 0 Text without features
FCR_BOLD 1 Fat content of the text
FCR_ITALICS 2 Bent (italic) text
FCR_BORDER 4 Dribbling text
FCR_SHADOW 8 text Shadow
FCR_UNDERLINE 16 Underlined text
FCR_STRIKEOUT 32 Strikethrough text
*/

if 0AAB: file_exists "CLEO\AfisajStatus.ini"
then
0AF4: STR_FONT_NAME = read_string_from_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "font_name"
0AF0: DISPLAY_POS_X = get_int_from_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "x"
0AF0: DISPLAY_POS_Y = get_int_from_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "y"
0AF0: MOD_SWITCH = get_int_from_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "switch"
0AF0: TOGGLE_PING = get_int_from_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "ping"
0AF0: TOGGLE_FPS = get_int_from_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "fps"
0AF0: TOGGLE_ZONE = get_int_from_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "location"
0AF0: FONT_SIZE = get_int_from_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "font_size"
0AF0: FONT_FLAGS = get_int_from_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "font_flags"
0AF0: ALIGNMENT = get_int_from_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "alignment"
else
0AF8: samp add_message_to_chat "{F7F694}CLEO\AfisajStatus.ini {FF4800}nu a fost gasit. {F7F694}Modul nu lucreaza"
jump @Idle_loop
end

0B6D: render FONT = create STR_FONT_NAME height FONT_SIZE flags FONT_FLAGS

while true
wait 0
if MOD_SWITCH == 1
then
0085: DISPLAY_POS_Y_BUFF = DISPLAY_POS_Y // (int)

//adjust modes
if TOGGLE_MODE_ADJUSTPOS == 1
then 0AB1: @Position_stats 2 DISPLAY_POS_X DISPLAY_POS_Y _return DISPLAY_POS_X DISPLAY_POS_Y
end

if TOGGLE_MODE_ADJUSTSIZE == 1
then
if 0AB1: @Adjust_Font_Size 1 FONT_SIZE _ret FONT_SIZE
then
0B6E: render release FONT
0B6D: render FONT = create STR_FONT_NAME height FONT_SIZE flags FONT_FLAGS
wait 100
end
end

if TOGGLE_MODE_ADJUSTFLAGS == 1
then
if 0AB1: @Adjust_Font_Flags 1 FONT_FLAGS _ret FONT_FLAGS
then
0B6E: render release FONT
0B6D: render FONT = create_font STR_FONT_NAME height FONT_SIZE flags FONT_FLAGS
wait 100
end
end

//texts
if TOGGLE_ZONE == 1
then
00A0: store_actor $PLAYER_ACTOR position_to PLAYER_POS_X PLAYER_POS_Y PLAYER_POS_Z
0843: get_zone_at PLAYER_POS_X PLAYER_POS_Y PLAYER_POS_Z nameA_to GTX_ZONENAME
0ADE: STR_ZONE = text_by_GXT_entry GTX_ZONENAME
if ALIGNMENT == 0 // left
then
0B6F: render FONT draw_text STR_ZONE of pos DISPLAY_POS_X DISPLAY_POS_Y color 0xFFFFFFFF
else
0B6B: render TEXT_LENGTH = FONT get_length_of STR_ZONE
if ALIGNMENT == 1 //center
then
0016: TEXT_LENGTH /= 2
end
0085: DISPLAY_POS_X_BUFF = DISPLAY_POS_X
0062: DISPLAY_POS_X_BUFF -= TEXT_LENGTH
0B6F: render FONT draw_text STR_ZONE of pos DISPLAY_POS_X_BUFF DISPLAY_POS_Y color 0xFFFFFFFF
end
end

if TOGGLE_PING == 1
then
0B2B: samp ID = get_player_id_by_actor_handle $PLAYER_ACTOR
0B2A: samp PING = get_player_ping ID
0AD3: STR_PING = format "Ping: %d" PING
0085: FONT_SIZE_BUFF = FONT_SIZE // (int)
0012: FONT_SIZE_BUFF *= 10
0016: FONT_SIZE_BUFF /= 7
005A: DISPLAY_POS_Y_BUFF += FONT_SIZE_BUFF // (int)
if ALIGNMENT == 0 // left
then
0B6F: render FONT draw_text STR_PING of pos DISPLAY_POS_X DISPLAY_POS_Y_BUFF color 0xFFFFFFFF
else
0B6B: render TEXT_LENGTH = FONT get_length_of STR_PING
if ALIGNMENT == 1 //center
then
0016: TEXT_LENGTH /= 2
end
0085: DISPLAY_POS_X_BUFF = DISPLAY_POS_X
0062: DISPLAY_POS_X_BUFF -= TEXT_LENGTH
0B6F: render FONT draw_text STR_PING of pos DISPLAY_POS_X_BUFF DISPLAY_POS_Y_BUFF color 0xFFFFFFFF
end
end

if TOGGLE_FPS == 1
then
FPS_COUNT += 1
if 0AB1: @HalfSecondPassed 1 SYSTEM_TICK_COUNT _ret SYSTEM_TICK_COUNT
then
0085: FPS_COUNT_COPY = FPS_COUNT // get time interval
0012: FPS_COUNT_COPY *= 2
FPS_COUNT = 0
end
0AD3: STR_FPS = format "Fps: %d" FPS_COUNT_COPY
0085: FONT_SIZE_BUFF = FONT_SIZE // (int)
0012: FONT_SIZE_BUFF *= 10
0016: FONT_SIZE_BUFF /= 7
005A: DISPLAY_POS_Y_BUFF += FONT_SIZE_BUFF // (int)
if ALIGNMENT == 0 // left
then
0B6F: render FONT draw_text STR_FPS of pos DISPLAY_POS_X DISPLAY_POS_Y_BUFF color 0xFFFFFFFF
else
0B6B: render TEXT_LENGTH = FONT get_length_of STR_FPS
if ALIGNMENT == 1 //center
then
0016: TEXT_LENGTH /= 2
end
0085: DISPLAY_POS_X_BUFF = DISPLAY_POS_X
0062: DISPLAY_POS_X_BUFF -= TEXT_LENGTH
0B6F: render FONT draw_text STR_FPS of pos DISPLAY_POS_X_BUFF DISPLAY_POS_Y_BUFF color 0xFFFFFFFF
end
end
end
end

:Idle_loop
wait 5000
jump @Idle_loop

:changeAlignment
ALIGNMENT++
if ALIGNMENT > 2
then
ALIGNMENT = 0
end
0AF1: write_int ALIGNMENT to_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "alignment"
samp.CmdRet()

:adjustpos
wait 0
0B12: TOGGLE_MODE_ADJUSTPOS = TOGGLE_MODE_ADJUSTPOS XOR 1
if TOGGLE_MODE_ADJUSTPOS == 1
then
0B5D: samp toggle_cursor 1
else
0B5D: samp toggle_cursor 0
end
samp.CmdRet

:adjustsize
0B12: TOGGLE_MODE_ADJUSTSIZE = TOGGLE_MODE_ADJUSTSIZE XOR 1
if TOGGLE_MODE_ADJUSTSIZE == 0
then
0AF1: write_int FONT_SIZE to_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "font_size"
end
samp.CmdRet

:adjustflags
0B12: TOGGLE_MODE_ADJUSTFLAGS = TOGGLE_MODE_ADJUSTFLAGS XOR 1
if TOGGLE_MODE_ADJUSTFLAGS == 0
then
0AF1: write_int FONT_FLAGS to_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "font_flags"
end
samp.CmdRet

:tog_zone
0B12: TOGGLE_ZONE = TOGGLE_ZONE XOR 1
0AF1: write_int TOGGLE_ZONE to_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "location"
samp.CmdRet

:tog_ping
0B12: TOGGLE_PING = TOGGLE_PING XOR 1
0AF1: write_int TOGGLE_PING to_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "ping"
samp.CmdRet

:tog_fps
0B12: TOGGLE_FPS = TOGGLE_FPS XOR 1
0AF1: write_int TOGGLE_FPS to_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "fps"
samp.CmdRet

/*
:tog_
0B12: TOGGLE_ = TOGGLE_ XOR 1
0AF1: write_int 16 to_ini_file "CLEO\statDisplaySettings.ini" section "Settings" key ""
samp.CmdRet
:tog_
0B12: TOGGLE_ = TOGGLE_ XOR 1
0AF1: write_int 16 to_ini_file "CLEO\statDisplaySettings.ini" section "Settings" key ""
samp.CmdRet
*/

:help
0AF8: samp add_message_to_chat "{FF4800}Afisaj status {F7F694}comenzi:"
0AF8: samp add_message_to_chat "{FFFFFF}/as {F7F694}(Activezi / Dezactivezi Modul)"
0AF8: samp add_message_to_chat "{FFFFFF}/aspoz {F7F694}(Iti potrivesti pozitia)"
0AF8: samp add_message_to_chat "{FFFFFF}/asmarime {F7F694}(Potrivesti marimea fontului)"
0AF8: samp add_message_to_chat "{FFFFFF}/asalin {F7F694}(Schimbi pozitia textului, stanga ,centru ,dreapta)"
0AF8: samp add_message_to_chat "{FFFFFF}/asfont {F7F694}(Schimbi fontul)"
0AF8: samp add_message_to_chat "{FFFFFF}/aszona {F7F694}(Activezi/Dezactivezi zona)"
0AF8: samp add_message_to_chat "{FFFFFF}/asping {F7F694}(Activezi/Dezactivezi ping-ul)"
0AF8: samp add_message_to_chat "{FFFFFF}/asfps {F7F694}(Activezi/Dezactivezi fps-urile)"
samp.CmdRet()

:toggle
0B12: MOD_SWITCH = MOD_SWITCH XOR 1
0AF1: write_int MOD_SWITCH to_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "switch"
if MOD_SWITCH == 1
then
FPS_COUNT = 0
FPS_COUNT_COPY = 0
//0A8D: [email protected] = read_memory 0xB7CB84 size 4 virtual_protect 0
0AD1: show_formatted_text_highpriority "Afisaj Status este ~G~ON" time 700
else
0AD1: show_formatted_text_highpriority "Afisaj Status este ~R~OFF" time 700
end
samp.CmdRet()

//0AB1: @SecondPassed 1 second [email protected] _second [email protected]
:halfSecondPassed
0AA2: [email protected] = load_library "kernel32.dll" // IF and SET
if 0AA4: [email protected] = get_proc_address "GetTickCount" library [email protected]
then
[email protected] = 0 //GetSystemTimeA results in access violation if the pointer is NULL so just in case it's set to 1 first
//0AA5: call_function [email protected] num_params 1 pop 0 [email protected]
0AA7: call_function [email protected] num_params 0 pop 0 [email protected]
[email protected] = 0
0085: [email protected] = [email protected] //
0062: [email protected] -= [email protected] //
if 0019: [email protected] >= 500
then
0085: [email protected] = [email protected]
0485: return_true
else
059A: return_false
end
else
059A: return_false
end
0AA3: free_library [email protected]
0AB2: ret 1 [email protected]

//0AB1: @Position_stats 3 XY [email protected] [email protected]
:Position_stats
0B5D: samp toggle_cursor 1
if key_down 1
then
0B5E: get_cursor_pos [email protected] [email protected]
//0B5F: convert_window_screen_coords [email protected] [email protected] to_game_screen_coords [email protected] [email protected]
0AF1: write_int [email protected] to_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "x"
0AF1: write_int [email protected] to_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "y"
end
//03E3: set_texture_to_be_drawn_antialiased 6
//03F0: enable_text_draw 1
//038D: draw_texture 6 position [email protected] [email protected] size 129.142960 45.333576 RGBA 150 150 150 150
0AD1: show_formatted_text_highpriority "Apesi click oriunde pe ecran pentru a alege pozitia + foloseste /aspoz din nou pentru a iesi din edit." time 100 0xF7F694
0AB2: ret 2 [email protected] [email protected]

//0AB1: @Adjust_Font_Size 1
:Adjust_Font_Size
[email protected] = false
if key_down 104
then
[email protected] += 1
[email protected] = true
0485: return_true
else
if key_down 98
then
[email protected] -= 1
[email protected] = true
end
end
if 001B: 0 > [email protected]
then
[email protected] = 0
else
if 0019: [email protected] > 63
then
[email protected] = 63
end
end
0AD1: show_formatted_text_highpriority "Foloseste numpad 8 si 2 pentru a mari/micsora fontul + foloseste /asmarime din nou pentru a iesi din edit." time 100 0xF7F694
if [email protected] == true
then
0485: return_true
else
059A: return_false
end
0AB2: ret 1 [email protected]

//0AB1: @Adjust_Font_Flags 1
:Adjust_Font_Flags
[email protected] = false
if key_down 104
then
[email protected] += 1
[email protected] = true
0485: return_true
else
if key_down 98
then
[email protected] -= 1
[email protected] = true
end
end
if 001B: 0 > [email protected]
then
[email protected] = 0
else
if 0019: [email protected] > 63
then
[email protected] = 63
end
end
0AD1: show_formatted_text_highpriority "Foloseste numpad 8 si 2 pentru a seta fontul + foloseste /asfont din nou pentru a inchide editarea." time 100 0xF7F694
if [email protected] == true
then
0485: return_true
else
059A: return_false
end
0AB2: ret 1 [email protected]

 

 

 

Code translated to spanish:

 

 

{$CLEO}
0000:

const
FONT = [email protected]
ID = [email protected]
PING = [email protected]
STR_PING = [email protected]
STR_ZONE = [email protected]
STR_FPS = [email protected]
PLAYER_POS_X = [email protected]
PLAYER_POS_Y = [email protected]
PLAYER_POS_Z = [email protected]
FPS_COUNT = [email protected]
FPS_COUNT_COPY = [email protected]
SYSTEM_TICK_COUNT = [email protected]
DISPLAY_POS_X = [email protected]
DISPLAY_POS_Y = [email protected]
DISPLAY_POS_Y_BUFF = [email protected]
TOGGLE_MODE_ADJUSTPOS = [email protected]
TOGGLE_PING = [email protected]
TOGGLE_FPS = [email protected]
TOGGLE_ZONE = [email protected]
STR_FONT_NAME = [email protected]
MOD_SWITCH = [email protected]
FONT_SIZE = [email protected]
FONT_FLAGS = [email protected]
TOGGLE_MODE_ADJUSTSIZE = [email protected]
TOGGLE_MODE_ADJUSTFLAGS = [email protected]
FONT_SIZE_BUFF = [email protected]
TEXT_LENGTH = [email protected]
DISPLAY_POS_X_BUFF = [email protected]
ALIGNMENT = [email protected]

GTX_ZONENAME = s$93
end

alloc STR_PING 64
alloc STR_ZONE 64
alloc STR_FPS 64
alloc STR_FONT_NAME 64

repeat
wait 200
until 0AFA: is_samp_available
0B34: samp register_client_command "as" to_label @toggle
0B34: samp register_client_command "aspoz" to_label @adjustpos
0B34: samp register_client_command "ascomenzi" to_label @help
0B34: samp register_client_command "asping" to_label @tog_ping
0B34: samp register_client_command "asfps" to_label @tog_fps
0B34: samp register_client_command "aszona" to_label @tog_zone
0B34: samp register_client_command "asfont" to_label @adjustflags
0B34: samp register_client_command "asmarime" to_label @adjustsize
0B34: samp register_client_command "asalin" to_label @changeAlignment
0B34: samp register_client_command "astoggle" to_label @toggle
0B34: samp register_client_command "asposicion" to_label @adjustpos
0B34: samp register_client_command "asayuda" to_label @help
0B34: samp register_client_command "asping" to_label @tog_ping
0B34: samp register_client_command "asfps" to_label @tog_fps
0B34: samp register_client_command "aszona" to_label @tog_zone
0B34: samp register_client_command "asfuente" to_label @adjustflags
0B34: samp register_client_command "astamaño" to_label @adjustsize
0B34: samp register_client_command "asalineacion" to_label @changeAlignment
0AF8: samp add_message_to_chat "{F7F694}Afisaj Status. Usa {FF4800}/asayuda {F7F694}para mas comandos. Traducido por Carl_Mayhem"

/* flags
FCR_NONE 0 Text without features
FCR_BOLD 1 Fat content of the text
FCR_ITALICS 2 Bent (italic) text
FCR_BORDER 4 Dribbling text
FCR_SHADOW 8 text Shadow
FCR_UNDERLINE 16 Underlined text
FCR_STRIKEOUT 32 Strikethrough text
*/

if 0AAB: file_exists "CLEO\AfisajStatus.ini"
then
0AF4: STR_FONT_NAME = read_string_from_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "font_name"
0AF0: DISPLAY_POS_X = get_int_from_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "x"
0AF0: DISPLAY_POS_Y = get_int_from_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "y"
0AF0: MOD_SWITCH = get_int_from_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "switch"
0AF0: TOGGLE_PING = get_int_from_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "ping"
0AF0: TOGGLE_FPS = get_int_from_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "fps"
0AF0: TOGGLE_ZONE = get_int_from_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "location"
0AF0: FONT_SIZE = get_int_from_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "font_size"
0AF0: FONT_FLAGS = get_int_from_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "font_flags"
0AF0: ALIGNMENT = get_int_from_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "alignment"
else
0AF8: samp add_message_to_chat "{F7F694}CLEO\AfisajStatus.ini {FF4800}no encontrado. {F7F694}Mod mal instalado!"
jump @Idle_loop
end

0B6D: render FONT = create STR_FONT_NAME height FONT_SIZE flags FONT_FLAGS

while true
wait 0
if MOD_SWITCH == 1
then
0085: DISPLAY_POS_Y_BUFF = DISPLAY_POS_Y // (int)

//adjust modes
if TOGGLE_MODE_ADJUSTPOS == 1
then 0AB1: @Position_stats 2 DISPLAY_POS_X DISPLAY_POS_Y _return DISPLAY_POS_X DISPLAY_POS_Y
end

if TOGGLE_MODE_ADJUSTSIZE == 1
then
if 0AB1: @Adjust_Font_Size 1 FONT_SIZE _ret FONT_SIZE
then
0B6E: render release FONT
0B6D: render FONT = create STR_FONT_NAME height FONT_SIZE flags FONT_FLAGS
wait 100
end
end

if TOGGLE_MODE_ADJUSTFLAGS == 1
then
if 0AB1: @Adjust_Font_Flags 1 FONT_FLAGS _ret FONT_FLAGS
then
0B6E: render release FONT
0B6D: render FONT = create_font STR_FONT_NAME height FONT_SIZE flags FONT_FLAGS
wait 100
end
end

//texts
if TOGGLE_ZONE == 1
then
00A0: store_actor $PLAYER_ACTOR position_to PLAYER_POS_X PLAYER_POS_Y PLAYER_POS_Z
0843: get_zone_at PLAYER_POS_X PLAYER_POS_Y PLAYER_POS_Z nameA_to GTX_ZONENAME
0ADE: STR_ZONE = text_by_GXT_entry GTX_ZONENAME
if ALIGNMENT == 0 // left
then
0B6F: render FONT draw_text STR_ZONE of pos DISPLAY_POS_X DISPLAY_POS_Y color 0xFFFFFFFF
else
0B6B: render TEXT_LENGTH = FONT get_length_of STR_ZONE
if ALIGNMENT == 1 //center
then
0016: TEXT_LENGTH /= 2
end
0085: DISPLAY_POS_X_BUFF = DISPLAY_POS_X
0062: DISPLAY_POS_X_BUFF -= TEXT_LENGTH
0B6F: render FONT draw_text STR_ZONE of pos DISPLAY_POS_X_BUFF DISPLAY_POS_Y color 0xFFFFFFFF
end
end

if TOGGLE_PING == 1
then
0B2B: samp ID = get_player_id_by_actor_handle $PLAYER_ACTOR
0B2A: samp PING = get_player_ping ID
0AD3: STR_PING = format "Ping: %d" PING
0085: FONT_SIZE_BUFF = FONT_SIZE // (int)
0012: FONT_SIZE_BUFF *= 10
0016: FONT_SIZE_BUFF /= 7
005A: DISPLAY_POS_Y_BUFF += FONT_SIZE_BUFF // (int)
if ALIGNMENT == 0 // left
then
0B6F: render FONT draw_text STR_PING of pos DISPLAY_POS_X DISPLAY_POS_Y_BUFF color 0xFFFFFFFF
else
0B6B: render TEXT_LENGTH = FONT get_length_of STR_PING
if ALIGNMENT == 1 //center
then
0016: TEXT_LENGTH /= 2
end
0085: DISPLAY_POS_X_BUFF = DISPLAY_POS_X
0062: DISPLAY_POS_X_BUFF -= TEXT_LENGTH
0B6F: render FONT draw_text STR_PING of pos DISPLAY_POS_X_BUFF DISPLAY_POS_Y_BUFF color 0xFFFFFFFF
end
end

if TOGGLE_FPS == 1
then
FPS_COUNT += 1
if 0AB1: @HalfSecondPassed 1 SYSTEM_TICK_COUNT _ret SYSTEM_TICK_COUNT
then
0085: FPS_COUNT_COPY = FPS_COUNT // get time interval
0012: FPS_COUNT_COPY *= 2
FPS_COUNT = 0
end
0AD3: STR_FPS = format "Fps: %d" FPS_COUNT_COPY
0085: FONT_SIZE_BUFF = FONT_SIZE // (int)
0012: FONT_SIZE_BUFF *= 10
0016: FONT_SIZE_BUFF /= 7
005A: DISPLAY_POS_Y_BUFF += FONT_SIZE_BUFF // (int)
if ALIGNMENT == 0 // left
then
0B6F: render FONT draw_text STR_FPS of pos DISPLAY_POS_X DISPLAY_POS_Y_BUFF color 0xFFFFFFFF
else
0B6B: render TEXT_LENGTH = FONT get_length_of STR_FPS
if ALIGNMENT == 1 //center
then
0016: TEXT_LENGTH /= 2
end
0085: DISPLAY_POS_X_BUFF = DISPLAY_POS_X
0062: DISPLAY_POS_X_BUFF -= TEXT_LENGTH
0B6F: render FONT draw_text STR_FPS of pos DISPLAY_POS_X_BUFF DISPLAY_POS_Y_BUFF color 0xFFFFFFFF
end
end
end
end

:Idle_loop
wait 5000
jump @Idle_loop

:changeAlignment
ALIGNMENT++
if ALIGNMENT > 2
then
ALIGNMENT = 0
end
0AF1: write_int ALIGNMENT to_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "alignment"
samp.CmdRet()

:adjustpos
wait 0
0B12: TOGGLE_MODE_ADJUSTPOS = TOGGLE_MODE_ADJUSTPOS XOR 1
if TOGGLE_MODE_ADJUSTPOS == 1
then
0B5D: samp toggle_cursor 1
else
0B5D: samp toggle_cursor 0
end
samp.CmdRet

:adjustsize
0B12: TOGGLE_MODE_ADJUSTSIZE = TOGGLE_MODE_ADJUSTSIZE XOR 1
if TOGGLE_MODE_ADJUSTSIZE == 0
then
0AF1: write_int FONT_SIZE to_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "font_size"
end
samp.CmdRet

:adjustflags
0B12: TOGGLE_MODE_ADJUSTFLAGS = TOGGLE_MODE_ADJUSTFLAGS XOR 1
if TOGGLE_MODE_ADJUSTFLAGS == 0
then
0AF1: write_int FONT_FLAGS to_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "font_flags"
end
samp.CmdRet

:tog_zone
0B12: TOGGLE_ZONE = TOGGLE_ZONE XOR 1
0AF1: write_int TOGGLE_ZONE to_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "location"
samp.CmdRet

:tog_ping
0B12: TOGGLE_PING = TOGGLE_PING XOR 1
0AF1: write_int TOGGLE_PING to_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "ping"
samp.CmdRet

:tog_fps
0B12: TOGGLE_FPS = TOGGLE_FPS XOR 1
0AF1: write_int TOGGLE_FPS to_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "fps"
samp.CmdRet

/*
:tog_
0B12: TOGGLE_ = TOGGLE_ XOR 1
0AF1: write_int 16 to_ini_file "CLEO\statDisplaySettings.ini" section "Settings" key ""
samp.CmdRet
:tog_
0B12: TOGGLE_ = TOGGLE_ XOR 1
0AF1: write_int 16 to_ini_file "CLEO\statDisplaySettings.ini" section "Settings" key ""
samp.CmdRet
*/

:help
0AF8: samp add_message_to_chat "{FF4800}Afisaj status {F7F694}comenzi:"
0AF8: samp add_message_to_chat "{FFFFFF}/as {F7F694}(Activezi / Dezactivezi Modul)"
0AF8: samp add_message_to_chat "{FFFFFF}/aspoz {F7F694}(Iti potrivesti pozitia)"
0AF8: samp add_message_to_chat "{FFFFFF}/asmarime {F7F694}(Potrivesti marimea fontului)"
0AF8: samp add_message_to_chat "{FFFFFF}/asalin {F7F694}(Schimbi pozitia textului, stanga ,centru ,dreapta)"
0AF8: samp add_message_to_chat "{FFFFFF}/asfont {F7F694}(Schimbi fontul)"
0AF8: samp add_message_to_chat "{FFFFFF}/aszona {F7F694}(Activezi/Dezactivezi zona)"
0AF8: samp add_message_to_chat "{FFFFFF}/asping {F7F694}(Activezi/Dezactivezi ping-ul)"
0AF8: samp add_message_to_chat "{FFFFFF}/asfps {F7F694}(Activezi/Dezactivezi fps-urile)"
samp.CmdRet()

:toggle
0B12: MOD_SWITCH = MOD_SWITCH XOR 1
0AF1: write_int MOD_SWITCH to_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "switch"
if MOD_SWITCH == 1
then
FPS_COUNT = 0
FPS_COUNT_COPY = 0
//0A8D: [email protected] = read_memory 0xB7CB84 size 4 virtual_protect 0
0AD1: show_formatted_text_highpriority "Afisaj Status cambiado a ~G~ENCENDIDO" time 900
else
0AD1: show_formatted_text_highpriority "Afisaj Status cambiado a ~R~APAGADO" time 900
end
samp.CmdRet()

//0AB1: @SecondPassed 1 second [email protected] _second [email protected]
:halfSecondPassed
0AA2: [email protected] = load_library "kernel32.dll" // IF and SET
if 0AA4: [email protected] = get_proc_address "GetTickCount" library [email protected]
then
[email protected] = 0 //GetSystemTimeA results in access violation if the pointer is NULL so just in case it's set to 1 first
//0AA5: call_function [email protected] num_params 1 pop 0 [email protected]
0AA7: call_function [email protected] num_params 0 pop 0 [email protected]
[email protected] = 0
0085: [email protected] = [email protected] //
0062: [email protected] -= [email protected] //
if 0019: [email protected] >= 500
then
0085: [email protected] = [email protected]
0485: return_true
else
059A: return_false
end
else
059A: return_false
end
0AA3: free_library [email protected]
0AB2: ret 1 [email protected]

//0AB1: @Position_stats 3 XY [email protected] [email protected]
:Position_stats
0B5D: samp toggle_cursor 1
if key_down 1
then
0B5E: get_cursor_pos [email protected] [email protected]
//0B5F: convert_window_screen_coords [email protected] [email protected] to_game_screen_coords [email protected] [email protected]
0AF1: write_int [email protected] to_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "x"
0AF1: write_int [email protected] to_ini_file "CLEO\AfisajStatus.ini" section "Settings" key "y"
end
//03E3: set_texture_to_be_drawn_antialiased 6
//03F0: enable_text_draw 1
//038D: draw_texture 6 position [email protected] [email protected] size 129.142960 45.333576 RGBA 150 150 150 150
0AD1: show_formatted_text_highpriority "Usa el click para cambiar la posicion y /asposicion para salir del editor" time 100 0xF7F694
0AB2: ret 2 [email protected] [email protected]

//0AB1: @Adjust_Font_Size 1
:Adjust_Font_Size
[email protected] = false
if key_down 104
then
[email protected] += 1
[email protected] = true
0485: return_true
else
if key_down 98
then
[email protected] -= 1
[email protected] = true
end
end
if 001B: 0 > [email protected]
then
[email protected] = 0
else
if 0019: [email protected] > 63
then
[email protected] = 63
end
end
0AD1: show_formatted_text_highpriority "Usa NUMPAD 8 y 2 para aumentar/disminuir el tamaño de la fuente y /astamaño para salir del editor" time 100 0xF7F694
if [email protected] == true
then
0485: return_true
else
059A: return_false
end
0AB2: ret 1 [email protected]

//0AB1: @Adjust_Font_Flags 1
:Adjust_Font_Flags
[email protected] = false
if key_down 104
then
[email protected] += 1
[email protected] = true
0485: return_true
else
if key_down 98
then
[email protected] -= 1
[email protected] = true
end
end
if 001B: 0 > [email protected]
then
[email protected] = 0
else
if 0019: [email protected] > 63
then
[email protected] = 63
end
end
0AD1: show_formatted_text_highpriority "Usa NUMPAD 8 y 2 para cambiar la fuente y /asfuente para salir del editor" time 100 0xF7F694
if [email protected] == true
then
0485: return_true
else
059A: return_false
end
0AB2: ret 1 [email protected]

 

Link to comment
Share on other sites

Try going to Sanny Builder options, find Case Converting or something like that and select "As is" and then compile.

Edited by kosticn101
Link to comment
Share on other sites

TeReviento89

Try going to Sanny Builder options, find Case Converting or something like that and select "As is" and then compile.

 

That fixed, thanks!

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • 1 User Currently Viewing
    0 members, 0 Anonymous, 1 Guest

×
×
  • Create New...

Important Information

By using GTAForums.com, you agree to our Terms of Use and Privacy Policy.