Jump to content
Sign in to follow this  
Nmenth

Building spawn

Recommended Posts

Is it possible for a base defense to spawn units like the Destroyer/Carrier? I tried it already using the Destroyer's spawn logic, without success.

 

If not, is it possible to limit how far from its dock an aircraft can fly to attack?

 

I'm making naval defenses here and would like each faction to have its own unique method of anti-naval attacks. So a floating Osprey platform is what I'd like for the Allies.

Share this post


Link to post

This is very possible, using the same logic as the Carrier even. However, any structure you use needs to be 1x1 or 3x3. Otherwise, you get a happy little IE window.

Share this post


Link to post

My test building was 2x2, but I didn't get an IE, just... nothing. The building merely sat there. Luckily my planned defense building is 1x1, but the art is not finished yet, I wanted to make sure the logic was possible before I did all that.

 

These are the codes I applied to my test building (new 1x1 test building):

Primary=ASWLauncher
NavalTargeting=1
Spawns=ASW
SpawnsNumber=1
SpawnRegenRate=400
SpawnReloadRate=150
NoSpawnAlt=no
FireAngle=32
Turret=no
Sensors=yes
SensorsSight=8
OpportunityFire=yes

Still nothing. No crash, no glitchyness, just nothing.

Share this post


Link to post

It's probably your NavalTargeting value. It means use Secondary against water. I don't see a secondary so I would take that off.

But it also seems as though you lack the necessary base defense tags as well.

 

You don't need NoSpawnAlt, Turret or OpportunityFire. You do, however, need IsBaseDefense=yes, HasStupidGuardMode=false, AntiInfantryValue, AntiArmorValue and AntiAirValue.

Share this post


Link to post
It's probably your NavalTargeting value. It means use Secondary against water. I don't see a secondary so I would take that off.

Well that makes sense... :mellow:

 

You don't need NoSpawnAlt, Turret

Oops, those were on my first test building, not my second one... forgot to remove them from the codebox.

 

It now works, but cannot detect submarines (despite having sensors), and only counterattacks... are you sure I shouldn't use OpportunityFire?

Share this post


Link to post

Base defenses work different when it comes to acquiring targets. They do it automatically through IsBaseDefense. That's very necessary when it comes to auto-acquire.

Share this post


Link to post

Well I added all the codes you suggested...

So what else is missing?

 

Oh, and when I make the art for this, are buildings able to use alternate art for having it's spawn and no spawn like the Destroyer?

Assuming that they are, I'll need to grab a copy of the Osprey to slap onto the building, for which I'll need an hva editor. Where can I get a good one of those?

Share this post


Link to post
Buildings are not voxels. You won't need an HVA editor.

I know, I just want to be able to see what the Osprey is supposed to look like, and I'd like an editor anyway, in case I want to start making units.

 

Now I'm also having problems with my OS SHP Builder (I think). All three of my new naval defense SHPs are not remapping in the previews. The 'Red to Remapable' is checked and I know my shades of red are correct because it used to work while I was creating them, but now when I open the saved SHPs, they refuse to remap. All my old SHPs still work fine, but not these three (six if you count both generic and snow, but both versions are identical).

The only thing all three buildings have in common is being the latest SHPs I've made and having (modified) water ripples stolen from the Allied Shipyard.

Is this a problem with the Builder or something I've done? And will they still remap when inserted into the game even if the preview doesn't work?

Share this post


Link to post

You should be able to load dest.vxl in the OS Voxel Editor and still see the Osprey on it, or just load asw.vxl. Same thing really. There's an OS HVA Editor available as well.

 

And I'm sure bugs like that exist with the OS SHP Builder. I'd test it in-game first, then file a bug report on PPM.

Share this post


Link to post

I got a HVA Builder, but it only wants to open VXLs... how do I get into HVAs? Eh... I hate all these different file names...

Share this post


Link to post

I don't get it... the Destroyer is dest.hva, why can't an HVA Builder open dest.hva?

Share this post


Link to post

You don't open an HVA, you create one based on the voxel. The only time you would need to edit an HVA is if it's animated.

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.

×