Locking skins
#1

How do i make it so that if someone enters the wrong password it says Wrong Password
also what is wrong with this script

pawn Код:
#define FILTERSCRIPT

#include <a_samp>
new locked[MAX_PLAYERS];

#if defined FILTERSCRIPT

public OnFilterScriptInit()
{
    print("\n--------------------------------------");
    print(" Blank Filterscript by your name here");
    print("--------------------------------------\n");
    return 1;
}
public OnGameModeInit()
{
    AddPlayerClass(294, 0, 0, 0, 130, 24, 300, 0, 0, 0, 0); //Class 1 - Not passworded
    AddPlayerClass(188, 0, 0, 0, 130, 24, 300, 0, 0, 0, 0); //Class 2 - Passworded
    return 1;
}
public OnPlayerRequestClass(playerid, classid)
{
    switch(classid)
    {
    case 0: Locked[playerid] = 1; //this one DOESNT.
    case 1: Locked[playerid] = 1; //this one too
    }
    return 1;
 }
public OnPlayerRequestSpawn(playerid)
{
    if(Locked[playerid]) return 0;
    //If player's current class is passworded, stop them from spawning
    return 1;
}
public OnPlayerCommandText(playerid, cmdtext[])
{
    if(!strcmp(cmdtext, "/unlock test "))
    {
        Locked[playerid] = 0;
        SendClientMessage(playerid, COLOR_GREEN, "Skins unlocked!");
    }
    return 1
Reply


Messages In This Thread
Locking skins - by Jack- - 01.01.2011, 07:11
Re: Locking skins - by Haydz - 01.01.2011, 07:19
Re: Locking skins - by Stryke - 12.09.2011, 16:22
Re: Locking skins - by judothijs - 12.09.2011, 16:41
Re: Locking skins - by DRIFT_HUNTER - 12.09.2011, 16:47

Forum Jump:


Users browsing this thread: 1 Guest(s)