CLEO Help TEXT_BOX

CLEO related
Status
Not open for further replies.

KamikazeSripterul

Well-known member
Joined
Jun 30, 2019
Messages
353
Reaction score
23
So I've tried to make a textbox once the whole script has been running but when i test it in game, nothing happens.
Code:
alloc 2@ 260
    0B75: samp get_chat_string 99 text_to 2@ prefix_to 3@ color_to 4@ prefix_color_to 5@
    
    if or
    4@ == 0xffffd700           
    4@ == 0xff4dad2b
    then
        if
        0C29: $not_used = strstr string1 2@ string2 "Your account balance is now"
    then   
        0AB1: @GetText 1 WriteStringPointer 2@ rnt 15@
        0AF5: write_string 15@ to_ini_file "cleo\ServerCMD.ini" section "Bank" key "balance"       
        0ACE: show_formatted_text_box "There was a change at your bank account balance! Use /bankmenu in order to see new changes." -1
        wait 5000
        end
    end   
free 2@
Can anyone help? Thanks
 

KamikazeSripterul

Well-known member
Joined
Jun 30, 2019
Messages
353
Reaction score
23
@Parazitas the thing is, i want to make a message that wont appear in chat but also it will appear somewhere on the screen then after 5-6 sec it will disappear. Thats why i thought of a text box
 

Parazitas

God
Joined
Jan 2, 2017
Messages
3,104
Solutions
5
Reaction score
882
Location
Lithuania
PHP:
:DRAW_TEXT
{
    0AB1: @DRAW_TEXT 3 X 160.0 Y 230.0 String 22@
}
03F0: enable_text_draw 1
0342: set_text_draw_centered 1
03E0: draw_text_behind_textures 0
0340: set_text_draw_RGBA 66 195 227 255
033F: set_text_draw_letter_size width 0.205 height 0.955
0349: set_text_draw_font 2
060D: draw_text_shadow 0 rgba 43 43 43 255
0AA8: call_function_method 0x6A0050 0xC1B340 num_params 1 pop 0 'CRED036' 4@ //// Get gxt text address by gxt name
0AA5: call 0x718600 2 pop 2 4@ 2@ // 2@ = TEXT
033E: set_draw_text_position 0@ 1@ GXT 'CRED036' // "String"
0AB2: 0
 

KamikazeSripterul

Well-known member
Joined
Jun 30, 2019
Messages
353
Reaction score
23
PHP:
:DRAW_TEXT
{
    0AB1: @DRAW_TEXT 3 X 160.0 Y 230.0 String 22@
}
03F0: enable_text_draw 1
0342: set_text_draw_centered 1
03E0: draw_text_behind_textures 0
0340: set_text_draw_RGBA 66 195 227 255
033F: set_text_draw_letter_size width 0.205 height 0.955
0349: set_text_draw_font 2
060D: draw_text_shadow 0 rgba 43 43 43 255
0AA8: call_function_method 0x6A0050 0xC1B340 num_params 1 pop 0 'CRED036' 4@ //// Get gxt text address by gxt name
0AA5: call 0x718600 2 pop 2 4@ 2@ // 2@ = TEXT
033E: set_draw_text_position 0@ 1@ GXT 'CRED036' // "String"
0AB2: 0
0AB1: @DRAW_TEXT 3 X 160.0 Y 230.0 String 22@
what is string 22@?
 

Parazitas

God
Joined
Jan 2, 2017
Messages
3,104
Solutions
5
Reaction score
882
Location
Lithuania
String....
Just do like :
Alloc 10@ 260
Format 10@ "hello"
0AB1: @DRAW_TEXT 3 X 160.0 Y 230.0 String 10@
 
Last edited:
Status
Not open for further replies.
Top