SA-MP Forums

Go Back   SA-MP Forums > SA-MP Scripting and Plugins > Filterscripts > Includes

Reply
 
Thread Tools Display Modes
Old 27/04/2018, 07:40 AM   #1
jlalt
High-roller
 
Join Date: Oct 2014
Location: Iran
Posts: 1,447
Reputation: 366
Default Name Highlighter

What's this?
Its a simple include which includes only one function to highlight player name which is mentioned in a string.

What
Do @Name to highlight a player name in a string with his in game color.

Usage example:
PHP Code:
#include <NH>

public OnPlayerText(playeridtext[])
{
    new 
newtext[320];
    
GetPlayerCalledName(playeridtextnewtext/*,.defaultcolor = YourDefaultChatColor, .nowhite = false = to accept white players color or to change it into red*/);
    
SendClientMessageToAll(-1newtext);
    return 
0;


Result:







Project:

Github
Download
jlalt is offline   Reply With Quote
Old 27/04/2018, 05:11 PM   #2
RogueDrifter
High-roller
 
RogueDrifter's Avatar
 
Join Date: Dec 2017
Location: SA-MP Drifting world.
Posts: 1,565
Reputation: 338
Default Re: Name Highlighter

I was just thinking of making something similar, good job.
__________________
Code:
I'm available to script stuff for cash PM me here or on discord @ Andy[RDZ]#0040
[Tutorial]:Anti-cheat guide ||Mini-game 101||VC/LC maps install||
Array index out of bounds


[Github]:Link [Pastebin]:Link [Forum]:Link [Server]:Link [Discord]:Link


RogueDrifter is offline   Reply With Quote
Old 27/04/2018, 05:23 PM   #3
RxErT
Huge Clucker
 
RxErT's Avatar
 
Join Date: May 2016
Location: SA:MP Lemon
Posts: 258
Reputation: 12
Default Re: Name Highlighter

Oh man this is so lit!

So it does give each player unique color when marking their names?
What if we marked an un-existing player name, will it still highlighting his name?
__________________
Filterscript:[UPDATED] DM Event [Friendly, Funny, Controllable]
Filterscript:[NEW] New Simple Parkour Event]
Snippet:Whisper and Car whisper commands, controllable
Discord: Flofey#8478
Github: RxErT's profile
Working-on: Administration script Based on SQLite
RxErT is offline   Reply With Quote
Old 27/04/2018, 06:01 PM   #4
jlalt
High-roller
 
Join Date: Oct 2014
Location: Iran
Posts: 1,447
Reputation: 366
Default Re: Name Highlighter

Quote:
Originally Posted by RxErT View Post
Oh man this is so lit!

So it does give each player unique color when marking their names?
What if we marked an un-existing player name, will it still highlighting his name?
It gives them the color of GetPlayerColor and leaves the name without highlight if player isn't connected.
jlalt is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
[Tool/Web/Other] Code Highlighter - Highlight code to find brackets, organize code, ... Sinner Tools and Files 8 09/03/2012 01:28 PM
Pawn code highlighter for php/html? kayle Help Archive 3 20/03/2011 08:48 AM


All times are GMT. The time now is 04:51 PM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.