Random missiles and fighters, please help!

More
18 years 7 months ago #15089 by Shane

oops, it seems I spoke to soon.

It's happened to all of us... especially on this particular problem. I, myself, thought I'd fixed it no less than five times. ;)

Let me know if you need some help debugging this. I might not know C++ that well but I do have a friend that does.

There's really nothing you can do with it... the script does attempt to remove the AI pilot before placing the Player pilot into the craft. That's about all we can do. The problem (as listed in the topic link above) seems to be hidden deep within the engine.

I don't think this one can be fixed without the source code (possibly not even with the source code... I find it hard to believe we would be able to correct something which Flux's designers could not).

I'd say your best bet is to try to align the weapons on the Z+ axis and see if the problem persists. It's not the most elegant solution, but the only one which we have the tools for.

Please Log in or Create an account to join the conversation.

More
18 years 7 months ago #15096 by gwzero
I did some more testing after I aligned all the weapons, and I came across some things that seem a little strange to me. First, the problem is somewhere in the source code like you thought, I tested that by turning off the mods and using the dev cmds to remote link to a ship. But somehow the designers found a way around it cuz I am unable to reproduce this with the standard ships. so I've been proding around the files, trying to find the major difference. Secondly, I must be getting close to a solution, I can now jump to the first ship in my list without any problems. However, I still can not remote link to another ship or jump to the other ships in my list without problems. All I've changed so far is align the 2 main dockports and setup a shield nullpoint (which might not be setup right). Could it be that I need to put Z+OrientationArrows and Y+OrientationArrows on all the cargoport nulls?

Oh and do these shield nulls look right to you guys?

AddNullObject front_shield
ShowObject 7 7
ObjectMotion (unnamed)
9
1
0 139 -166 0 -90 0 1 1 1
0 0 0 0 0
EndBehavior 1
LockedChannels 41
ShadowOptions 7

AddNullObject lower_shield
ShowObject 7 7
ObjectMotion (unnamed)
9
1
0 -90 -166 0 90 0 1 1 1
0 0 0 0 0
EndBehavior 1
LockedChannels 40
ShadowOptions 7

<hr noshade size="1">Smith - "12 assault cannon turrets, 15 quadpack launchers, 6 antimatter pbc's, and 30+ fighters in 6 bays, all mounted on a megafreighter."

Cal - "Ya think that'll be enough? I mean we're just going to the store."

Smith - "You know you're right, I better add on some more antimatter pbc's."

<hr noshade size="1">Smith - "12 docking turrets, 15 quadpack launchers, 6 antimatter pbc's, and 2 turret fighters, all mounted on a megafreighter."

Cal - "Ya think that'll be enough? I mean we're just going to the store."

Smith - "You know you're right, I'd better mount on some antimatter streams."

Please Log in or Create an account to join the conversation.

More
18 years 7 months ago #15105 by Shane
There is some confusion on the purpose of the Z+Dock Orientation Arrow. Quite understandable if the modder is not familiar with Lightwave or other modeling/animation programs.

A null doesn't really exist. It can be considered an imaginary reference point in space. They are used to mark a location in 3D space or to control animation.

