| 12-15-2010, 09:57 PM | #1 |
The native in question: SetUnitFlyHeight takes unit whichUnit, real newHeight, real Rate So I get the first two, but how the heck does Rate work? If it even works at all. I've tried two things so far: 1) I looked around and found out about some "Crow Form" trick that makes Rate work. Apparently, you're suppose give the ability and remove it from the unit, which then allows you to set the unit's height freely with a rate that would work. I tried this and now the dummy unit doesn't move at all whereas if I don't try this trick, the dummy unit moves to the new Z height instantly. 2) What exactly is Rate "measuring"? A unit of time, I'm assuming, but how is that working? It is the amount of time it takes for the unit to get to the new Z value? Is it how much the unit is going to move newHeight units in Rate seconds? They really should be more descriptive about this. Whether or not those two observations means anything eludes from the actual question I'm asking: How exactly do I get Rate to work? I need to move a dummy unit to a newHeight of zero because it starts a negative value of -400. I don't want it to move instantly though; it needs to rise from the surface smoothly. I could make timer or a loop to solely control this special effect, but really-- it'd be awesome to do that with only one line of code. EDIT: ... Do I have to do use waits...? Uugh... |
| 12-15-2010, 11:40 PM | #2 |
| 12-16-2010, 01:32 AM | #3 | |
Quote:
Hm... I think that should answer. Not sure. |
| 12-16-2010, 09:42 AM | #4 |
I've read, I think by Anitarf, that if rate == distance, it takes 1 second to get there. It's obviously unintuitive, though I suppose it has its perks. I always use 0.00 for that value because I value speed. |
| 12-16-2010, 04:34 PM | #5 |
Well, that's nice to know, but dumb at the same time. I guess I didn't use values high enough; I was doing single digits. I think I my alternative way is better, then... In another spell, I need control of certain points of the unit's Z, because the dummy unit starts at a height of 2000 and gradually slows down when it gets closer to the location's Z. However, for something as simple as moving a unit up and down as in the dummy unit at -400. height, this works. Thanks a lot, guys. |
