• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

Bug with ordering flying units - isolated, but not fixed

Status
Not open for further replies.
Level 14
Joined
Aug 30, 2004
Messages
909
I've had this bug for years and finally isolated the problem. In short, ordering (via trigger) a flying unit to move will sometimes create a jittery flying pattern...like the animation is resetting every .1 seconds or something until it reaches its point. I've uploaded a map that illustrates the bug:

http://www.hiveworkshop.com/forums/pastebin_data/qwcj45/_files/Jitter bug.w3x

Here's are its only triggers. The map has 1 gryphon for player 1 in the center:

  • intialize
    • Events
      • Map initialization
    • Conditions
    • Actions
      • Camera - Pan camera for Player 1 (Red) to (Position of Gryphon Rider 0000 <gen>) over 0.00 seconds
      • Camera - Lock camera target for Player 1 (Red) to Gryphon Rider 0000 <gen>, offset by (0.00, 0.00) using Default rotation
      • Set Ship = Gryphon Rider 0000 <gen>
      • Game - Display to (All players) the text: Arrow keys order th...
      • Wait 2.00 game-time seconds
      • Game - Display to (All players) the text: BUG: Ordering it t...
  • West
    • Events
      • Player - Player 1 (Red) Presses the Left Arrow key
    • Conditions
    • Actions
      • Unit - Order Ship to Move To ((Position of Ship) offset by 500.00 towards 180.00 degrees)
  • East
    • Events
      • Player - Player 1 (Red) Presses the Right Arrow key
    • Conditions
    • Actions
      • Unit - Order Ship to Right-Click ((Position of Ship) offset by 500.00 towards 0.00 degrees)
  • North
    • Events
      • Player - Player 1 (Red) Presses the Up Arrow key
    • Conditions
    • Actions
      • Unit - Order Ship to Move To ((Position of Ship) offset by 500.00 towards 90.00 degrees)
  • South
    • Events
      • Player - Player 1 (Red) Presses the Down Arrow key
    • Conditions
    • Actions
      • Unit - Order Ship to Move To ((Position of Ship) offset by 500.00 towards 270.00 degrees)
Here is what happens:

If you press the up or down arrows, the gryphon moves north or south appropriately.

If you press the west arrow ONCE, the gryphon flies to the west.

If you press the west arrow TWICE the gryphon jitters and animates wrong.

Ordering the gryphon to go east or west more than once breaks the animation even though they go in the right direction. I know it doesn't have to be exactly 0 and 180 degrees (in my main map it's not), but it always breaks when ordered twice in those directions.

Here's a list of potential fixes that do NOT work:
- ordering unit to stop before new order to move.
- pausing and unpausing unit
- ordering unit to move to it's own location before new order to move.
- reseting unit's animation
- ignoring guard position
- switching models
- switching units
- changing unit max pitch and rotation


I'm having a hell of a time with this, and it really ruins parts of my map. Can anyone think of why this happens and how to fix it?
 
Level 29
Joined
Oct 24, 2012
Messages
6,543
u can get rid of this line since ur locking it to the unit in the next line.
  • Camera - Pan camera for Player 1 (Red) to (Position of Gryphon Rider 0000 <gen>) over 0.00 seconds
also note that u leaked in that line.

ur leaking two points in each of these.
  • Unit - Order Ship to Move To ((Position of Ship) offset by 500.00 towards 180.00 degrees)
u can try moving the unit manually but this will require custom scripts and a loop trigger and indexing and de-indexing the units.

u should look at the Things That Leak tutorial on here. also take a look at my tutorial Things a GUIer Should Know as it will help u with triggering.
 
Level 14
Joined
Aug 30, 2004
Messages
909
I'm not worried about leaks, this is a bug test.

I've got some more information. I don't think it's the animation (I tried the custom calls and it didn't work, I'm afraid).

It appears to have something to do with the Art - Maximum Roll Angle. When I change it to 0 it appears to go away (it looks like it might twitch a bit...it's hard to tell). Regardless, it's definitely related to this roll. I don't know how Max. Roll Angle works exactly... I thought it had something to do with terrain but it happens on perfectly flat terrain.

Again, this doesn't happen when you select the unit and right-click; only when you do it through triggers.

Could I get some more suggestions please? I can set the Max. Roll Angle = 0 for now, but it makes flying units look less cool.
 
Last edited:
Status
Not open for further replies.
Top