View topic - Immovable flying structures



All times are UTC + 1 hour


Post new topic Reply to topic  [ 21 posts ]  Go to page 1, 2  Next
Author Message
PostPosted: 14 May 2012, 13:53 
AI Coder
User avatar

Joined: 14 Sep 2004, 10:32
Location: Cookieland
I'm curious, and please slap me if this is a silly thing everybody knows is obvious but..

Right now we have:

  • Immovable floating structure
  • Movable floating units
  • Immovable uw structure
  • Movable uw units
  • Immovable ground structures
  • Movable ground units
  • Movable flying units

What about immovable flying structures? Aka structures that do not sit on the ground or have a ground presence, but have a position and altitude and obey air based pathing rather than ground based pathing. The sort that would need anti air to shoot at, that could not be issued move commands, and had all the normal structure abilities like being a factory etc

Without needing the usual hacks of turning mobile units into factories and giving them a speed of zero, or having a ground structure that has a tiny footprint and a model that's shifted upwards to look like it's flying


Top
 Offline Profile  
 
PostPosted: 14 May 2012, 14:01 
Moderator
User avatar

Joined: 26 Oct 2007, 15:21
Correct me if I am wrong, but this can be done with th following:
Completely open yardmap
Raise structure in upspring, make sure to correct its center and radius
Animate building to float up and down a bit
Put it in category vtol (or whatever your mod uses for air, as toairweapon is deprecated)
Put the los emit height high up, along with radar emit height.
Turn off terrain flattening under building.

All the above should result in what you desire.


Top
 Online Profile  
 
PostPosted: 14 May 2012, 14:34 
Moderator
User avatar

Joined: 22 Feb 2006, 01:02
Location: cheap kitchen
throw your units in the air with MoveCtrl :shock:


Top
 Offline Profile  
 
PostPosted: 14 May 2012, 18:38 
Kernel Panic Co-Developer
User avatar

Joined: 16 Nov 2004, 13:08
Beherith wrote:
All the above should result in what you desire.
No, instead of a structure that can only be hit by AA, you'd get a structure that cannot be hit.


Top
 Offline Profile  
 
PostPosted: 14 May 2012, 21:36 
Moderator
User avatar

