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

Ability to Push Another Player


Post New Thread Reply   
 
Thread Tools Display Modes
XunTric
BANNED
Join Date: Jan 2005
Location: Norway/Norge
Old 05-15-2005 , 05:16  
Reply With Quote #11

Quote:
Originally Posted by jtp10181
someone once requsted I made the superhero "blob" into a standalone plugin

here it is, works flawlessly.
Could you make a cvar for it on how "hard" or "fast" you push them?
Its boring when you can only push with the normall walk speed
XunTric is offline
v3x
Veteran Member
Join Date: Oct 2004
Location: US
Old 05-15-2005 , 14:30  
Reply With Quote #12

Try this:
Code:
#include <amxmodx> #include <amxmisc> #include <engine> public plugin_init() {     // Plugin Info     register_plugin("Blob Push","0.1","JTP10181")     register_cvar("push_velocity","320") } public pfn_touch(ptr, ptd) {     if (!is_valid_ent(ptr) || !is_valid_ent(ptd)) return     new ptrname[32], ptdname[32]     entity_get_string(ptr, EV_SZ_classname, ptrname, 31)     entity_get_string(ptd, EV_SZ_classname, ptdname, 31)     if(equal(ptrname,"player") && equal(ptdname,"player")) {         new Float:Vel[3]         new VelAmt = get_cvar_num("push_velocity")         VelocityByAim(ptr, VelAmt, Vel)         Vel[2] = 0.0 // Don't want user to go airbourne         entity_set_vector(ptd, EV_VEC_velocity, Vel)     } }
Cvar: push_velocity
__________________
What am I doing these days? Well, I run my own Rust server. It's heavily modded. If you'd like to join, the ip is 167.114.101.67:28116

I also created a website called Rust Tools. It will calculate and tell you the raw amounts of resources needed to craft items.
v3x is offline
n0obie4life
Veteran Member
Join Date: Dec 2004
Old 05-16-2005 , 09:34  
Reply With Quote #13

Quote:
Originally Posted by v3x
Try this:
Code:
#include <amxmodx> #include <amxmisc> #include <engine> public plugin_init() {     // Plugin Info     register_plugin("Blob Push","0.1","JTP10181")     register_cvar("push_velocity","320") } public pfn_touch(ptr, ptd) {     if (!is_valid_ent(ptr) || !is_valid_ent(ptd)) return     new ptrname[32], ptdname[32]     entity_get_string(ptr, EV_SZ_classname, ptrname, 31)     entity_get_string(ptd, EV_SZ_classname, ptdname, 31)     if(equal(ptrname,"player") && equal(ptdname,"player")) {         new Float:Vel[3]         new VelAmt = get_cvar_num("push_velocity")         VelocityByAim(ptr, VelAmt, Vel)         Vel[2] = 0.0 // Don't want user to go airbourne         entity_set_vector(ptd, EV_VEC_velocity, Vel)     } }
Cvar: push_velocity
v3x writes the "best" plugins ;). push push@
__________________
Plugins:
none

n0obie4life is offline
Johnny got his gun
Veteran Member
Join Date: Jan 2004
Location: Tokyo
Old 05-16-2005 , 12:24  
Reply With Quote #14

Quote:
Originally Posted by v3x
Try this:
Code:
#include <amxmodx> #include <amxmisc> #include <engine> new g_maxplayers public plugin_init() {     // Plugin Info     register_plugin("Blob Push","0.1","JTP10181")     register_cvar("push_velocity","320")     g_maxplayers = get_maxplayers() } public pfn_touch(ptr, ptd) {     if (ptr > g_maxplayers || ptd > g_maxplayers || ptr < 1 || ptd < 1)         return     if (!is_valid_ent(ptr) || !is_valid_ent(ptd)) return     new ptrname[32], ptdname[32]     entity_get_string(ptr, EV_SZ_classname, ptrname, 31)     entity_get_string(ptd, EV_SZ_classname, ptdname, 31)     if(equal(ptrname,"player") && equal(ptdname,"player")) {         new Float:Vel[3]         new VelAmt = get_cvar_num("push_velocity")         VelocityByAim(ptr, VelAmt, Vel)         Vel[2] = 0.0 // Don't want user to go airbourne         entity_set_vector(ptd, EV_VEC_velocity, Vel)     } }
Cvar: push_velocity
I edit the quote. Should be a tad optimized.
Johnny got his gun is offline
Brad
AMX Mod X Team Member
Join Date: Jun 2004
Old 05-16-2005 , 13:17  
Reply With Quote #15

Quote:
Originally Posted by n0obie4life
v3x writes the "best" plugins ;). push push@
v3x didn't create the plugin, here just made a minor modification to improve it. JTP is the creator as you should be able to tell from the first couple of posts in this thread.
Brad is offline
v3x
Veteran Member
Join Date: Oct 2004
Location: US
Old 05-16-2005 , 13:40  
Reply With Quote #16

Yea, what he said ^^,
__________________
What am I doing these days? Well, I run my own Rust server. It's heavily modded. If you'd like to join, the ip is 167.114.101.67:28116

I also created a website called Rust Tools. It will calculate and tell you the raw amounts of resources needed to craft items.
v3x is offline
gucio1200
Junior Member
Join Date: Feb 2012
Old 02-08-2012 , 18:11   Re: Ability to Push Another Player
Reply With Quote #17

As i understand this should push user by user staight away right ? I have compiled it and dont know why but do not work .
gucio1200 is offline
Devil259
Veteran Member
Join Date: Dec 2009
Location: France (59)
Old 02-09-2012 , 11:26   Re: Ability to Push Another Player
Reply With Quote #18

Last post was in 2005.
__________________
You can do anything you set your mind to, man.

Devil259 is offline
gucio1200
Junior Member
Join Date: Feb 2012
Old 02-09-2012 , 11:38   Re: Ability to Push Another Player
Reply With Quote #19

and thats the reason why it wont work
gucio1200 is offline
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 14:37.


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