• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.
  • The Hive's 22nd Icon Contest: Creep Abilities is now concluded, time to vote for your favourite set of icons! Click here to vote!
  • ✅ The POLL for Hive's Texturing Contest #34 is OPEN! Vote for the TOP 3 SKINS! 🔗Click here to cast your vote!
  • ✅ The POLL for Hive's Techtree Contest #20 is OPEN! Vote for the TOP 3 FACTIONS! 🔗Click here to cast your vote!

Help me! JAWS are eating me.

Status
Not open for further replies.
I need some help regarding angles. I never went to 3rd year class(at least not yet) so don't expect me to know about trigonometry (those Cos and Sin functions make no sense to me as to why they only take one argument when they compare stuff).

If an object, rather a ball, hit a wall, how would I know in which angle to send the ball to?
 
I know that u take the angle between the movement line of the ball and the line that makes 90° with the surface being hit, you then make the new trajectory line from that same line from the opposite side with the angle that u calculated, problem is that idk how u can get the angle of the surface where the ball hits in Warcraft
 
Untitled.jpg

so as you can see, u will need to calculate the angle between the line perpendicular to the region or border, and the trajectory line of the ball, then do the opposite of it compared to the perpendicular line

#paint :3
 
Jad's right, adding 180 to the trajectory angle would make the balls go in the opposite direction.

Code:
0------> HERO
<------0 HERO
 
I need help. This always returns false even though the DebugMsg exactly above it says that FC_Name is "Trueshot". SO WHAT THE HELL.

  • Custom script: call BJDebugMsg(udg_FC_Name[udg_A])
  • Custom script: if udg_FC_Name[udg_A] == "Trueshot" then
  • Custom script: set udg_TempUnit = ClosestOfGroupLoc(udg_TempGroup, udg_TempPoints[1])
  • Set TempPoints[2] = (Position of TempUnit)
  • Set TempPoints[3] = (TempPoints[1] offset by (Distance between TempPoints[1] and TempPoints[2]) towards FC_Angle[A] degrees)
  • Set TempReals[2] = (1.00 + (((Distance between TempPoints[2] and TempPoints[3]) x 0.25) x 0.01))
  • Set TempReals[3] = ((FC_Damage[A] x (((FC_Distance[A] x 0.03) x 0.01) + 1.00)) x TempReals[2])
  • Custom script: call BJDebugMsg(R2S(udg_TempReals[3]))
  • Set DamageEventType = 2
  • Set DamageType = 8
  • Unit - Cause FC_Caster[A] to damage TempUnit, dealing TempReals[3] damage of attack type Chaos and damage type Universal
  • Custom script: call RemoveLocation(udg_TempPoints[2])
  • Custom script: call RemoveLocation(udg_TempPoints[3])
  • Custom script: endif
Then even if I remove the 'if' block it still doesn't work for no reason:
  • Custom script: set udg_TempUnit = ClosestOfGroupLoc(udg_TempGroup, udg_TempPoints[1])
  • Set TempPoints[2] = (Position of TempUnit)
  • Set TempPoints[3] = (TempPoints[1] offset by (Distance between TempPoints[1] and TempPoints[2]) towards FC_Angle[A] degrees)
  • Set TempReals[2] = (1.00 + (((Distance between TempPoints[2] and TempPoints[3]) x 0.25) x 0.01))
  • Set TempReals[3] = ((FC_Damage[A] x (((FC_Distance[A] x 0.03) x 0.01) + 1.00)) x TempReals[2])
  • Custom script: call BJDebugMsg(R2S(udg_TempReals[3]))
  • Set DamageEventType = 2
  • Set DamageType = 8
  • Unit - Cause FC_Caster[A] to damage TempUnit, dealing TempReals[3] damage of attack type Chaos and damage type Universal
  • Custom script: call RemoveLocation(udg_TempPoints[2])
  • Custom script: call RemoveLocation(udg_TempPoints[3])
 
That's a lot of work, you could either, set the facing angle as the bouncing plane or calculate it using something I don't know, let Jad explain it lol haha XD.
 
====================

Okay guys my mind is burning out. I did something similar in the past, but it did not include this crap I'm in. >.<

So... here's what I'm trying to do. Every three attacks, the hero applies a non stacking mark on the target. Abilities from the hero can detonate the mark. Mark lasts for 4 seconds. (This duration is why I need a countdown index)

Mark detonation is done with the Damage Mod. My problem is the mark application.

So can anyone give me an outline of how to do this? Like example GUI trigs. (Yes, GUI. I feel more comfortable reading GUI than JASS (and JASS scripts need to exist before the caller func unlike libs), and vJASS is useful but not his time.)
 
Damn Pali! Be more sensitive damnit! /kidding
What happened to Malhorne? He's busy as "fuck" lolololol
 
Egg cells... I dunno if you could get them normally without medical tools, I mean they come out as menstrual secretions but I don't think it would be pleasant...
 
Yeah haha XD I didn't know you were "that" mature already buddy lol. [not an insult okay lololol]. "Moderation is key", that's what my dad used to say.
 
Needs Fix, does not work on multiple items of the same type.

  • Item Recipe System
    • Events
      • Unit - A unit Acquires an item
    • Conditions
    • Actions
      • For each (Integer TempIndex) from 1 to RecipeMax, do (Actions)
        • Loop - Actions
          • Set X = 0
          • Set RecipeTempItems[1] = RecipeItem1[TempIndex]
          • Set RecipeTempItems[2] = RecipeItem2[TempIndex]
          • Set RecipeTempItems[3] = RecipeItem3[TempIndex]
          • Set RecipeTempItems[4] = RecipeItem4[TempIndex]
          • Set RecipeTempItems[5] = RecipeItem5[TempIndex]
          • For each (Integer TempInteger) from 1 to RecipeNumberOfItems[TempIndex], do (Actions)
            • Loop - Actions
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • ((Triggering unit) has an item of type RecipeTempItems[TempInteger]) Equal to True
                • Then - Actions
                  • Set X = (X + 1)
                • Else - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • X Equal to RecipeNumberOfItems[TempIndex]
            • Then - Actions
              • Item - Remove (Item carried by (Triggering unit) of type RecipeItem1[TempIndex])
              • Item - Remove (Item carried by (Triggering unit) of type RecipeItem2[TempIndex])
              • Item - Remove (Item carried by (Triggering unit) of type RecipeItem3[TempIndex])
              • Item - Remove (Item carried by (Triggering unit) of type RecipeItem4[TempIndex])
              • Item - Remove (Item carried by (Triggering unit) of type RecipeItem5[TempIndex])
              • Hero - Create RecipeResult[TempIndex] and give it to (Triggering unit)
              • Special Effect - Create a special effect attached to the origin of (Triggering unit) using Abilities\Spells\Items\AIem\AIemTarget.mdl
              • Special Effect - Destroy (Last created special effect)
            • Else - Actions
 
  • Recipe Setup
    • Events
      • Map initialization
    • Conditions
    • Actions
      • -------- Arkenstone --------
      • Set RecipeMax = (RecipeMax + 1)
      • Set RecipeItem1[RecipeMax] = Value
      • Set RecipeItem2[RecipeMax] = Value
      • Set RecipeItem3[RecipeMax] = Value
      • Set RecipeItem4[RecipeMax] = Value
      • Set RecipeNumberOfItems[RecipeMax] = 4
      • Set RecipeResult[RecipeMax] = Value
 
Status
Not open for further replies.
Back
Top