|
gimik
|
 |
« on: November 29, 2009, 08:37:50 PM » |
|
I'm trying to make a ability where when you attack an enemy, you have 5-25% chance to give you and your whole team 25-100$. Here's what my attempt, its only partially done, if im not doing it correctly please fix. "skill1_setting" "es_xset wcs_chance 5|es_xset wcs_chance 10|es_xset wcs_chance 15|es_xset wcs_chance 20|es_xset wcs_chance 25" "racealias_cash" "es est_setcash(userid)) 25;es est_teamcash 25|
For the racealias_cash thats just for the first level, let me know if thats how i have to set it up.
|
|
|
|
|
Logged
|
|
|
|
|
Zawmbee
Guest
|
 |
« Reply #1 on: November 29, 2009, 10:35:05 PM » |
|
swing and a miss... sorry, but better luck next time.
|
|
|
|
|
Logged
|
|
|
|
|
gimik
|
 |
« Reply #2 on: November 29, 2009, 10:56:58 PM » |
|
That didn't really help me much, I'm just starting out so I'm doing the best i can. Can you show me how its supposed to be?
|
|
|
|
|
Logged
|
|
|
|
|
AvasT
|
 |
« Reply #3 on: November 29, 2009, 11:09:42 PM » |
|
In the setting set a chance for the skill and set the amount of cash that you want to be stealed, in the cmd use a check for the attacking team use a then and load the racealias, create 2 aliases, one ctsteals, and the other is tsteals, use a est_setcash #t for tsteals and #ct for ctsteals and set the amount. May i code it for you when i get at my home, im not in my house atm! but i'll try to code here xD
*EDIT, dont use a setcash, use cashadd, use a get to get the victims cash, use a xmath to subtract the cash that have been stole for the cash that the victims already have, and use the cashadd.
|
|
|
|
« Last Edit: November 29, 2009, 11:14:46 PM by AvasT »
|
Logged
|
Lol?
|
|
|
|
gimik
|
 |
« Reply #4 on: November 29, 2009, 11:24:58 PM » |
|
I want to give my team mates the cash aswell, how could you do that?
|
|
|
|
|
Logged
|
|
|
|
|
‹––тєxησ––›
|
 |
« Reply #5 on: November 29, 2009, 11:35:00 PM » |
|
I want to give my team mates the cash aswell, how could you do that?
Using Wcsadmin
|
|
|
|
|
Logged
|
|
|
|
|
gimik
|
 |
« Reply #6 on: November 29, 2009, 11:38:33 PM » |
|
Haha thats not what i meant.
|
|
|
|
|
Logged
|
|
|
|
|
AvasT
|
 |
« Reply #7 on: November 29, 2009, 11:45:08 PM » |
|
You don't want to steal right you just want to give cash ? I want to give my team mates the cash aswell, how could you do that?
Using Wcsadmin What a fucking idiot answer Sorry. But he asked for a skill.
|
|
|
|
|
Logged
|
Lol?
|
|
|
|
gimik
|
 |
« Reply #8 on: November 29, 2009, 11:48:25 PM » |
|
It doesn't have to steal no, just give cash to me and my team. If you wish to make it steal go ahead, i don't really mind.
|
|
|
|
|
Logged
|
|
|
|
|
AvasT
|
 |
« Reply #9 on: November 30, 2009, 12:20:04 AM » |
|
Well, so wait. I think the est_command for cash is est_cashadd! just use a check for teams then use a if for the team and use a then again and use the est_cashadd #team amount!
|
|
|
|
|
Logged
|
Lol?
|
|
|
|
gimik
|
 |
« Reply #10 on: December 02, 2009, 12:11:15 AM » |
|
How do you do a team check? I'm not sure how to do this skill yet.
|
|
|
|
|
Logged
|
|
|
|
|
Zawmbee
Guest
|
 |
« Reply #11 on: December 02, 2009, 12:48:22 AM » |
|
How do you do a team check? I'm not sure how to do this skill yet.
es est_getteam VARIABLE TARGET
|
|
|
|
|
Logged
|
|
|
|
|
gimik
|
 |
« Reply #12 on: December 02, 2009, 12:51:02 AM » |
|
so in this particular case, es est_getteam #ct cash? or do i not need to specify which team?
|
|
|
|
|
Logged
|
|
|
|
xpxdoo
Level 0 Beginner
Offline
 United States
Posts: 19
|
 |
« Reply #13 on: December 02, 2009, 12:52:08 AM » |
|
You should be able to skip a team check. It does it automatically whenever a skill is executed.
You just need something like "if (server_var(wcs_team) = 2) then est_cashadd #t server_var(cash)" and 3 then #ct
|
|
|
|
|
Logged
|
|
|
|
|
gimik
|
 |
« Reply #14 on: December 02, 2009, 12:57:16 AM » |
|
Could anyone code this skill for me? So i can look at the parts, cause i don't quite understand what you guys are trying to explain. Once i see the whole think completed ill be able to look at what you were saying  If you cant its no problem ill poke around with it.
|
|
|
|
|
Logged
|
|
|
|
|