Raised This Month: $95 Target: $400
 23% 

Friendly Fire On Before map end


Post New Thread Reply   
 
Thread Tools Display Modes
Plugin Info:     Modification:   Counter-Strike        Category:   Fun Stuff        Approver:   Hawk552 (427)
YamiKaitou
Has a lovely bunch of coconuts
Join Date: Apr 2006
Location: Texas
Old 05-17-2007 , 00:24   Friendly Fire On Before map end
Reply With Quote #1

Made by request of Šiego ( http://forums.alliedmods.net/showthread.php?t=54622 )

This plugin turns friendlyfire on and will respawn you if you die after it is turned on during the last x seconds of the map.


Cvars:
ff_message <message to be displayed. Max of 256 characters> (Default: "FF ON! KILL 'EM ALL!!")
ff_time <length of ff on time> (Default: 60.0)
ff_revive <1/0> (Default 1/On) (Whether or not to revive players. If using CSDM, set this to 0)

When the player is revived, they are given their teams pistol, a knife, and a mp5.

The plugin plays a sound when ff is turned on. It is defaulted to misc/killingspree.wav. To change it, you need to edit this line to the location of the file within the sound folder (must be a .wav or a .mp3 file)
Code:
#define SOUND "misc/killingspree.wav"


This is my first public plugin. Hopefully nobody hates it
Attached Files
File Type: sma Get Plugin or Get Source (ffonend.sma - 2560 views - 4.1 KB)
__________________
ProjectYami Laboratories

I do not browse the forums regularly anymore. If you need me for anything (intervening in a thread, asking questions or anything else), then PM me (be descriptive in your PM, message containing only a link to a thread will be ignored).

Last edited by YamiKaitou; 03-28-2008 at 17:24. Reason: Updated version
YamiKaitou is offline
Juba_PornBorn
BANNED
Join Date: Apr 2007
Location: Caracas
Old 05-17-2007 , 01:48   Re: Friendly Fire On Before map end
Reply With Quote #2

Killing frenzy at the end. Everyone likes to do it in my server. Im gonna take a look. Gonna put the "shark" music theme. But could you do it with a funny song already and a cvar for it that lasts looping all the last seconds? Do players keep respawning at the end(no need at deathmatch will it get in conflit)?

Last edited by Juba_PornBorn; 05-17-2007 at 01:51.
Juba_PornBorn is offline
Send a message via MSN to Juba_PornBorn
YamiKaitou
Has a lovely bunch of coconuts
Join Date: Apr 2006
Location: Texas
Old 05-17-2007 , 02:15   Re: Friendly Fire On Before map end
Reply With Quote #3

Yes, if you die after the ff turns on, you get revived. If you die before, you are out of luck. Not sure if csdm will conflict with it or not, I don't run a csdm server anymore. Maybe I should add a check to see if csdm is running.

I would have to figure out how to do the lopping, but I will try it out.
__________________
ProjectYami Laboratories

I do not browse the forums regularly anymore. If you need me for anything (intervening in a thread, asking questions or anything else), then PM me (be descriptive in your PM, message containing only a link to a thread will be ignored).
YamiKaitou is offline
YamiKaitou
Has a lovely bunch of coconuts
Join Date: Apr 2006
Location: Texas
Old 05-17-2007 , 02:36   Re: Friendly Fire On Before map end
Reply With Quote #4

Updated with a new cvar.

ff_revive <1/0> (Default 1/On)

Set this to 0 if you are using CSDM or any other form of auto respawn plugins, just to avoid conflicts.
__________________
ProjectYami Laboratories

I do not browse the forums regularly anymore. If you need me for anything (intervening in a thread, asking questions or anything else), then PM me (be descriptive in your PM, message containing only a link to a thread will be ignored).
YamiKaitou is offline
Juba_PornBorn
BANNED
Join Date: Apr 2007
Location: Caracas
Old 05-17-2007 , 04:20   Re: Friendly Fire On Before map end
Reply With Quote #5

does the music still plays and ff turn on right?
Juba_PornBorn is offline
Send a message via MSN to Juba_PornBorn
YamiKaitou
Has a lovely bunch of coconuts
Join Date: Apr 2006
Location: Texas
Old 05-17-2007 , 11:03   Re: Friendly Fire On Before map end
Reply With Quote #6

If you have ff_time set to 60.0 seconds, then 60 seconds before the map ends, the plugins turns mp_friendlyfire to 1, mp_autokick to 0, displays a flashing hud saying the value of ff_message, and will play the sound when it turns ff on. Then, if ff_revive is set to 1, any user that dies during this time is revived and given some weapons. If the player died before this activated, they are out of luck.

There is maybe a better description of what this plugin does.
__________________
ProjectYami Laboratories

I do not browse the forums regularly anymore. If you need me for anything (intervening in a thread, asking questions or anything else), then PM me (be descriptive in your PM, message containing only a link to a thread will be ignored).
YamiKaitou is offline
Hawk552
AMX Mod X Moderator
Join Date: Aug 2005
Old 05-26-2007 , 11:34   Re: Friendly Fire On Before map end
Reply With Quote #7

Ah, nice. I've always wanted to do something like this in game.

Approved.
__________________
Hawk552 is offline
Send a message via AIM to Hawk552
purple nurple
Senior Member
Join Date: Jun 2007
Location: US Missouri
Old 03-26-2008 , 16:17   Re: Friendly Fire On Before map end
Reply With Quote #8

Code:
if (containi(sound2,".wav"))
            replace(sound2,128,".wav","");
        else if (containi(sound2,".mp3"))
            replace(sound2,128,".mp3","");
        client_cmd(0, "spk %s",sound2);
That will only work is its a .wav spk doesn't support mp3 it has to be "mp3 play %s"
purple nurple is offline
YamiKaitou
Has a lovely bunch of coconuts
Join Date: Apr 2006
Location: Texas
Old 03-26-2008 , 16:29   Re: Friendly Fire On Before map end
Reply With Quote #9

I made this when I didn't know there was a difference, then forgot about this plugin. You brought this back just to tell me this, lol. You must be really bored. Will fix later if I remember.
__________________
ProjectYami Laboratories

I do not browse the forums regularly anymore. If you need me for anything (intervening in a thread, asking questions or anything else), then PM me (be descriptive in your PM, message containing only a link to a thread will be ignored).
YamiKaitou is offline
spiderbites
Senior Member
Join Date: Nov 2007
Old 03-28-2008 , 17:07   Re: Friendly Fire On Before map end
Reply With Quote #10

bump..

YamiKaitou..fixed now?
spiderbites is offline
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

Forum Jump


All times are GMT -4. The time now is 02:16.


Powered by vBulletin®
Copyright ©2000 - 2020, vBulletin Solutions, Inc.
Theme made by Freecode