You can give a null a name (such as pbc_cannon or peanut_butter_phantom or anything else you'd like). You can move them around, rotate them, and even shrink or grow them. Below is a picture of a null.



3D space has coordinates. Typically, +Y is considered “up�. -Y is considered “down�. +X and -X are considered “left� and “right� respectively. +Z is forward. -Z is behind.



Not only do nulls have a position (in the X, Y, Z world coordinates), they also have an orientation (Heading, Pitch, Bearing). The orientation tells us how they're rotated within the 3D world.



But, because a null is represented in LW as a 6-point cross, it can get hard to visually tell which way the null is oriented. So Particle Systems created a simple marker which, when parented (attached) to the null, would give a clear visual determination of where the null is pointed. This marker can only be seen in Lightwave and it does nothing in Flux... it's only purpose is to allow the modeler to see what direction a null is pointing in.

Here is a picture of the same null with the Z+ Dock Orientation Arrow object parented to it. When parented to the null, the arrow always points towards the null's +z axis. Now, no matter how we rotate the null, we can tell where it's pointing. The big arrow will move with it.



If you lack Lightwave, orienting nulls is very tedious... and inserting a Z+ Dock Orientation Arrow doesn't really do anything. Flux will just skip over the item.

Please Log in or Create an account to join the conversation.

More
18 years 7 months ago #15106 by gwzero
see I'm new to lightwave and I still dont quite understand what the z rotational value actually does. I know that x axis is the side to side rotation and y axis is the up and down rotation, but I dont really understand the purpose for the z axis. But if I understand You correctly, you're saying that the Z+DockOrientationArrow is meant to point in the direction that the weapon will face and fire? So then what does the Y+DockOrientationArrow do? From what I've seen with the corvette it seems that you need both to properly align a null.

<hr noshade size="1">Smith - "12 assault cannon turrets, 15 quadpack launchers, 6 antimatter pbc's, and 30+ fighters in 6 bays, all mounted on a megafreighter."

Cal - "Ya think that'll be enough? I mean we're just going to the store."

Smith - "You know you're right, I better add on some more antimatter pbc's."

<hr noshade size="1">Smith - "12 docking turrets, 15 quadpack launchers, 6 antimatter pbc's, and 2 turret fighters, all mounted on a megafreighter."

Cal - "Ya think that'll be enough? I mean we're just going to the store."

Smith - "You know you're right, I'd better mount on some antimatter streams."

Please Log in or Create an account to join the conversation.

More
18 years 7 months ago #15107 by GrandpaTrout
You need a clean test case. It is easy to be misled into thinking you fixed an issue, if your test case sometimes works/sometimes fails. You need a test case that always fails, so you know when it works, you have really fixed the issue.

So I would spend some time putting together a test case that is reliable. Figure out which ship to use for testing. How to jump into the ship. The exact steps needed to make it fail. Then try it a whole bunch of times to make sure it is consistant.

Only after your test case is reliable, then start making changes. And I would start with the very simplest test case that still fails. Something with very few dockports that are quick to change. Then you can try many ideas for fixes very fast. Make a new folder for tried test cases. Put a comment at the top of each INI file explaining what you were testing and how you plan to do it. Then you can always go back and see what you have done and your memory won't fool you.

It sounds like a lot of work, but it is actually much faster trying things that later prove to not work.

Please Log in or Create an account to join the conversation.

More
18 years 7 months ago #15110 by Shane
I agree completely with everything GrandpaTrout said... especially when dealing with a bug this insideous. This one has stymied the best of us... coders, modelers, and jack-of-all-trades. Take it in small, well-documented steps.

Having no experience with 3D modeling makes it even tougher. I too entered EoC modding this way, and it's one hell of a learning curve. But just keep plugging away and one day it'll all start falling into place.

Here's a quick down-and-dirty primer on 3D modeling. (But I highly recommend googling a real 3D primer to get the basics of X,Y,Z coordinates and Heading, Pitch, Bearing orientations.)

You're dealing with a 'model coordinate system'. All this basically means is that:

+Z = the front of the ship.
-Z = the back of the ship.
+X = the right side of the ship (when in the pilot's seat).
-X = the left of the ship.
+Y = above the ship.
-Y = below the ship.



In the picture above, you can see the grid shows the z axis and x axis. The y axis is there too, but not displayed since that would get in the way of the modeling. The y axis is top and bottom.



So, if you orient (point) a cannon along the +Z axis, all you're really doing is pointing it towards the front of the ship.

In Flux, according to the SDK literature, weapons (cannons, beam projectors, and missile magazines) are always supposed to be aligned to point towards the Z+ axis.

But if I understand You correctly, you're saying that the Z+DockOrientationArrow is meant to point in the direction that the weapon will face and fire?


No. The Z+Dock Orientation Arrow does one thing and one thing only; when parented to a null in Lightwave, the arrow points towards the null's +z axis. That's it. It only exists so the modeler won't screw up and point the null the wrong way.

So then what does the Y+DockOrientationArrow do?

While weapons are always supposed to be pointed towards the +Z axis (forward), dockports are different... they should, in most cases, always be pointed towards the Y+ axis. The Y+Dock Orientation Arrow, when parented to a null in Lightwave, will point towards the null's +Y axis.

If you do not have Lightwave version 5.6, the Z+Dock and Y+Dock Orientation arrows are completely useless to you. Trust me on this...Ignore them entirely. They do nothing except help the modeler know what's going on in Lightwave.

Check out the silly cannon I made for the container carrier. :D



This cannon's Heading, Pitch, and Bearing is 0, 0, 0. It is oriented on the +Z axis (points towards the front of the ship). But let's change that and see what happens...



This cannon's Heading is now set at 90 degrees. The Pitch and Bearing are still at zero. (So, in the Lightwave scene, you'd see 90, 0, 0). As you can see, changing the heading points the cannon away from the +Z axis (it is now firing on the +X axis). Flux won't like this and is apt to give us problems.



This time we've altered the cannon's pitch to 90 degrees. Heading and Bearing is zero. So the Lightwave scene will reflect 0, 90, 0. As you can see, this makes the cannon point downwards. The cannon is now aligned on the -Y axis. And again, Flux might have a problem with this.

This should be enough to get you started, but find a primer on 3D modeling. It will really help.

Cheers!

Please Log in or Create an account to join the conversation.