wc3campaigns
WC3C Homepage - www.wc3c.netUser Control Panel (Requires Log-In)Engage in discussions with other users and join contests in the WC3C forums!Read one of our many tutorials, ranging in difficulty from beginner to advanced!Show off your artistic talents in the WC3C Gallery!Download quality models, textures, spells (vJASS/JASS), systems, and scripts!Download maps that have passed through our rigorous approval process!

Go Back   Wc3C.net > Resources > Code Resources > vJass Spells
User Name
Password
Register Rules Get Hosted! Chat Pastebin FAQ and Rules Members List Calendar



Reply
 
Thread Tools Search this Thread
Old 05-07-2009, 08:22 PM   #46
Rising_Dusk
Obscurity, the Art


Projects Director
Project Leader: OD
 
Join Date: Feb 2006
Posts: 9,729

Submissions (27)

Rising_Dusk has a reputation beyond repute (1192)Rising_Dusk has a reputation beyond repute (1192)Rising_Dusk has a reputation beyond repute (1192)Rising_Dusk has a reputation beyond repute (1192)Rising_Dusk has a reputation beyond repute (1192)Rising_Dusk has a reputation beyond repute (1192)Rising_Dusk has a reputation beyond repute (1192)Rising_Dusk has a reputation beyond repute (1192)Rising_Dusk has a reputation beyond repute (1192)

Hero Contest #3 - 1st PlaceApproved Map: Desert of ExileApproved Map: Advent of the ZenithHero Contest #2 - 1st PlaceHero Contest - Third place>

Send a message via AIM to Rising_Dusk Send a message via MSN to Rising_Dusk
Default

I'm not exactly sure what exactly Anitarf meant by 'devour multiple units.' I was just saying what I think, but I feel that Anitarf should indeed clarify.
__________________
Rising_Dusk is offline   Reply With Quote
Sponsored Links - Login to hide this ad!
Old 05-08-2009, 01:26 AM   #47
moyack
Evil Emoticon
 
moyack's Avatar


Respected User
Project Leader: PoC
 
Join Date: Jan 2006
Posts: 3,279

Submissions (17)

moyack is a splendid one to behold (666)moyack is a splendid one to behold (666)moyack is a splendid one to behold (666)moyack is a splendid one to behold (666)

AI Tournament #2 - 2nd PlaceHero Contest - Second place

Send a message via MSN to moyack
Default

Quote:
Originally Posted by Rising_Dusk
This is absolutely wrong. The value of LastOrder + AbortSpell + SimError is that it actually maintains the exact Blizzard behavior of errors, maintaining previous orders, and the display of error messages. If you just use stop, you lose that entire aspect of the behavior, which sucks.
what's wrong is to use such amount of libraries for a warning message. Do you want a Blizzard behavior? why not doing this?

Collapse JASS:
private function OnOrder takes nothing returns boolean
     local unit u = GetTriggerUnit()
     if IsUnitInGroup(u,isDevouring) and GetIssuedOrderId() == SpellOrderId then
        call SimError(GetOwningPlayer(u),SpellErrorMessage)
        call IssueTargetOrder(u, "smart", GetOrderTarget()) // yes, this replaces 2 libraries...
     endif
     set u = null
     return false
endfunction

And tested.
Attached Files
File Type: w3x Devour.w3x (46.4 KB, 11 views)
moyack is offline   Reply With Quote
Old 05-08-2009, 02:23 PM   #48
Flame_Phoenix
retired coder | real ilfe
 
Flame_Phoenix's Avatar
 
Join Date: Mar 2007
Posts: 2,208

Submissions (10)

Flame_Phoenix has a spectacular aura about (90)Flame_Phoenix has a spectacular aura about (90)Flame_Phoenix has a spectacular aura about (90)Flame_Phoenix has a spectacular aura about (90)

Send a message via MSN to Flame_Phoenix
Default

@Moyack:
Some people see it as "not being modular" if I am not mistaken. If you take a close look to my Launch Seal spell, you will see I also had this problem, and that I also had to add the libraries.
You may also see, it is still waiting for approval ... but that is because of another reason ... (somehow and for some reason no one mods knockback systems around here ...)
__________________
Check out my tutorials at:
1-Creating a Hero Tavern
2-Complete Icon Tutorial - ALL about Icons
3-Making a spell in vJass - Practice Session 1
Check out all my current spells at here
Finally, check my project:
Castle vs Castle Flame Edition
Flame_Phoenix is offline   Reply With Quote
Old 05-08-2009, 02:28 PM   #49
Rising_Dusk
Obscurity, the Art


Projects Director
Project Leader: OD
 
