Jump to content
Hostul a fost schimbat. Daca vedeti serverul offline readaugati rpg.b-zone.ro sau 141.95.124.78:7777 in clientul de sa-mp ×

Problema sanny builder


Mihai7CaSe
 Share

Recommended Posts

:test
SAMP.IsCommandTyped(20@)
if
0AD4: 20@ = scan_string 20@ format "%d %s" 0@ 1@
then
    0B36: samp 1@ = get_player_nickname 21@
    0AF9: samp say_msg " testez %s %d" 0@ 1@ // [0@ = numele 1@ = id]

    
    end
    cmdret

 

vreu ca aici sa in loc de &s si &d sa apara numele si id

Link to comment
Share on other sites

@Mihai7CaSE | Use this code:

0B34: samp register_client_command "test" to_label @test_name

:test_name
SAMP.IsCommandTyped(20@)
if 
	0AD4: 20@ = scan_string 20@ format "%d" 21@  
else_jump @test_error
	1@ = SAMP.GetPlayerNickname(21@)
	0AF9: samp say_msg "%s (%d)" 1@ 21@
jump @test_is_done 

:test_error
chatmsg "{FFFFFF}Error: Use /test <id>" -1

:test_is_done
0B43: samp cmd_ret

 

Link to comment
Share on other sites

{$CLEO}

0000:
repeat
wait 50
until 0AFA:

0B34: "test" @test

:loop
wait 0
jump @loop

:test
SAMP.IsCommandTyped(0@)
if 0AD4: 33@ = scan_string 0@ format "%d" 1@
then
       if SAMP.IsPlayerConnected(1@)
       then
              2@ = SAMP.GetPlayerNickname(1@)
              chatmsg "%s(%d)" -1 2@ 1@
       else chatmsg "Jucatorul nu este conectat!" -1
       end
else chatmsg "Use: /test <PlayerID>" -1
end
cmdret

 

Link to comment
Share on other sites

0b34: "re" @cmd10

 

:cmd10

SAMP.IsCommandTyped(0@)
if 0AD4: 33@ = scan_string 0@ format "%d" 1@
then
       if SAMP.IsPlayerConnected(1@)
       then
              2@ = SAMP.GetPlayerNickname(1@)
         say "/c Salut %s(%d)" 2@ 1@
       else 
       chatmsg "{f50a0a}({ffffff}Error{f50a0a}){ffffff} Jucatorul nu este conectat."  -1 1@
       end
else
     chatmsg "{f50a0a}({ffffff}Error{f50a0a}){ffffff} /re PlayerID" -1
end
cmdret

 

cand dau /re si un id care nu online imi iau crash.

eu vreu ca atunci cand imi apare textul in chat sa fie si timpstump alb.

Edited by Mihai7CaSE
Link to comment
Share on other sites

Primesti crash din mai multe motive:

1. In chatmsg esti limitat la circa 2/3 culori masix, tu ai vreo 4. Daca vrei ca mesajul de eroare sa fie tot alb atunci foloseste

chatmsg "Eroare: Jucatorul nu este conectat!" -1

2. Nu are ce cauta 1@ in acest mesaj de eroare

Link to comment
Share on other sites

  • Tupi locked this topic
Guest
This topic is now closed to further replies.
 Share

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.