Archived copy of warcraft-source.com, the Warcraft: Source (WCS) forum (2007–2011), rebuilt from the Internet Archive by wc3mods.net. This page was captured on 2010-02-04 (original capture). Home · Forum · All archived topics · Downloads
Warcraft-Source.com - WCS mod for CSS
February 04, 2010, 01:33:01 PM *
Welcome, Guest. Please login or register.
Login with username, password and session length
News: Please obey the rules, to achieve a pleasent order in our community.
Google  
  Home   Forum   Help Search Login Register   *
Pages: [1]   Go Down
  Print  
Author Topic: Tauren Warrior  (Read 245 times)
LordOfSuicide
Level 2 Apprentice
**
Offline Offline

United States United States

Posts: 49




itsourcer
godofanim3
« on: March 04, 2008, 04:46:18 AM »

No Idea what I did wrong, nothing works. The sound for player_spawn does, but not well. Its like... a chirping bird everytime someone spawns.
Skills:
  • Skill 1 - Tauren Hammer: Use your mighty tauren hammer to beat their heads in. Well its a knife skill that does 15 damage per level, and is supposed to have a brown ring 3... Doesn't work...
  • Skill 2 - Instinct: Evasion... thats all it really is. Still doesn't work...
  • Skill 3 - Call of the Wild: Big thing of armor when you spawn. Makes the chirpy noise thing.
  • Skill 4 - Ultimate/ War Stomp: Flings enemies into the air, but it was taken from Entangle because I didn't know how to code this. Doesn't work aswell.
So as you can see... Nothing works.  :cry:
Code
GeSHi (python):
'''
Tauren Warrior by LordOfSuicide
'
''
import es, wcs, gamethread, random, popuplib, playerlib
from wcs import wcs
name = 'Tauren Warrior'
race = wcs.Race(name)
race.registerSkill('Tauren Hammer', 5, 2, "Beat their heads in with your mighty hammer.")
race.registerSkill('Instinct', 5, 3, "Your instinct allows you to dodge bullets.")
race.registerSkill('Call of the Wild', 10, 1, "Natures vines give you tough armour.")
race.registerUltimate('War stomp', 10, 3, 3, "Use your mighty legs to knock them into the air.")
allowed_weapons = ('knife','hegrenade')
race.registerWeaponRestriction('allow only',allowed_weapons)
def player_hurt(ev):
   aid = ev['attacker']
   uid = ev['userid']
   wpn = ev['weapon']
   Hammer = wcs.GetLevel(aid, name, 'Tauren Hammer')
   if wpn == 'knife':
       player = wcs.Command(userid)
       player.Damage(Hammer * 15 , 128, aid)
       effect = wcs.Effect()
       effect.Ring3(victim, 150, 5, 150, 78, 0)
       sound = 'ambient/misc/hammer3.wav'
       es.emitsound('player',uid,sound,0.5,0.5)
   if attacker:
       damage = int(event_var['dmg_health'])
       instinct = wcs.GetLevel(aid, name, 'Instinct')
       if instinct:
           if instinct >= random.randint(instinct * 3,100):
               wcs.Command(userid).Heal(damage)
               es.tell(userid, '#multi', '#lightgreenInstinct #default- #greenYou fight with your heart and escaped from %s damage.'%damage)
def player_spawn(ev):
   uid = ev['userid']
   CotW = wcs.GetLevel(uid, name, 'Call of the Wild')
   wcs.Command(uid).Armor(CotW * 50)
   sound = 'ambient/animal/bird2.wav'
   es.emitsound('player',uid,sound,0.5,0.5)
   wcs.Effect().Misc6(uid,5,1)
def player_ultimate_on(event_var):
uid = int(event_var['userid'])
tem = int(es.getplayerteam(userid))
if tem == 2:
filter = '#ct'
elif tem == 3:
filter = '#t'
war = wcs.GetLevel(uid, name, 'War Stomp')
if war:
wcs.Command(uid).Near(150 * war,pgtw,filter)
wcs.Command(uid).SetCoolDown('War Stomp',30)
def pgtw (userid, attacker):
   wcs.Command(ev['userid']).Push(0,0,250)
   wcs.Effect().Ring1(ev['attacker'], 250, 5, 255, 255, 255)
   es.tell(userid, '#lightgreen', 'WAR STOMP!')
 

EDIT* Did what you guys said, but the skills still do not work for some reason.  :Huh:
« Last Edit: March 05, 2008, 05:03:39 AM by LordOfSuicide » Logged
Mouth662
Level 3 Trained Apprentice
***
Offline Offline

United States United States

Posts: 66


Your going to feel a little prick!


WWW
mouth662
mouth662
« Reply #1 on: March 04, 2008, 08:26:59 AM »

I used a few models... (kicks self in the teeth). Thanks for telling me man.
No problem, it sounds like a mistake id make lol, and for the errors j3ff did post a error log addon to save any errors that may occur, im going to download it right now actually now that i think of it
« Last Edit: March 04, 2008, 08:31:32 AM by Mouth662 » Logged

The_Last_Ghost
Level 3 Trained Apprentice
***
Offline Offline

Denmark Denmark

Posts: 76




The_Last_Ghost
thelastkaas
« Reply #2 on: March 04, 2008, 01:48:55 PM »

as far as the sound try using 1.0 for the volume instead of 0.5 1.0 is the max.
Code
GeSHi (python):
es.emitsound('player',uid,sound,1.0,0.5)

Since this is an es command, you probably want to change the 0.5 to something alot more, could be like 240 (20 feet), because es uses game-units as range.
Logged

- I will tell you what u want to hear, but not mean anything!
Jeff
Level 7 Expert
*****
Offline Offline

United States United States

Posts: 458



WWW
beastrace91
« Reply #3 on: March 04, 2008, 03:11:24 PM »

Yes this is why your skills are not trigging your 'race' global has a value of
Code
GeSHi (python):
wcs.Race(name)
while your 'name' global has a value of 'Tauren Warrior'

In other words try updating these:
Code
GeSHi (python):
wcs.GetLevel(aid, race, 'Tauren Hammer')
to
Code
GeSHi (python):
wcs.GetLevel(aid, name, 'Tauren Hammer')

As remember to try using the debug logger

~J3ff
Logged

Pages: [1]   Go Up
  Print  
 
Jump to:  

Last 7 Shouts:
Today at 02:33:47 AM
Sup?
Today at 02:33:37 AM
hey Ghost
Today at 01:44:10 AM
hey dark
February 02, 2010, 10:43:30 AM
Yap, he mean eventscripter xD
February 02, 2010, 01:03:48 AM
Eventscripter. lol
February 02, 2010, 12:23:17 AM
A WCS scripter?
February 01, 2010, 06:12:18 PM
izh lookeh for 1 scripter to supp0t me
Recent
[Today at 01:30:33 AM]

[Today at 12:44:51 AM]

[February 03, 2010, 11:57:35 PM]

[February 03, 2010, 11:17:14 PM]

[February 03, 2010, 10:05:11 PM]

[February 03, 2010, 09:50:54 PM]

[February 03, 2010, 06:40:35 PM]

[February 03, 2010, 05:37:57 PM]

[February 03, 2010, 04:33:23 PM]

[February 03, 2010, 02:30:39 PM]
Theme switch

Powered by MySQL Powered by PHP Powered by SMF 1.1.4 | SMF © 2006-2009, Simple Machines LLC
TinyPortal v0.9.8 © Bloc
Valid XHTML 1.0! Valid CSS!
Page created in 0.22 seconds with 24 queries.