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 > Warcraft III Modding > Developer's Corner > Triggers & Scripts
User Name
Password
Register Rules Get Hosted! Chat Pastebin FAQ and Rules Members List Calendar



Reply
 
Thread Tools Search this Thread
Old 04-13-2010, 12:14 PM   #1
icarus
User
 
Join Date: Apr 2010
Posts: 5

icarus has little to show at this moment (0)

Default spell help

Can anyone help me create two spells I'm working on, I've got stuck.

The first one, I'm trying make the ability knock the target back away from the caster.

The second one, I'm trying to knock a target up into the air (I tried adjust flying height but it didn't do anything, I presume because it's not a flying unit).

Any help would be much appreciated.

Thanks in advance

Icarus
icarus is offline   Reply With Quote
Sponsored Links - Login to hide this ad!
Old 04-13-2010, 07:02 PM   #2
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

For the first spell, I recommend you take a look at Rising_Dusk's Knockback System; it should make the effect of your spell a simple matter of one function call.

For the second spell, the problem is indeed the fact that you are trying to do it on a ground unit. There is a workaround, though: the Warcraft III Ability Guide explains how (just search the tutorial for "Amrf").
__________________
Anitarf is offline   Reply With Quote
Old 04-13-2010, 09:38 PM   #3
BuRnInSpartan
User
 
BuRnInSpartan's Avatar
 
Join Date: Jan 2004
Posts: 1,077

BuRnInSpartan is on a distinguished road (21)

Default

so you basically wanna copy the dota spells? Spirit breakers knockback and tidehunter or sandking or demon witch spells that spike the unit upward?
__________________
Battle of the Earth (BotE) Progress Bars

Terrain: 0000000000
Units: 0000000000
Spells: 0000000000
Triggers: 0000000000
BuRnInSpartan is offline   Reply With Quote
Old 04-13-2010, 10:21 PM   #4
Ammorth
I blink, therefore I am.
 
Ammorth's Avatar
 
Join Date: Sep 2006
Posts: 1,812

Submissions (10)

Ammorth is a glorious beacon of light (461)Ammorth is a glorious beacon of light (461)Ammorth is a glorious beacon of light (461)Ammorth is a glorious beacon of light (461)

Default

Quote:
Originally Posted by BuRnInSpartan
so you basically wanna copy the dota spells? Spirit breakers knockback and tidehunter or sandking or demon witch spells that spike the unit upward?

More like, "so you basically wanna copy spells dota copied from the mapping community?"

