Recent content by hgkjfhfdsj

  1. H

    Dummy Spell damage

    2 ways i know of 1) trigger the projectile movement 2) order a new dummy(new or recycled) to cast projectile spell, detect when spell event fires > condition trigger unit = dummy, then retrieve data (original caster, damage etc) either through hashtable or array.
  2. H

    Bounce math

    var r = 2*wallAngle - this.getVelAngle(); r *= Math.PI/180; // convert angle to radians // ... var v = this.getVelMagnitude(); //... - is it me, or is ur equation slightly different to the source? xD how did u get that equation? - how do u get the angle of wall?? direction from...
  3. H

    A type does not allow...? Getting a syntax error with a struct

    data struct is not declared when u put the global before the struct similar to these scenarios local integer a = b*2 // undeclared b variable local integer b // ==== or ==== function a takes nothing returns nothing call b() //undeclared function b endfunction function b takes nothing...
  4. H

    A type does not allow...? Getting a syntax error with a struct

    only changed the destructable variable? u dont have a referencable 'd' in that function. either change d to > D (u did set D = d in ur treecheck) then add D into global block (or if u want, into 'data' as a static field) or add local data d = D to save u from changing the d to D in the whole...
  5. H

    Bounce math

    im having trouble with the maths behind bouncing projectiles. my code so far: function Data_bounce takes integer this returns nothing local real a = RAbsBJ(udg_angle[this]*bj_RADTODEG) if 2*a< 90 or 2*(180-a) < 90 then set a = udg_angle[this] if a> 0 then...
  6. H

    A type does not allow...? Getting a syntax error with a struct

    i think u meant D.newx = GetUnitX(D.caster) and same with the rest in the same function d is ur local destructable variable D is ur global data struct (i dont think u declared it yet)
  7. H

    Critique/Errors. Please.

    //consider using initializer scope VampiricStrike initializer Init //.. private function Init takes nothing returns nothing local trig... endfunction //.. or make inittrig public public function InitTrig takes nothing returns nothing local trig.. endfunction
  8. H

    Triggered Movement

    it might be b/c ur hashtable SurgeUnitGroupHash doesnt have an initialized group saved to it. put something like this in the spell effect event trigger. Custom Script: set LoadGroupHandle(udg_SurgeUnitGroupHash, udg_TempHandle, 1) = CreateGroup() then later destroying it when movement is over...
  9. H

    Leash system, not detecting range?

    >function ifiselse compares getenumunit with null unit's position //showing you on your code since you might be more familiar with it.. private function IfIsElse takes nothing returns nothing local real X = GetUnitX(GetEnumUnit()) local real Y = GetUnitY(GetEnumUnit()) local real dx...
  10. H

    Leash system, not detecting range?

    >What is running Leashocity? i think how this system is used is actually by calling Leashocity() in a starts effect Event. eg Event A Unit Starts the Effect of an Ability -- Action call Leashocity()
  11. H

    Summons System, Multiple Ability Levels?

    >Im not sure what you mean about [1*HIGHESTLEVEL+LEVEL]?' set SummonAbility[1] = 'AHfs' // 3 levels for this spell set Unit_Id[1 * 4 + 1] = 'hfoo' // level 1 unit set Unit_Id[1 * 4 + 2] = 'hfop' // level 2 unit set Unit_Id[1 * 4 + 3] = 'hfpp' // level 3 unit set SummonAbility[2] = 'AHfs' // 4...
  12. H

    Summons System, Multiple Ability Levels?

    >have one level to work you can try a 3d array eg SummonAbility[1] Unit_Id[1*HIGHESTLEVEL+LEVEL] then set u = CreateUnit(p, Unit_Id[i * HIGHESTLEVEL + GetUnitLevelAbility(...)], xp, yp, 270) also function InitTrig_Summons_System takes nothing returns nothing set gg_trg_Summons_System =...
  13. H

    Leash system, not detecting range?

    - no timer expire action is attached eg. call TimerStart(CreateTimer(), 0.03, true, function ForFun) or TriggerAddAction(...) - GetTriggerUnit() returns nulls > function IfIsElse compares LeashedUnit and null's position. - also unit will always travel south westly and not towards the caster
  14. H

    Buff won't apply twice?

    mind posting sample map? much easier to debug
Top