Vice City: Multiplayer

Server Development => Scripting and Server Management => Snippet Showroom => Topic started by: wilber32 on Dec 11, 2015, 11:31 PM

Title: Anti-Spawnkill [fixed up]
Post by: wilber32 on Dec 11, 2015, 11:31 PM
Hello scripts of VCMP-0.4, Today I will show my spawn kill  [Caveat] No is copy! It is modified follow my steps

PlayerClass
{
AntiSP = false;
}

function onPlayerSpawn( player )
{
SP( player );
}

function onPlayerKill( player, killer, reason, bodypart )
{
 if ( stats[player.ID].AntiSP = true )
 {
  player.Health = 0;
  Message( "++ Auto-kill:[ " + player.Name + " ]. Reason:[ Spawn-Kill ]" );
 }
}

Functions

function SP( player )
{
 stats[player.ID].AntiSP = true;
  MessagePlayer( "Spawnkil [ON]", player );
 NewTimer( "SPoff", 5000, 1, player.ID );
}

function SPoff( player )
{
local player = FindPlayer(player);
if(player){
 stats[player.ID].AntiSP = false;
 MessagePlayer( "Spawnkil [OFF]", player );
}
}

credits by  [NxR]Wilber32.

(https://forum.vc-mp.org/proxy.php?request=http%3A%2F%2Fi62.tinypic.com%2F24vp5p3.jpg&hash=ef6720cb9f766b1cb35664da52790c6c0e8f8858)
Title: Re: Anti-Spawnkill [fixed up]
Post by: MatheuS on Dec 11, 2015, 11:49 PM
This script looks a lot like what Lucas created.

Link Here. (http://vcmp.liberty-unleashed.co.uk/forum/index.php?topic=1759.msg11803#msg11803)

But good job for posting. ;)
Title: Re: Anti-Spawnkill [fixed up]
Post by: KAKAN on Dec 12, 2015, 02:56 AM
Quote from: MatheuS on Dec 11, 2015, 11:49 PMThis script looks a lot like what Lucas created.

Link Here. (http://vcmp.liberty-unleashed.co.uk/forum/index.php?topic=1759.msg11803#msg11803)

But good job for posting. ;)
I don't even know what he "fixed up" and didn't even gave credits to Lucas
Title: Re: Anti-Spawnkill [fixed up]
Post by: wilber32 on Dec 12, 2015, 03:10 AM
I only did this system
Title: Re: Anti-Spawnkill [fixed up]
Post by: KAKAN on Dec 12, 2015, 03:14 AM
Quote from: wilber32 on Dec 12, 2015, 03:10 AMI only did this system
You didn't even made the "whole" system.
How can you use the array stats for the class PlayerStats?
Title: Re: Anti-Spawnkill [fixed up]
Post by: Thijn on Dec 12, 2015, 01:38 PM
And why do people keep using Timers for such things...
Title: Re: Anti-Spawnkill [fixed up]
Post by: wilber32 on Dec 12, 2015, 08:20 PM
if you're so scrit modifies this Thijn
Title: Re: Anti-Spawnkill [fixed up]
Post by: Thijn on Dec 12, 2015, 10:44 PM
Quote from: wilber32 on Dec 12, 2015, 08:20 PMif you're so scrit modifies this Thijn
There's been scripts posted that do this without a timer. Search for it.
Title: Re: Anti-Spawnkill [fixed up]
Post by: wilber32 on Dec 13, 2015, 04:24 AM
give me link
Title: Re: Anti-Spawnkill [fixed up]
Post by: KAKAN on Dec 13, 2015, 05:12 AM
1st of all we can't do everything for you, we're not your servants.
Quote from: wilber32 on Dec 13, 2015, 04:24 AMgive me link
Still then, http://forum.vc-mp.org/?topic=1871.0
Title: Re: Anti-Spawnkill [fixed up]
Post by: wilber32 on Dec 13, 2015, 05:33 AM
That did not work for me kakán
Title: Re: Anti-Spawnkill [fixed up]
Post by: KAKAN on Dec 13, 2015, 06:06 AM
Quote from: wilber32 on Dec 13, 2015, 05:33 AMThat did not work for me kakán
Your system didn't work for me, @wilber32
Title: Re: Anti-Spawnkill [fixed up]
Post by: wilber32 on Dec 13, 2015, 03:32 PM
You should fit your script
Title: Re: Anti-Spawnkill [fixed up]
Post by: KAKAN on Dec 13, 2015, 04:27 PM
Quote from: wilber32 on Dec 13, 2015, 03:32 PMYou should fit your script
According to you: I have my script "fit" please help me!
The script without timer works for me, but yours one doesn't works

Sorry for fighting :P
Title: Re: Anti-Spawnkill [fixed up]
Post by: wilber32 on Dec 13, 2015, 05:28 PM
You're smart, When the timer is ON , He killed the player and appears spawnkill, But as time passes employee He killed the player and appears spawnkill.
I noticed after -.-! that bug
Title: Re: Anti-Spawnkill [fixed up]
Post by: dEaN on Dec 15, 2015, 04:37 PM
already edit by me..
Title: Re: Anti-Spawnkill [fixed up]
Post by: hotdogcat on Dec 15, 2015, 10:54 PM
i don't understand...
why so much dramas for a script?
Title: Re: Anti-Spawnkill [fixed up]
Post by: Thijn on Dec 16, 2015, 06:41 AM
Quote from: hotdogcat on Dec 15, 2015, 10:54 PMi don't understand...
why so much dramas for a script?
Welcome to the VC:MP Official forums.
Title: Re: Anti-Spawnkill [fixed up]
Post by: wilber32 on Dec 17, 2015, 01:42 AM
Lol Hotdogcat Thijn if you're so script help me with that, what he hotdogcat says is true