HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

script question... boats...

11-09-2002, 03:49 PM#1
Guest
Hi.... I've been watching this forum for a while, and am really impressed what some people have been able to figure out. I've finally given up hope that anyone is going to ask my question for me, so here goes:

Okay... I want boats... but I can't seem to make them work the way I want. I'm not really satisfied with the shallow water trick, so I thought I'd see if I could use slow-moving, slow turning, super-low-flying boats, which looks better in my opinion.

In order to reign-in my boats to keep them from becoming landships, I thought maybe I could use triggers or scripts to stop them when the reach a certain z-value, until they have turned so that they are on a negative incline.

My script works fine when I feed it artificial z-values, and with some setFlyHeight help it actually looks halfway decent even with uneven ocean floors.

The problem is, I can't find any way to access the height of point the unit is flying over and the point just ahead of that to determine the altitude and slope. I looked through the main APIs that I could find in war3.mpq, but I didn't see any equivelent of GetLocationZ. Maybe it's to be expected since z-values don't seem to be a part of the location data type, but am I wrong to think that there has to be some sort of way to do this? I had some hope for getrectheight, but that deals with y-axis length, I think... Is it part of the game-code? Then how do they determine altitude-based advantage for ranged units? They do that somehow, right?

I could use regions, but that seems like a somewhat ungraceful solution, and I want something that offers me more flexibility when it comes to inserting it into other maps. Also, that doesn't solve the magical bobbing boat problem when the ocean floor is uneven. I could edit pathing, except that that creates other weirdness, and is pretty hard to pull off on a macintosh...

Anybody have any ideas? I just want boats without the weirdness... do I have to wait for the inevitable boats in the expansion pack?
11-09-2002, 06:28 PM#2
ChronOmega
maybe you should post ur triggers...