Joined: 26 Oct 2007, 15:21
zw is correct, I tried it and it didnt work :(


Top
 Online Profile  
 
PostPosted: 15 May 2012, 07:45 
Evolution RTS Developer
User avatar

Joined: 17 Nov 2005, 02:43
Location: Raegquitting Spring on 04/24/12
zwzsg wrote:
Beherith wrote:
All the above should result in what you desire.
No, instead of a structure that can only be hit by AA, you'd get a structure that cannot be hit.


Put the structure in the vtol category (of whatever you use to define that this is an air unit that can or cannot be shot at by whatever).

Raise the model off of the ground in the script or in upspring.

Open yardmap.

Script move up and down a bit.

Set custom collision via unitdef.

I don't see the problem...

Example, Evolution RTS old ass versions (as in years ago... back before kaiserj came along) that had the central processing unit of spikeyness, bad particle effects and dewm.


Top
 Offline Profile  
 
PostPosted: 15 May 2012, 08:43 
Moderator

Joined: 12 Oct 2007, 08:24
You would not be able to place the construction blueprints on top of units and it would not construct if the destination is not clear.


Top
 Offline Profile  
 
PostPosted: 15 May 2012, 09:56 
Evolution RTS Developer
User avatar

Joined: 17 Nov 2005, 02:43
Location: Raegquitting Spring on 04/24/12
That's pretty minor...


Top
 Offline Profile  
 
PostPosted: 15 May 2012, 10:12 
Moderator
User avatar

Joined: 26 Oct 2007, 15:21
Forboding Angel wrote:
Put the structure in the vtol category (of whatever you use to define that this is an air unit that can or cannot be shot at by whatever).

This part doesnt work, I tried it.


Top
 Online Profile  
 
PostPosted: 15 May 2012, 11:06 
Evolution RTS Developer
User avatar

Joined: 17 Nov 2005, 02:43
Location: Raegquitting Spring on 04/24/12
Yeah it does. However, BA has too many categories, so until you fix that, your categories won't really work anyway (in infolog it tells you too many categories, etc etc etc).


Top
 Offline Profile  
 
PostPosted: 15 May 2012, 11:08 
User avatar

Joined: 30 Nov 2008, 04:31
Location: the flow
Last time i heard, you could either attach facs to transports with normal transport loading code, or just movectl them to position.

If a mobile flying factory can be done like that, why can't an immobile one.


Top
 Offline Profile  
 
PostPosted: 15 May 2012, 11:20 
Moderator
User avatar

Joined: 26 Oct 2007, 15:21
Forboding Angel wrote:
Yeah it does. However, BA has too many categories, so until you fix that, your categories won't really work anyway (in infolog it tells you too many categories, etc etc etc).

Stop saying that BA has too many categories, as it is clearly false.


Top
 Online Profile  
 
PostPosted: 15 May 2012, 12:44 
AI Coder
User avatar

Joined: 14 Sep 2004, 10:32
Location: Cookieland
My question general, not BA specific

Things that would make sense for true flying structures:

  • Units could walk underneath it ( check yardmap )
  • Aircraft could fly underneath at lower altitudes
  • Given an arbitrary 3D building placement widget, several could be built at the same location but at different altitudes
  • It would not deform terrain or have any slope tolerances ( hackable via extremely leniant values but for a flying structure this would not be necessary or apply)
  • Could be built in the air, no rising from the ground stuff

From the responses here I guess it is not possible, and the engine does not allow it, but there are approximations, e.g. flying aircraft that have a speed of 0 or structures that look like they're flying but aren't.


Top
 Offline Profile  
 
PostPosted: 15 May 2012, 17:34 
Moderator
User avatar

Joined: 29 Apr 2005, 00:14
Location: #moddev - join it!
Beherith wrote:
Forboding Angel wrote:
Put the structure in the vtol category (of whatever you use to define that this is an air unit that can or cannot be shot at by whatever).

This part doesnt work, I tried it.


Sorry behe but if that doesn't work, doin' it wrong.


Top
 Offline Profile  
 
PostPosted: 15 May 2012, 17:41 
Content Developer
User avatar

Joined: 13 Jan 2005, 00:46
Location: ModalitÃ
Solution:

enter marvel universe

ask blob to get into aircraft.

oh wait you needed a structure, well shit son, I am stumped.


Top
 Offline Profile  
 
PostPosted: 15 May 2012, 18:06 
User avatar

Joined: 23 Oct 2004, 00:43
Use 2 units?

One a immobilized air unit movectrled into the air, and one an untargetable open yardmap that just exists to block building more buildings on the spot?


Top
 Offline Profile  
 
PostPosted: 16 May 2012, 21:16 
AI Coder
User avatar

Joined: 14 Sep 2004, 10:32
Location: Cookieland
smoth wrote:
Solution:

enter marvel universe

ask blob to get into aircraft.

oh wait you needed a structure, well shit son, I am stumped.



I found the solution:

Code:
hasSuperman=true


Top
 Offline Profile  
 
PostPosted: 16 May 2012, 21:18 
Content Developer
User avatar

Joined: 13 Jan 2005, 00:46
Location: ModalitÃ
AF wrote:
Code:
hasSuperman=true

Fuck.


Top
 Offline Profile  
 
PostPosted: 16 May 2012, 22:27 
Moderator
User avatar

Joined: 22 Feb 2006, 01:02
Location: cheap kitchen
Since there is no urgent need, I guess the real question is can it be done with minimal effort.
you can move/create/damage units and if the factory thing is a problem you could replace it with a lua factory. Atm do not see the problem, guess it is "plausible"?
I had an idea but then my computer got ATIDS and minimal effort was exhausted.
Image


Top
 Offline Profile  
 
PostPosted: 25 May 2012, 05:08 
Moderator
User avatar

Joined: 22 Feb 2006, 01:02
Location: cheap kitchen
tl;dr goes to top of post
Image
normal flying units (like flying windmills or hover turrets) seem to be np, factories have with some quirks.

-------------
air unit with maxVelocity=0
-spawns at ground, then rises to its flightheight
-bops up and down a bit, as spring aircraft never like to sit 100% still
-when bumped, there is a chance that it will go flying in a random direction, off the map. (wut)
-builders can build under it
-aircrafts can not be a factory

------
unit script:
Code:
function script.Create()
Spring.MoveCtrl.Enable (unitID)
local x,y,z = Spring.GetUnitPosition (unitID)
Spring.MoveCtrl.SetPosition (unitID, x,y+300,z)
now unit sits perfectly still at its position in the air.

aircraft:
-when bumped, moves a few pixels (hardly noticeable but interessting)
coud be avoided by reseting position now and then or maybe there is some function for that.

ground unit:
works too, not sure what happens on collision
(was hard to tell and cba to make a testunit with bigger colsphere)

buildings:
-ground still blocked by yardmap, builders refuse to builder under unit
-yardMap = "yyy yyy yyy", and ground is free, builders build
yardmap = "" does not work.

factory:
[GiveUnits] spawned 1 tpfactory2 unit(s) for team 0
[f=0013556] [string "scripts/tpfactory2.lua"]:64: Enable(): Bad unitID
[f=0013556] stack traceback:
[C]: in function 'Enable'
[string "scripts/tpfactory2.lua"]:64: in function 'fun'
[string "LuaGadgets/Gadgets/unit_script.lua"]:747: in function <[string "LuaGadgets/Gadgets/unit_script.lua"]:745>

(wut)

A wupget appears:
Code:
local fly = {
--  [UnitDefNames["tpjeep"].id] = true,
  [UnitDefNames["tpsmallfac"].id] = true,
}
function gadget:UnitCreated(unitID, unitDefID, unitTeam, builderID)
   if fly[unitDefID] then
      Spring.MoveCtrl.Enable (unitID)
      local x,y,z = Spring.GetUnitPosition (unitID)
      Spring.MoveCtrl.SetPosition (unitID, x,y+200,z)
   end
end
Now the factory is in the air.
It builds, finished units appear at ground.
Problem:
build something under the factory and it can not build stuff.
(and builders will not begin construction under factory while it is building)
Problems seems to be that factory does not want to build if something is "in" in. Maybe solvable with different yardmap or moving the nanopiece elsewhere?

Funfact:
Flying factory on top of normal factory:
Image
Both can build, but only if the top factory is given the order first.

with all these variants, enemies will target the unit like before.
(this means moving your unit into the air does not make it targetable by AA weapons, you need to set categories)

:arrow: Need a way to make factories build even if their buildspot is blocked.


Top
 Offline Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 21 posts ]  Go to page 1, 2  Next

All times are UTC + 1 hour


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group

Site layout created by Roflcopter et al.