Jump to content
Tankbuster

setpos'ing the liberty and its turrets

Recommended Posts

Guys,

After much fumbling, I found the undocumented destroyer01posupdate function and have managed to get a decent dynamic spawn so the thing is just off the coast where my players start.

 

The ship is created in 3den and then moved using this function, but the mk45 and the VLS system that I carefully placed on deck don't move with it. Do I have to work out the offsets and attachto them to the ship? If so, will the MK45 still work as an artillery provider?

Share this post


Link to post
Share on other sites

If you have the offsets, you could setPos them after the ship is in its final position, no need for attachTo.

Share this post


Link to post
Share on other sites

I did an attachto as the first try and it worked but the mk45 barrel was spazzing out, apparently at random. Not actually tried to get it to send some rounds yet

Share this post


Link to post
Share on other sites

Use modelToWorld instead. You'll have to update it after you call the "destroyer01posupdate" function though. It may take a bit of tweaking at first to get the right positioning, etc but after that. It will always work, regardless of position or rotation.

  • Like 2

Share this post


Link to post
Share on other sites

Yes, that works a treat, thanks Harry.

  • Haha 2

Share this post


Link to post
Share on other sites

DO NOT CALL ME HARRY! Now everyone knows! God damn it, Paul. :rofl:

  • Like 1
  • Haha 2

Share this post


Link to post
Share on other sites
2 hours ago, Tankbuster said:

Sorry. Harriet :don11:

 

I 'm sure that this joke can go forever !

Share this post


Link to post
Share on other sites

As for Paulette! :rofl::rofl:

Anyway. Thread solved.

2 hours ago, Tankbuster said:

Yes, that works a treat

 

  • Haha 1

Share this post


Link to post
Share on other sites

there are some issues with turrets on ships ...

 

if you attach the turret to the ship object, you will have simulation issues with the turret (the child object inherits the simulation properties of the parent object).

 

if you dont attach the turret to anything, its own recoil can destabilize it and even knock itself off the ship (or just out of position).

 

the solution is to use a game logic, and attach the turret to the game logic

  • Like 5

Share this post


Link to post
Share on other sites
10 hours ago, GEORGE FLOROS GR said:

 

I 'm sure that this joke can go forever !

Yes, Georgina. :)

  • Haha 2

Share this post


Link to post
Share on other sites
2 hours ago, fn_Quiksilver said:

there are some issues with turrets on ships ...

 

if you attach the turret to the ship object, you will have simulation issues with the turret (the child object inherits the simulation properties of the parent object).

 

if you dont attach the turret to anything, its own recoil can destabilize it and even knock itself off the ship (or just out of position).

 

the solution is to use a game logic, and attach the turret to the game logic

This is interesting. So far, I've not seen recoil dislodge the Hammer, but will definitely keep an eye

  • Like 1

Share this post


Link to post
Share on other sites

Offsets for my placement of turrets, if anyone is interested. Use with modelToWorld as suggested by @HazJ

Note that relative zero direction for the destroyer is towards the stern of the ship, not the bow, so if you set the direction of the Hammer to the same as the ship, it will face the other way, not as seen below.

 

0428B3F03253D299C7C5FA9517F0C041077B462D

 

Mk45 Hammer. [-0.0175781,-78.95,11.9841]

 

Mk41 VLS [0.000976563,-62.2217,0.62267]

 

Praetorian 1C [-0.180664,-48.1677,1.86881]

 

6BEAFB5F38C0D205D6D07541E58EBCEAFC3FDF31

 

Starboard Praetorian [-9.62402,9.52246,0.50216]

 

Port Praetorian [9.69238,9.31494,0.622216]

 

Mk21 Centurian [0.0341797,35.4907,0.433431]

 

Mk49 Spartan [-0.0546875,50.6006,0.433254]

 

 

 

  • Like 3

Share this post


Link to post
Share on other sites

What kind of ship would you say the liberty destroyer is based on?

Share this post


Link to post
Share on other sites
33 minutes ago, beebah said:

What kind of ship would you say the liberty destroyer is based on?

 

It seems to be a mash-up of the capabilities of a Burke-class destroyer and the aesthetic of a Freedom-class littoral combat ship.

Share this post


Link to post
Share on other sites
On 9/10/2018 at 9:54 PM, Tankbuster said:

Offsets for my placement of turrets, if anyone is interested. Use with modelToWorld as suggested by @HazJ

Note that relative zero direction for the destroyer is towards the stern of the ship, not the bow, so if you set the direction of the Hammer to the same as the ship, it will face the other way, not as seen below.

 

0428B3F03253D299C7C5FA9517F0C041077B462D

 

Mk45 Hammer. [-0.0175781,-78.95,11.9841]

 

Mk41 VLS [0.000976563,-62.2217,0.62267]

 

Praetorian 1C [-0.180664,-48.1677,1.86881]

 

6BEAFB5F38C0D205D6D07541E58EBCEAFC3FDF31

 

Starboard Praetorian [-9.62402,9.52246,0.50216]

 

Port Praetorian [9.69238,9.31494,0.622216]

 

Mk21 Centurian [0.0341797,35.4907,0.433431]

 

Mk49 Spartan [-0.0546875,50.6006,0.433254]

 

 

 

 

Tankbuster, I'm trying to use the USS Liberty in Zeus mode and whenever I ask for help I keep getting pointed to this thread. 

 

I'm struggling to make sense of these instructions, can you help with more context/instructions for a LayPerson?

 

TIA :-)

Share this post


Link to post
Share on other sites

The numbers in the post are the offset relative to the centre point of the destroyer.

The last one - the Spartan for example is 0.054m to the right of the centreline of the ship (it is zero to all intents and purposes) and 50m forward of the middle of the ship and then, 0.4m above the middle point.

I'm not familiar with Zeus. I mean I know what it does, I've just never done it. If I write you a snippet of code, can you execute it in the game?

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

×