Join Date: Feb 2006
Posts: 9,729

Submissions (27)

Rising_Dusk has a reputation beyond repute (1192)Rising_Dusk has a reputation beyond repute (1192)Rising_Dusk has a reputation beyond repute (1192)Rising_Dusk has a reputation beyond repute (1192)Rising_Dusk has a reputation beyond repute (1192)Rising_Dusk has a reputation beyond repute (1192)Rising_Dusk has a reputation beyond repute (1192)Rising_Dusk has a reputation beyond repute (1192)Rising_Dusk has a reputation beyond repute (1192)

Hero Contest #3 - 1st PlaceApproved Map: Desert of ExileApproved Map: Advent of the ZenithHero Contest #2 - 1st PlaceHero Contest - Third place>

Send a message via AIM to Rising_Dusk Send a message via MSN to Rising_Dusk
Default

Quote:
Originally Posted by moyack
what's wrong is to use such amount of libraries for a warning message. Do you want a Blizzard behavior? why not doing this?
So what if I order my Salamander to use Firebolt, a derivation of storm bolt, and then I issue it an order to cast Devour that has to be canceled? Now, instead of firebolting the unit, I 'smart' to it, which is wrong. Really, those two libraries would not be approved if they were useless, please stop being so disgruntled.
__________________

Last edited by Rising_Dusk : 05-08-2009 at 02:30 PM.
Rising_Dusk is offline   Reply With Quote
Old 05-08-2009, 02:38 PM   #50
Anitarf
Procrastination Incarnate


Development Director
 
Join Date: Feb 2004
Posts: 8,190

Submissions (19)

Anitarf has a brilliant future (903)Anitarf has a brilliant future (903)Anitarf has a brilliant future (903)Anitarf has a brilliant future (903)Anitarf has a brilliant future (903)Anitarf has a brilliant future (903)Anitarf has a brilliant future (903)Anitarf has a brilliant future (903)

2008 Spell olympics - Fire - SilverApproved Map: Old School Alliance TacticsHero Contest #2 - 3rd PlaceSpell making session 2 winner

Default

What I meant was that it'd be nice if you could calibrate how many units can a unit with Devour digest at the same time - so it could for example devour one unit and then before it has finished digesting it devour another one.

Quote:
Originally Posted by moyack
what's wrong is to use such amount of libraries for a warning message.
This isn't about a warning message, it's about the unit continuing to do what it was previously doing. Your code does not accomplish that.
__________________
Anitarf is offline   Reply With Quote
Old 05-08-2009, 10:58 PM   #51
Av3n
Roar!
 
Av3n's Avatar


Project Leader: TBR
Project Member: PoC
 
Join Date: May 2006
Posts: 1,854

Submissions (7)

Av3n is a jewel in the rough (240)Av3n is a jewel in the rough (240)Av3n is a jewel in the rough (240)Av3n is a jewel in the rough (240)Av3n is a jewel in the rough (240)

Hero #4 extra-official winner2008 Spell olympics - Fire - BronzeHero Contest #3 - 3rd Place

Default

So like X level = Y Units devoured Anitarf? If so I think I can work on that sometime today/tonight

-Av3n
__________________

Thanks to FatherTime for the sig
.:
Current ProjectsSubmissions
Power of CorruptionMy Terrain
The Black RoadMy Resources
Strikeforce
Twitter
Av3n is offline   Reply With Quote
Old 05-14-2009, 08:05 PM   #52
Rising_Dusk
Obscurity, the Art


Projects Director
Project Leader: OD
 
Join Date: Feb 2006
Posts: 9,729

Submissions (27)

Rising_Dusk has a reputation beyond repute (1192)Rising_Dusk has a reputation beyond repute (1192)Rising_Dusk has a reputation beyond repute (1192)Rising_Dusk has a reputation beyond repute (1192)Rising_Dusk has a reputation beyond repute (1192)Rising_Dusk has a reputation beyond repute (1192)Rising_Dusk has a reputation beyond repute (1192)Rising_Dusk has a reputation beyond repute (1192)Rising_Dusk has a reputation beyond repute (1192)

Hero Contest #3 - 1st PlaceApproved Map: Desert of ExileApproved Map: Advent of the ZenithHero Contest #2 - 1st PlaceHero Contest - Third place>

Send a message via AIM to Rising_Dusk Send a message via MSN to Rising_Dusk
Default

It has been a week. Are you planning on updating this or not?
__________________
Rising_Dusk is offline   Reply With Quote
Old 05-15-2009, 11:23 AM   #53
Av3n
Roar!
 
Av3n's Avatar


Project Leader: TBR
Project Member: PoC
 