Believe it or not, DotA was not the grand designer of everything wc3. Many of the ideas were taken from the community or from blizzard themselves (which isn't a bad thing).
__________________
Ammorth is offline   Reply With Quote
Old 04-14-2010, 02:03 AM   #5
BuRnInSpartan
User
 
BuRnInSpartan's Avatar
 
Join Date: Jan 2004
Posts: 1,077

BuRnInSpartan is on a distinguished road (21)

Default

either way... is that what you wanted?
__________________
Battle of the Earth (BotE) Progress Bars

Terrain: 0000000000
Units: 0000000000
Spells: 0000000000
Triggers: 0000000000
BuRnInSpartan is offline   Reply With Quote
Old 04-14-2010, 09:48 AM   #6
icarus
User
 
Join Date: Apr 2010
Posts: 5

icarus has little to show at this moment (0)

Default

no, in fact I'm doing a Naruto map, and the knockback is for Rasengan and the knock up thing is for Naruto Rendan and Shishi Rendan.

Never actually played DotA but I have heard that it's got some inventive abilities.

(and thanks Anitorf)

Icarus

EDIT: after reading the Knockback system... I've been working with GUI and I don't know JASS so I might have some problem converting the abilities to suit it, but I'll try.

Last edited by icarus : 04-14-2010 at 10:18 AM.
icarus is offline   Reply With Quote
Old 04-14-2010, 10:57 AM   #7
icarus
User
 
Join Date: Apr 2010
Posts: 5

icarus has little to show at this moment (0)

Default

ummm, does the Raven Form thing have to be done with JASS too? cos' I did the GUI equivalent and it doesn't work?

(Sorry about all this, I'm still very much a n00b when it comes to triggering)
icarus is offline   Reply With Quote
Old 04-14-2010, 12:41 PM   #8
Kueken
User
 
Join Date: Mar 2009
Posts: 149

Kueken will become famous soon enough (41)Kueken will become famous soon enough (41)

Default

You just need to add the ability raven form, remove it again and after this you can alter the flying heigth. Everything easily doable in Gui.
Kueken is offline   Reply With Quote
Old 04-14-2010, 04:19 PM   #9
Ammorth
I blink, therefore I am.
 
Ammorth's Avatar
 
Join Date: Sep 2006
Posts: 1,812

Submissions (10)

Ammorth is a glorious beacon of light (461)Ammorth is a glorious beacon of light (461)Ammorth is a glorious beacon of light (461)Ammorth is a glorious beacon of light (461)

Default

I believe the flight thing in GUI is under "Animations - Unit Flying Height" but a quick search would find it for you.

As Kueken said, you add the ability raven form ability (the one that morphs a medhiva to a crow) and remove it. The unit will not be a flying unit, but can now change its flying height.

The knockback system isn't too bad. Take a look at the test map and how it is used there. If after poking around you still can't figure it out, post here exactly what you don't know (providing examples is the best) and someone will help you.
__________________
Ammorth is offline   Reply With Quote
Old 04-14-2010, 04:54 PM   #10
icarus
User
 
Join Date: Apr 2010
Posts: 5

icarus has little to show at this moment (0)

Default

There is no raven form, I assume people mean crow form(which has the same order ID) but when I add and remove it, then set flying height, nothing happens.
icarus is offline   Reply With Quote
Old 04-14-2010, 05:34 PM   #11
Kueken
User
 
Join Date: Mar 2009
Posts: 149

Kueken will become famous soon enough (41)Kueken will become famous soon enough (41)

Default

Just tested it, it works as intended in Gui. Used trigger:
Trigger:
Unit - Add Crow Form to TempUnit
Unit - Remove Crow Form from TempUnit
Animation - Change TempUnit flying height to 256.00 at 0.00
and it flies.
Your problem lies elsewhere.

Last edited by Kueken : 04-14-2010 at 05:35 PM.
Kueken is offline   Reply With Quote
Old 04-14-2010, 05:40 PM   #12
icarus
User
 
Join Date: Apr 2010
Posts: 5

icarus has little to show at this moment (0)

Default

ok, thanks, I guess I'll have to try and fathom this myself
icarus is offline   Reply With Quote
Old 04-14-2010, 06:13 PM   #13
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

The only way for it not to work that I can think of is if you edited the crow form ability to morph into a non-flying unit (since that's the important part that makes this trick work, the ability has to morph the unit into a flying unit).
__________________
Anitarf is offline   Reply With Quote
Old 04-15-2010, 08:17 AM   #14
Kueken
User
 
Join Date: Mar 2009
Posts: 149

Kueken will become famous soon enough (41)Kueken will become famous soon enough (41)

Default

Or some sort of Ensnare/Entangle based abilities (sometimes they seem to be able to prevent unit fly height changes permanently)

Last edited by Kueken : 04-15-2010 at 08:18 AM.
Kueken is offline   Reply With Quote
Old 05-10-2010, 03:29 AM   #15
_too
User
 
Join Date: May 2010
Posts: 2

_too has little to show at this moment (0)

Default

I hope this is close enough. Untested ...but should work.
////////////////////////////////////////////
globals
gamecache GC=InitGameCache("GC.w3v")
endglobals
function h2i takes handle h returns integer
return h
return 0
endfunction
function i2u takes integer i returns unit
return i
return null
endfunction
function GetPolarX takes real x,real d,real a returns real
return x+d*Cos(a*3.14159/180)
endfunction
function GetPolarY takes real y,real d,real a returns real
return y+d*Sin(a*3.14159/180)
endfunction
function UnitTimedMove takes nothing returns nothing
local timer t=GetExpiredTimer()
local unit u=i2u(GetStoredInteger(GC,I2S(h2i(t)),"u"))
local real du=GetStoredReal(GC,I2S(h2i(t)),"du")
local real di=GetStoredReal(GC,I2S(h2i(t)),"di")
local real a=GetStoredReal(GC,I2S(h2i(t)),"a")
call SetUnitPosition(u,GetPolarX(GetUnitX(u),di,a),GetPolarY(GetUnitY(u),di,a))
call SetUnitFlyHeight(u,GetUnitFlyHeight(u)+10,1000)
if TimerGetElapsed(t)>=du then
call FlushStoredMission(GC,I2S(h2i(t)))
call DestroyTimer(t)
endif
set t=null
set u=null
endfunction
//call UnitAbilityBack(GetSpellTargetUnit(),Duration,Distance,Angle)
function UnitAbilityBack takes unit u,real du,real di,real a returns nothing
local timer t=CreateTimer()
call UnitAddAbility(u,'Amrf')
call UnitRemoveAbility(u,'Amrf')
call TimerStart(t,0.03,true,function UnitTimedMove)
call StoreInteger(GC,I2S(h2i(t)),"u",h2i(u))
call StoreReal(GC,I2S(h2i(t)),"du",du)
call StoreReal(GC,I2S(h2i(t)),"di",di/du*0.03)
call StoreReal(GC,I2S(h2i(t)),"a",a)
set t=null
endfunction
///////////////////////////

Last edited by _too : 05-12-2010 at 12:31 PM.
_too 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 02:32 PM.


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

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