Raised This Month: $51 Target: $400
 12% 

HEV suit emulation


Post New Thread Reply   
 
Thread Tools Display Modes
Plugin Info:     Modification:   Counter-Strike        Category:   Fun Stuff        Approver:   EKS (166)
MistaGee
Senior Member
Join Date: Aug 2004
Location: Germany (Fulda)
Old 08-13-2005 , 17:51   HEV suit emulation
Reply With Quote #1

This plugin emulates the HEV suit from Half-Life.

When ppl connect to the server., it plays a welcome sound that tells them the HEV is online.
If the cvar amx_hev_refill is set to anything larger than 0, the welcome sound will also tell users that automatic medical systems are online. The users will get the amount of HP set in the cvar when they got hurt, e.g. by falling down somewhere.
If ammunition depleted, the plugin will play a sound for that.
Whenever a player gets hurt, the plugin will check for the following:
If they fell down somewhere and lost lesss than 30 HP, this is a minor fracture.
If they fell down somewhere and lost more than 30 HP, this is a major fracture.
If they drown / burn / breathe nerve gas and so on, they will be told to evacutate this certain area.
If your HP is less than 26, you get a notice about vital signs being critical.


Requirements:
Cstrike module


Have Fun with it!

Greetz MGee
Attached Files
File Type: sma Get Plugin or Get Source (hevsuit.sma - 4007 views - 6.4 KB)
__________________
Ich hab nie behauptet dass ich kein Genie bin!
Mumble-Django: A web interface for Mumble
MistaGee is offline
Send a message via ICQ to MistaGee
CubicVirtuoso
Senior Member
Join Date: Sep 2004
Location: Canada
Old 08-13-2005 , 19:20  
Reply With Quote #2

Nice little part two to your other plugin they work nicely together.
__________________
Sig Under Construction.
CubicVirtuoso is offline
Send a message via ICQ to CubicVirtuoso Send a message via AIM to CubicVirtuoso Send a message via MSN to CubicVirtuoso Send a message via Yahoo to CubicVirtuoso
MistaGee
Senior Member
Join Date: Aug 2004
Location: Germany (Fulda)
Old 08-14-2005 , 08:19  
Reply With Quote #3

if you mean the ammunition depleted thingy, this HEV suit actually does that too :p
__________________
Ich hab nie behauptet dass ich kein Genie bin!
Mumble-Django: A web interface for Mumble
MistaGee is offline
Send a message via ICQ to MistaGee
CubicVirtuoso
Senior Member
Join Date: Sep 2004
Location: Canada
Old 08-14-2005 , 13:38  
Reply With Quote #4

Oh lol thats cool.
__________________
Sig Under Construction.
CubicVirtuoso is offline
Send a message via ICQ to CubicVirtuoso Send a message via AIM to CubicVirtuoso Send a message via MSN to CubicVirtuoso Send a message via Yahoo to CubicVirtuoso
F|4THeAd
Member
Join Date: Jan 2005
Old 08-16-2005 , 22:02  
Reply With Quote #5

That sounds awesome. Can someone make it work for other mods like The Specialists?
F|4THeAd is offline
MistaGee
Senior Member
Join Date: Aug 2004
Location: Germany (Fulda)
Old 08-17-2005 , 07:17  
Reply With Quote #6

np... I don't know anything about the Specialists, but I need a function to check how much ammo the user has left in backpack, since that is the only cstrike specific function in there...

How does TS handle its weapons? I only need to find out if all ammunition is gone or only the current clip was shot empty. If I can figure that out, changing the script is no problem.


Greetz MGee
__________________
Ich hab nie behauptet dass ich kein Genie bin!
Mumble-Django: A web interface for Mumble
MistaGee is offline
Send a message via ICQ to MistaGee
VercettiK
Junior Member
Join Date: Jun 2005
Location: Sao Paulo - Brazil
Old 08-17-2005 , 14:35  
Reply With Quote #7

Taken from tsfun.inc

Btw, check out this link:
http://www.amxmodx.org/funcwiki.php?...=ts_&go=search

Code:
native Float:ts_getusertime( index );
native ts_setusertime( index, Float:time );

native ts_getuserslots( index );
native ts_setuserslots( index, slots );

stock ts_has_stored_superjump(id) return (ts_getuseritems(id) & TSITEM_SUPERJUMP)
stock ts_has_stored_kungfoo(id) return (ts_getuseritems(id) & TSITEM_KUNGFU)
stock ts_has_stored_slowmo(id) return (ts_getuserpwup(id) == TSPWUP_SLOWMO)

stock ts_has_stored_infammo(id) return (ts_getuserpwup(id) == TSPWUP_INFAMMO)
stock ts_has_stored_slowpause(id) return (ts_getuserpwup(id) == TSPWUP_SLOWPAUSE)
stock ts_has_stored_dfirerate(id) return (ts_getuserpwup(id) == TSPWUP_DFIRERATE)