Join Date: May 2006
Posts: 1,854

Submissions (7)

Av3n is a jewel in the rough (240)Av3n is a jewel in the rough (240)Av3n is a jewel in the rough (240)Av3n is a jewel in the rough (240)Av3n is a jewel in the rough (240)

Hero #4 extra-official winner2008 Spell olympics - Fire - BronzeHero Contest #3 - 3rd Place

Default

Yes I am since I've been a bit busy over the week, it coming out a bit slower than I thought.

-Av3n

EDIT:
Expand JASS:

That's my current code, the problem is however I ain't getting it to recycle the variables properly... If you the spell in quick succession it will bug.

So For Example. Hero Devours Unit A (Bar A is created) then Unit B (Bar B is created).
Unit A is devoured (Bar A is destroyed) Unit A is recycled to devour Unit C (Bar A is created).

The current testmap has this code, try bug it out, since it does bug out pretty easily

-Av3n
Attached Files
File Type: w3x Devour.w3x (57.5 KB, 7 views)
__________________

Thanks to FatherTime for the sig
.:
Current ProjectsSubmissions
Power of CorruptionMy Terrain
The Black RoadMy Resources
Strikeforce
Twitter
Av3n is offline   Reply With Quote
Old 06-15-2009, 12:23 PM   #54
Anitarf
Procrastination Incarnate


Development Director
 
Join Date: Feb 2004
Posts: 8,190

Submissions (19)

Anitarf has a brilliant future (903)Anitarf has a brilliant future (903)Anitarf has a brilliant future (903)Anitarf has a brilliant future (903)Anitarf has a brilliant future (903)Anitarf has a brilliant future (903)Anitarf has a brilliant future (903)Anitarf has a brilliant future (903)

2008 Spell olympics - Fire - SilverApproved Map: Old School Alliance TacticsHero Contest #2 - 3rd PlaceSpell making session 2 winner

Default

Meh, nevermind about multiple devoured units, the spell is good enough as it is. Just a few details:

There's no need for an effect local variable in .create, you could just destroy it as you create it. That way, you could also avoid the extra GetSpellTargetLoc calls since you could create it after you set a.targ.

It would be nice if the mana drain was calibrateable, rather than being hardcoded to equal the damage.

// How much damage is dealt roughly each second if you are using the default ExecutionRate value I guess this comment is outdated since the code works with any ExecutionRate.

You are missing the TTBar requirement in the library declaration.

The EffectExecutionRate could use a more intuitive calibration, something like a single value that determines how many times per second does the effect appear on average and then your condition in the code would look something like if GetRandomReal(0,1) < EffectExecutionRate*ExecutionRate then.
__________________
Anitarf is offline   Reply With Quote
Old 06-16-2009, 08:39 AM   #55
Av3n
Roar!
 
Av3n's Avatar


Project Leader: TBR
Project Member: PoC
 
Join Date: May 2006
Posts: 1,854

Submissions (7)

Av3n is a jewel in the rough (240)Av3n is a jewel in the rough (240)Av3n is a jewel in the rough (240)Av3n is a jewel in the rough (240)Av3n is a jewel in the rough (240)

Hero #4 extra-official winner2008 Spell olympics - Fire - BronzeHero Contest #3 - 3rd Place

Default

Updated.

Anything else that I foolishly missed out?

-Av3n
__________________

Thanks to FatherTime for the sig
.:
Current ProjectsSubmissions
Power of CorruptionMy Terrain
The Black RoadMy Resources
Strikeforce
Twitter
Av3n is offline   Reply With Quote
Old 06-16-2009, 10:12 AM   #56
Anitarf
Procrastination Incarnate


Development Director
 
Join Date: Feb 2004
Posts: 8,190

Submissions (19)

Anitarf has a brilliant future (903)Anitarf has a brilliant future (903)Anitarf has a brilliant future (903)Anitarf has a brilliant future (903)Anitarf has a brilliant future (903)Anitarf has a brilliant future (903)Anitarf has a brilliant future (903)Anitarf has a brilliant future (903)

2008 Spell olympics - Fire - SilverApproved Map: Old School Alliance TacticsHero Contest #2 - 3rd PlaceSpell making session 2 winner

Default

Very nice. Approved.
__________________
Anitarf is offline   Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off


All times are GMT. The time now is 10:25 PM.


Affiliates
The Hubb The JASS Vault Clan WEnW Campaign Creations Clan CBS GamesModding Flixreel Videos

Powered by vBulletin (Copyright ©2000 - 2020, Jelsoft Enterprises Ltd).
Hosted by www.OICcam.com
IT Support and Services provided by Executive IT Services