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
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.
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.
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).
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.
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.
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?
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.
Joined: 22 Feb 2006, 01:02 Location: cheap kitchen
tl;dr goes to top of post 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: 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)
Need a way to make factories build even if their buildspot is blocked.
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