• 🏆 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!

MDL editing: BillboardedLockZ turns model 90° clockwise, why?

Status
Not open for further replies.
Level 4
Joined
Jun 19, 2010
Messages
49
Hi there!

I created a simple model in "GMAX 1.2". A plane which is slightly inclined like that:
150577d1448471917-mdl-editing-billboardedlockz-turns-model-90a-clockwise-why-_screenshot_gmax.png
To export the model from GMAX I use the script "DeX_0.186m.mcr". After MDL-editing (adding Textures, Materials & adjusting Bone) everything is fine (model looks downwards in Magos War3 Model Editor, world editor & in game). This is the MDL:
View attachment spiky3b.mdl
But when I add "BillboardedLockZ," to the Bone, the model looks leftwards in the world editor & in game (Magos still shows downwards in "(Unanimated)"). Here is the second model with the said change:
View attachment spiky3a.mdl
To convert the MDL to MDX I use "MDLX Converter 1.04" from Guesst & ProFeT.
To show the difference in a screenshot:
On the left is the second model ("spiky3a.mdl") & on the right is the first model ("spiky3b.mdl") when imported into world editor:
150578d1448471917-mdl-editing-billboardedlockz-turns-model-90a-clockwise-why-_screenshot_worldeditor-edit.png
What is the issue?
Why does "BillboardedLockZ" turn this model 90° clockwise in world editor & in game?
How can i fix it in the MDL (text-editing prefered)?

Please help & explain...



edit (2015_11_27):
following information was all i found after exploring the WWW for 1 day for everything interesting in connection with "BillboardedLockZ":
Born²Modificate said:
Give it the X-rotation -90,0. (This is needed for right billboarding)
source: post #1 from "Born²Modificate": http://www.wc3c.net/showthread.php?t=93945

Cookie said:
The rest are planes, just planes that are rotated and billboarded even with bones animation
source: post #4 from "Cookie": http://www.wc3c.net/showthread.php?t=19639

Rao Dao Zao said:
Add the line:
Billboarded,
To the bone. This will make it always face the camera
(unless you created the plane facing the wrong direction, in which case the side or something will always face the camera).
source: post #1 from "Rao Dao Zao": http://www.wc3c.net/showthread.php?t=74397

shadow1500 said:
You will have to use billboarded planes for the 2d image, there was a tutorial on how to do it, but it got deleted for some reason, ...
source: post #4 from "shadow1500": http://www.wc3c.net/showthread.php?t=87156



edit (2015_11_27, a little later :wink:):
I might have understood it now by myself after I PM-ed BlinkBoy & tried to describe the problem as accurately as possible. First thing I noticed was, that I never conciously realized that I rotate objects in Magos with every start by 90° to "correct" the coordinate system. I then asked myself why Magos used to show the coordinate system the way it is showing by default: X axis vertically, Y axis horizontically. Warcraft has X axis horizontically & Y axis vertically when using triggers like:
JASS:
native CreateUnit takes player id, integer unitid, real x, real y, real face returns unit
native SetCameraPosition takes real x, real y returns nothing
etc.
And then I finally came across a possible solution! In fact there were 2 questions:
1. Why does Magos show the X axis from a vertical perspective by default?
2. Why does Warcraft Editor show units facing to the east when you set their orientation to 0°?
And these two questions led me to a new assumption:
The MDL flag "BillboardedLockZ" locks the model to the camera in Warcraft editor & game by using a unit orientation of 270°!
Practical relevance for process of model creation in GMAX for models planned with "BillboardedLockZ":
The axis which faces to the camera is the positive X axis, so your model mustn't face to -Y (south), but +X (east)!
(Compare first screenshot for GMAX axis.)


degreedirection
east
90°north
180°west
270°south

Here are three final screenshots I catched for proof:

(Same coordinate system in magos & warcraft!) World editor showing original peasant unit (MDL has no "BilldboardedLockZ" by default):
150624d1448655654-mdl-editing-billboardedlockz-turns-model-90a-clockwise-why-coordinatesystem_magos-warcraft-2-no-billdboardedlockz-used-.png


(Same coordinate system in magos & warcraft!) World editor showing sorceress unit with model "spiky3b.mdl" (MDL has no "BilldboardedLockZ"!):
(Note: When the unit from this screenshot is orientated to 270°, it looks identical to the unit from the next screenshot with "BilldboardedLockZ".)
150622d1448655654-mdl-editing-billboardedlockz-turns-model-90a-clockwise-why-coordinatesystem_magos-warcraft-1a-no-billdboardedlockz-used-.png


(Same coordinate system in magos & warcraft!) World editor showing priest unit with model "spiky3a.mdl" (MDL with "BilldboardedLockZ"!):
150623d1448655654-mdl-editing-billboardedlockz-turns-model-90a-clockwise-why-coordinatesystem_magos-warcraft-1b-billdboardedlockz-used-.png


Can someone confirm this assumption to be true? BlinkBoy?
 

Attachments

  • _screenshot_GMAX.png
    _screenshot_GMAX.png
    96.7 KB · Views: 323
  • _screenshot_worldEditor edit.png
    _screenshot_worldEditor edit.png
    805.2 KB · Views: 210
  • coordinateSystem_magos=warcraft 1a (no BilldboardedLockZ used!).png
    coordinateSystem_magos=warcraft 1a (no BilldboardedLockZ used!).png
    1 MB · Views: 188
  • coordinateSystem_magos=warcraft 1b (with BilldboardedLockZ used!).png
    coordinateSystem_magos=warcraft 1b (with BilldboardedLockZ used!).png
    1 MB · Views: 180
  • coordinateSystem_magos=warcraft 2 (no BilldboardedLockZ used!).png
    coordinateSystem_magos=warcraft 2 (no BilldboardedLockZ used!).png
    1 MB · Views: 231
Last edited:
Status
Not open for further replies.
Top