[HELP] On admin shoot kill
#1

Hy guys...again me!!! I have a quastion for you! Can anywove make a script for me about admin shoot kill!!! When any player fight or shoot ADMIN with gun, the player Dead!!?
Reply
#2

I got a question for you, when you gonna learn proper English?

Damn..

EDITING TOPIC LATER...
Reply
#3

hahhaha YES! i dont speak much english! but can anywove make that script
Reply
#4

He means if player shoots at admin, the player dies
Reply
#5

yes!!!!!!!!!!!!!!!
Reply
#6

No-one is going to write a script for you. But I will give you some pointers on how to proceed.

You will firstly need to use OnPlayerTakeDamage.

Within this callback, you want to check if the receiver is an admin.

If they ARE an admin, you want the sender's health to be set to 0.

If you have any questions about how to achieve this, you are more than welcome to ask. But asking for a script in Scripting Discussion is not the way it works.

Have a go, test it out, if it doesn't work, come back and ask questions about how to IMPROVE your OWN coding
Reply
#7

Okey Rob!! I will try that! Thanks! |||||||| But can anybody als make it??
Reply
#8

No. As you can see, the purpose of scripting discussion is to discuss about scripting. Above you have got some great information that will help you script exactly what you asked for. So stop being lazy and develop it, and people will help you if you have questions while working on it.
Reply
#9

Quote:
Originally Posted by c0GI
Посмотреть сообщение
Okey Rob!! I will try that! Thanks! |||||||| But can anybody als make it??
This can't just be "made" because you'll need to have you admin system (which we'll get the variables from) and integrate it into your script. Anyway I've made a short one for you, but it only works if the Admins is logged-in to RCON.

pawn Код:
public OnPlayerTakeDamage(playerid, issuerid, Float:amount, weaponid)
{
    if(IsPlayerAdmin(playerid))
    {
        SetPlayerHealth(issuerid,0.0);
        SendClientMessage(issuerid,-1,"Don't kill an admin.");
    }
    return 1;
}
Reply
#10

Okeyyy! Thanks man!! ))
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)