stock ts_has_stored_grenade(id) return (ts_getuserpwup(id) == TSPWUP_GRENADE)
stock ts_has_stored_health(id) return (ts_getuserpwup(id) == TSPWUP_HEALTH)
stock ts_has_stored_armor(id) return (ts_getuserpwup(id) == TSPWUP_ARMOR)

// Alters a fu attack. Use with fu forward
native ts_set_fuattack(id,Float:time,Float:damage)

// Changes board message
native ts_set_message(id,message)

// Gets the message board message
native ts_get_message(id)

stock ts_is_normal(id)
{
	new msg = ts_get_message(id)
	if( (msg > 11) || (msg > 6 && msg < 10) ) return 1;
	return 0;
}
stock ts_is_waiting(id) return (ts_get_message(id) == TSMSG_WAITING)
stock ts_is_dead(id) return (ts_get_message(id) == TSMSG_DEAD)
stock ts_is_killer(id) return (ts_get_message(id) == TSMSG_KILLER)
stock ts_is_demolition(id) return (ts_get_message(id) == TSMSG_DEMOLITION)
stock ts_is_specialist(id) return (ts_get_message(id) == TSMSG_SPECIALIST)
stock ts_is_unstoppable(id) return (ts_get_message(id) == TSMSG_UNSTOPPABLE)
stock ts_is_theone(id) return (ts_get_message(id) == TSMSG_THEONE)

// Return one on true, 0 on false
native ts_has_superjump(id)
native ts_has_fupowerup(id)
native ts_is_in_slowmo(id)

// Get and set consecutive frags
native ts_get_cons_frags(id)
native ts_set_cons_frags(id,num)

// Set to see cool bullet trails. Only id will see them.
native ts_set_bullettrail(id,yesorno)

// Sets fake versions of slow mo and slow pause. Use ts_set_speed for more options.
native ts_set_fakeslowmo(id,Float:time)
native ts_set_fakeslowpause(id,Float:time)

/* Sets speed artificially. 1.0 is default, Go into fractions and decimals for slower
* and put in higher numbers for higher speeds. Aura is how far things around you are effected
* Time is the time until it wears off. 0.0 for speed will freeze people. Do not use negatives. */

native ts_set_speed(id,Float:speed,Float:auradist,Float:time)

/* Sets physics speed artificially. Things like sparks and sounds will be effected.
* Any negative number will render all physics paused. */
native ts_set_physics_speed(id,Float:speed)

// Returns 0 if no powerup is running. Returns the powerup type otherwise.
native ts_is_running_powerup(id)

// Highly experimental command which overrides powerup types.
// Use if a powerup is already running, or if a powerup is not running.
// Safe to use in powerup forward.
native ts_force_run_powerup(id,PWUP_TYPE)
I don't think there's a special ammo function for TS, check this one out
http://www.amxmodx.org/funcwiki.php?go=func&id=157

[ EDIT ]
Found out functions here
Code:
native ts_getuserwpn( index,&clip,&ammo,&mode,&extra );
native ts_getusercash( index );
native ts_getuserspace( index );
native ts_getuserpwup( index,&Value );
native ts_getuseritems( index );
native ts_getuserkillflags(killer);
native ts_getkillingstreak( index );
native ts_getuserlastfrag( index );
From tsx.inc, maybe the ts_getuserwpn() would work.
__________________
VercettiK is offline
Send a message via ICQ to VercettiK Send a message via AIM to VercettiK Send a message via MSN to VercettiK Send a message via Yahoo to VercettiK
F|4THeAd
Member
Join Date: Jan 2005
Old 08-17-2005 , 14:43  
Reply With Quote #8

I don't know anything about writing AMXx plugins, but I think I found a function in the tsx.inc that looks like what it needs.

ts_getuserwpn( index,&clip,&ammo,&mode,&extra );
F|4THeAd is offline
MistaGee
Senior Member
Join Date: Aug 2004
Location: Germany (Fulda)
Old 08-18-2005 , 13:25  
Reply With Quote #9

I don't have TS so I can't try it, moreover I don't have time for amxx scripting atm... still, this looks like just a function to get the weapon data of how much ammo is left in the clip but not in the backpack...
__________________
Ich hab nie behauptet dass ich kein Genie bin!
Mumble-Django: A web interface for Mumble
MistaGee is offline
Send a message via ICQ to MistaGee
Charr
Senior Member
Join Date: Jul 2005
Location: Long Island, New York, U
Old 08-27-2005 , 19:09  
Reply With Quote #10

use:
Code:
new clip,ammo,mode,extra new weapon = ts_getuserwpn(id,clip,ammo,mode,extra)

clip is clip in ammo
ammo is total ammo left
mode is current firing mode
extra is any attachments to the gun
Charr is offline
Send a message via AIM to Charr Send a message via MSN to Charr
Reply



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 23:32.


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