SA-MP Forums Archive
[FilterScript] Mask System - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Filterscripts (https://sampforum.blast.hk/forumdisplay.php?fid=17)
+--- Thread: [FilterScript] Mask System (/showthread.php?tid=429525)



Mask System - Elysian` - 09.04.2013

Hello, I made this filterscript within 15 minutes and all it does right now is equips a HockeyMask2 to your face.

If you type /mask then your nametag disappears and when you type it comes up as stranger.
EX: "Stranger says: Give me your money!".

In Version 2 I'll add a dialog with a variety of mask you can place on your face.

Код:
[10/4/13]
- Initial Release
Download Link:
http://www.solidfiles.com/d/d4d0c444db/

To add this to your server:
- Download this to your 'filterscripts' folder.
- Go to server.cfg - Add "mask" to the filterscripts line. There should be a successful message to say it was loaded fully.
PLEASE NOTE: You need zcmd && sscanf for this to function properly!

Credits:
- Me.
- Zeke.
- ******.


Re: Mask System - iJumbo - 09.04.2013

This will fits correctly to all skins?

and sure you have to remove some unless things from your Filterscript such as ongamemodeinit or unused functions


Re: Mask System - betta - 09.04.2013

cool work


Re: Mask System - Elysian` - 09.04.2013

Quote:
Originally Posted by [ISS]jumbo
Посмотреть сообщение
This will fits correctly to all skins?

and sure you have to remove some unless things from your Filterscript such as ongamemodeinit or unused functions
Not too sure yet.. Maybe in V2?


Re: Mask System - Krisna - 10.04.2013

wow Nice Filterscript


Re: Mask System - Emmet_ - 10.04.2013

pawn Код:
format(string,sizeof(string), "Stranger", randomID);
SetPlayerName(playerid, string);
You formatted the string but forgot to add the placeholder, try this:

pawn Код:
format(string,sizeof(string), "Stranger%d", randomID);
SetPlayerName(playerid, string);
You should hide the player's name for other players rather than setting the player's name, good job though.


Re: Mask System - Riddick94 - 10.04.2013

Quote:
Originally Posted by iJumbo
Посмотреть сообщение
This will fits correctly to all skins?

and sure you have to remove some unless things from your Filterscript such as ongamemodeinit or unused functions
pawn Код:
#if defined FILTERSCRIPT

public OnFilterScriptInit()
{
    print("------------------------------");
    print("| Simple Mask System Loaded! |");
    print("|         Version v1.0!      |");
    print("------------------------------");
    return 1;
}

public OnFilterScriptExit()
{
    return 1;
}

#else

main()
{
    print("\n----------------------------------");
    print(" Blank Gamemode by your name here");
    print("----------------------------------\n");
}

#endif

public OnGameModeInit()
{
    // Don't use these lines if it's a filterscript
    SetGameModeText("Blank Script");
    AddPlayerClass(0, 1958.3783, 1343.1572, 15.3746, 269.1425, 0, 0, 0, 0, 0, 0);
    return 1;
}

public OnGameModeExit()
{
    return 1;
}

public OnPlayerRequestClass(playerid, classid)
{
    SetPlayerPos(playerid, 1958.3783, 1343.1572, 15.3746);
    SetPlayerCameraPos(playerid, 1958.3783, 1343.1572, 15.3746);
    SetPlayerCameraLookAt(playerid, 1958.3783, 1343.1572, 15.3746);
    return 1;
}

public OnPlayerSpawn(playerid)
{
    return 1;
}

public OnPlayerDeath(playerid, killerid, reason)
{
    return 1;
}

public OnVehicleSpawn(vehicleid)
{
    return 1;
}

public OnVehicleDeath(vehicleid, killerid)
{
    return 1;
}



Re: Mask System - Elysian` - 10.04.2013

Quote:
Originally Posted by Emmet_
Посмотреть сообщение
pawn Код:
format(string,sizeof(string), "Stranger", randomID);
SetPlayerName(playerid, string);
You formatted the string but forgot to add the placeholder, try this:

pawn Код:
format(string,sizeof(string), "Stranger%d", randomID);
SetPlayerName(playerid, string);

You should hide the player's name for other players rather than setting the player's name, good job though.
Ahh yeah! Thanks!

Quote:
Originally Posted by Riddick94
Посмотреть сообщение
pawn Код:
#if defined FILTERSCRIPT

public OnFilterScriptInit()
{
    print("------------------------------");
    print("| Simple Mask System Loaded! |");
    print("|         Version v1.0!      |");
    print("------------------------------");
    return 1;
}

public OnFilterScriptExit()
{
    return 1;
}

#else

main()
{
    print("\n----------------------------------");
    print(" Blank Gamemode by your name here");
    print("----------------------------------\n");
}

#endif

public OnGameModeInit()
{
    // Don't use these lines if it's a filterscript
    SetGameModeText("Blank Script");
    AddPlayerClass(0, 1958.3783, 1343.1572, 15.3746, 269.1425, 0, 0, 0, 0, 0, 0);
    return 1;
}

public OnGameModeExit()
{
    return 1;
}

public OnPlayerRequestClass(playerid, classid)
{
    SetPlayerPos(playerid, 1958.3783, 1343.1572, 15.3746);
    SetPlayerCameraPos(playerid, 1958.3783, 1343.1572, 15.3746);
    SetPlayerCameraLookAt(playerid, 1958.3783, 1343.1572, 15.3746);
    return 1;
}

public OnPlayerSpawn(playerid)
{
    return 1;
}

public OnPlayerDeath(playerid, killerid, reason)
{
    return 1;
}

public OnVehicleSpawn(vehicleid)
{
    return 1;
}

public OnVehicleDeath(vehicleid, killerid)
{
    return 1;
}
Erm..?


Re: Mask System - iJumbo - 10.04.2013

You just need

pawn Код:
public OnFilterScriptInit()
{
    print("------------------------------");
    print("| Simple Mask System Loaded! |");
    print("|         Version v1.0!      |");
    print("------------------------------");
    return 1;
}

public OnFilterScriptExit()
{
    return 1;
}
no the whole functions


Re: Mask System - Elysian` - 10.04.2013

Quote:
Originally Posted by iJumbo
Посмотреть сообщение
You just need

pawn Код:
public OnFilterScriptInit()
{
    print("------------------------------");
    print("| Simple Mask System Loaded! |");
    print("|         Version v1.0!      |");
    print("------------------------------");
    return 1;
}

public OnFilterScriptExit()
{
    return 1;
}
no the whole functions
Urm, What?