08.10.2013, 14:54
You said you read the wiki but you haven't looked enough, because otherwise you would have seen this example there:
https://sampwiki.blast.hk/wiki/TextDrawSetString
You just have to adjust the example above for leaving and joining messages. You'll have to make use of the callbacks OnPlayerConnect and OnPlayerDisconect to detect joining and leaving, then you will need to create your desired textdraws with the textdraw functions (you can make it look however you want). The TextDrawSetString function can be used to edit the text in your textdraw.
https://sampwiki.blast.hk/wiki/TextDrawSetString
Код:
new Text:himessage; public OnGameModeInit() { himessage = TextDrawCreate(1.0, 5.6, "Hi, how are you?"); return 1; } public OnPlayerConnect(playerid) { new newtext[41], name[MAX_PLAYER_NAME]; GetPlayerName(playerid, name, MAX_PLAYER_NAME); format(newtext, sizeof(newtext), "Hi %s, how are you?", name); TextDrawSetString(himessage, newtext); TextDrawShowForPlayer(playerid, himessage); return 1; }