- Joined
- Jun 1, 2009
- Messages
- 87
Hi so i just got new Gen cause i wana try some JASS spells but i cant seem to get the import right, when i imported the spell and followed directions new gen is telling me there is 15 compiled errors and wont let me test the map.
I have double and tripple checked my ID number and it all matches, i have checked the spell order ID as well and its set to "clusterrockets" like the spell said.
This is just the first part of error
new gen says
Line 17609: undecleared Function GetHandled unit
and its hightlightning this line
"local unit cast= GetHandleUnit(t , "cast")"
Line 17910: Undeclared function GetHandleReal
"local real angle= GetHandleReal(t , "angle")"
and jsut continues down the page. I got the spell off Hive, "wave Spell" and i am pretty sure it works fine since it works before i imported....
Here is what my import looks like
Pls help thx + rep if anyone can teach me how to import Jass and or guide me to a tutorial on it.
I have double and tripple checked my ID number and it all matches, i have checked the spell order ID as well and its set to "clusterrockets" like the spell said.
This is just the first part of error
new gen says
Line 17609: undecleared Function GetHandled unit
and its hightlightning this line
"local unit cast= GetHandleUnit(t , "cast")"
Line 17910: Undeclared function GetHandleReal
"local real angle= GetHandleReal(t , "angle")"
and jsut continues down the page. I got the spell off Hive, "wave Spell" and i am pretty sure it works fine since it works before i imported....
JASS:
function Dragon_Roar takes nothing returns nothing
local timer t= GetExpiredTimer()
local unit cast= GetHandleUnit(t , "cast")
local real angle= GetHandleReal(t , "angle")
local real z= GetHandleReal(t , "z")
local real x1= GetHandleReal(t , "x1")
Here is what my import looks like
JASS:
//===============================Dragon Roar By BlackShogun==============================//
//=========================================Setup=========================================//
//Note: to edit the spells DAMAGE, change the damage parameter in the DRAGON ROAR DUMMY spell
//change this to the raw code of your trigger spell
constant function DragonRoarCode takes nothing returns integer
return 'A043'
endfunction
//change this to the raw code of your dummy caster
constant function DragonRoarDummy takes nothing returns integer
return 'h03W'
endfunction
//change this to the raw code of your dummy spell (the spell that will be repeated to create the wave)
constant function DragonRoarRawCode takes nothing returns integer
return 'A042'
endfunction
//change this to the order id of your dummy spell (the spell that will be repeated to create the wave)
constant function DragonRoarID takes nothing returns string
return "clusterrockets"
endfunction
//change this to edit the number of parts to the wave
function DragonRoarRepeats takes real lvl returns real
return 4+(2*lvl)
endfunction
//change this to edit the distance between each part of the wave
constant function DragonRoarDistance takes nothing returns real
return 100.0
endfunction
//change this to edit the time between each part of the wave
constant function DragonRoarInterval takes nothing returns real
return 0.25
endfunction
//change this to edit the caster dummies lifespan (recommended 3.0)
constant function DragonRoarDummySpan takes nothing returns real
return 3.0
endfunction
//======================================End Setup=======================================//
//Note: Changing anything beyond here may stop the trigger from functioning and should be left alone
function Trig_Dragon_Roar_Conditions takes nothing returns boolean
return GetSpellAbilityId() == DragonRoarCode()
endfunction
function Dragon_Roar takes nothing returns nothing
local timer t = GetExpiredTimer()
local unit cast = GetHandleUnit(t, "cast")
local real angle = GetHandleReal(t, "angle")
local real z = GetHandleReal(t, "z")
local real x1 = GetHandleReal(t, "x1")
local real y1 = GetHandleReal(t, "y1")
local integer lvl = GetUnitAbilityLevel(cast, DragonRoarCode())
local player p = GetOwningPlayer(cast)
local real mx = DragonRoarDistance() * Cos(angle * 0.01745)
local real my = DragonRoarDistance() * Sin(angle * 0.01745)
local unit u
if z<DragonRoarRepeats(lvl) then
set z = z+1
call SetHandleReal(t, "z", z)
set u = CreateUnit(p, DragonRoarDummy(), x1, y1, angle)
call SetUnitAbilityLevel(u, DragonRoarRawCode(), lvl)
call IssuePointOrder(u, DragonRoarID(), (x1 + (mx * z)), (y1 + (my * z)))
call UnitApplyTimedLife(u, 'BTLF', DragonRoarDummySpan())
else
call FlushHandleLocals(t)
call PauseTimer(t)
call DestroyTimer(t)
set t = null
endif
set cast = null
set p = null
set u = null
endfunction
function Trig_Dragon_Roar_Actions takes nothing returns nothing
local timer t = CreateTimer()
local unit cast = GetTriggerUnit()
local location targ = GetSpellTargetLoc()
local real x1 = GetUnitX(cast)
local real y1 = GetUnitY(cast)
local real x2 = GetLocationX(targ)
local real y2 = GetLocationY(targ)
local real angle = 57.29583 * Atan2(y2-y1, x2-x1)
call SetHandleHandle(t, "cast", cast)
call SetHandleReal(t, "angle", angle)
call SetHandleReal(t, "x1", x1)
call SetHandleReal(t, "y1", y1)
call TimerStart(t, DragonRoarInterval(), true, function Dragon_Roar)
set t = null
call RemoveLocation(targ)
set targ = null
set cast = null
endfunction
//===========================================================================
function InitTrig_Dragon_Roar takes nothing returns nothing
set gg_trg_Dragon_Roar = CreateTrigger( )
call TriggerRegisterAnyUnitEventBJ( gg_trg_Dragon_Roar, EVENT_PLAYER_UNIT_SPELL_EFFECT )
call TriggerAddCondition( gg_trg_Dragon_Roar, Condition( function Trig_Dragon_Roar_Conditions ) )
call TriggerAddAction( gg_trg_Dragon_Roar, function Trig_Dragon_Roar_Actions )
endfunction
Pls help thx + rep if anyone can teach me how to import Jass and or guide me to a tutorial on it.