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

Yoda


Post New Thread Reply   
 
Thread Tools Display Modes
imported_brad
Member
Join Date: Jun 2005
Location: miacigan
Old 08-02-2005 , 04:01  
Reply With Quote #11

Sweet hero
__________________
This Is My Server SuperHero*REC*[SHS] 24.192.203.197:61054 Come And Join For Free LVl 30 And 60 LVl's
imported_brad is offline
Send a message via MSN to imported_brad
SmokingJoePot
Member
Join Date: Aug 2007
Location: Dallas Texas
Old 08-26-2007 , 02:09   Re: Yoda
Reply With Quote #12

Can you make it for the new Super Hero Module version?
SmokingJoePot is offline
Send a message via AIM to SmokingJoePot Send a message via Yahoo to SmokingJoePot
genkernel
Junior Member
Join Date: Nov 2004
Old 09-02-2007 , 19:07   Re: Yoda
Reply With Quote #13

Does anyone know any reason that yoda would stop working? On my server yoda will work for a while then it will just stop working. I have to restart the server to make it work again.

Update:

Here is what I did to fix the people. In the force_push function I changed it to do a for loop searching all the players instead of relying to get_user_team. Here is the code that is working great for me.

Code:
public force_push(id)
{
	if ( !is_user_alive(id) ) return

	new team[33], players[SH_MAXSLOTS], pnum
  new origin[3], vorigin[3], parm[4], distance
	new Float:tempVelocity[3] = {0.0, 0.0, 200.0}
	new bool:enemyPushed = false


  for (new vic = 1; vic <= SH_MAXSLOTS; vic++)
  {
    if ( (is_user_alive(vic) && get_user_team(id) != get_user_team(vic)) || vic == id ) 
    {
		
      if( !is_user_alive(vic) ) continue
  
      get_user_origin(vic, vorigin)
  
      distance = get_distance(origin, vorigin)
  
      if ( distance < get_cvar_num("yoda_radius") ) {
        
        
        // Set cooldown/sound/self damage only once, if push is used
        if ( !enemyPushed ) {
          if (get_cvar_float("yoda_cooldown") > 0.0) ultimateTimer(id, get_cvar_float("yoda_cooldown"))
  
          emit_sound(id, CHAN_ITEM, "shmod/yoda_forcepush.wav", 1.0, ATTN_NORM, 0, PITCH_NORM)
  
          // Do damage to Yoda?
          if ( get_cvar_num("yoda_selfdmg") > 0 ) {
            shExtraDamage(id, id, get_cvar_num("yoda_selfdmg"), "Force Push")
          }
          enemyPushed = true
        }
  
        parm[0] = ((vorigin[0] - origin[0]) / distance) * get_cvar_num("yoda_power")
        parm[1] = ((vorigin[1] - origin[1]) / distance) * get_cvar_num("yoda_power")
        parm[2] = vic
        parm[3] = id
  
        // Stun enemy makes them easier to push
        shStun(vic, 1)
        set_user_maxspeed(vic, 1.0)
  
        // First lift them
        Entvars_Set_Vector(vic, EV_VEC_velocity, tempVelocity)
  
        // Then push them back in x seconds after lift and do some damage
        set_task(0.1, "move_enemy", 0, parm, 4)
      }
    }
  }

	if ( !enemyPushed && is_user_alive(id) ) {
		client_print(id, print_chat, "[SH](Yoda) No enemies within Range!")
		playSoundDenySelect(id)
	}
}

Last edited by genkernel; 09-04-2007 at 21:09.
genkernel is offline
st4l
Junior Member
Join Date: Feb 2008
Old 03-09-2008 , 23:11   Re: Yoda
Reply With Quote #14

англичане ебать :\
st4l is offline
killerman555
New Member
Join Date: Jun 2008
Old 06-01-2008 , 10:38   Re: Yoda
Reply With Quote #15

guys tell me how to add this hero in my server
killerman555 is offline
Dr. Jan Itor
Veteran Member
Join Date: Mar 2008
Location: there.
Old 06-01-2008 , 10:39   Re: Yoda
Reply With Quote #16

Quote:
Originally Posted by killerman555 View Post
guys tell me how to add this hero in my server

u put the .amxx files name in plugins-shero.ini
ex: sh_yoda.amxx in bottom of plugins-shero.ini
u put the sh_yoda.amxx in plugins
i hope u know where to put sounds , models, sprites
__________________
Dr. Jan Itor is offline
Sepehr
Senior Member
Join Date: Sep 2006
Location: www.aotclan.net
Old 02-04-2010 , 19:12   Re: Yoda
Reply With Quote #17

I was thinking of a good idea of this hero, it would be very cool if this hero was altered so it would have a version that when people go around the person it pushes them back, instead of them pressing the bind key, because i think there are tooooo many heroes that have a bind key attached to them.
__________________
Sepehr is offline
Send a message via MSN to Sepehr
Fr33m@n
Veteran Member
Join Date: May 2008
Location: France Marne
Old 02-05-2010 , 03:13   Re: Yoda
Reply With Quote #18

Try a loop or client_PreThink.

edit : i can do it, but try yourself.

Last edited by Fr33m@n; 02-05-2010 at 19:17.
Fr33m@n is offline
Exploited
Veteran Member
Join Date: Jul 2010
Location: Sweden
Old 09-23-2010 , 11:14   Re: Yoda
Reply With Quote #19

Code:
L 09/21/2010 - 14:31:55: Start of error session.
L 09/21/2010 - 14:31:55: Info (map "cs_winter_assault") (file "addons/amxmodx/logs/error_20100921.log")
L 09/21/2010 - 14:31:55: [AMXX] Displaying debug trace (plugin "sh_yoda.amxx")
L 09/21/2010 - 14:31:55: [AMXX] Run time error 11: divide 
L 09/21/2010 - 14:31:55: [AMXX]    [0] 20983.attach::force_push (line 154)
L 09/21/2010 - 14:31:55: [AMXX]    [1] 20983.attach::yoda_kd (line 108)
What happens is that it nearly never works for CTs (though sometimes it does) and sometimes it doesn't work for anyone.
It just says that theres no enemy within range and nothing happens. I tried Genkernles code but it wouldn't even compile.

Any ideas?
Exploited
__________________
Jelle (1): I LOVE YOU
Jelle (1): Yeah. omg you are so awesome!
--------------
Jelle (1): You know when a poo is about to exit but it is too big?
Jelle (1): God my ass still hurts

Last edited by vittu; 10-04-2010 at 20:56. Reason: made error message ledgible
Exploited is offline
Fr33m@n
Veteran Member
Join Date: May 2008
Location: France Marne
Old 09-23-2010 , 12:54   Re: Yoda
Reply With Quote #20

hum the flag e for get_players native sometimes don't work well.
the code need to be cleanned a bit.

Last edited by Fr33m@n; 09-23-2010 at 12:56.
Fr33m@n 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 08:51.


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