[SOLVED] Frigates not appearing

I’m running into a problem with my mod where I am building frigates from a carrier and the frigates are simply not appearing after they are built. There are no errors in the log. They are counted toward the unitcaps.

Has anyone ever encountered this?

The race is Hiigaran if that makes a difference.

1 Like

I have encountered similar issues in the past that seemed related to dockpath problems, but my solution was one that doesn’t really help in this case, as I’m assuming you’re using a ship that can launch frigates typically?

It’s a modified carrier. But the only modification I made was to remove the advanced research module in the .ship file.

Also, a correction. I am able to build defense field frigates and marine frigates. I have also granted all research.

[edit]

Also, I have seen flak frigates and torpedo frigates in the CPU players’ fleets, and they are Hiigaran too.

I’ve had this happen just recently while playing through the stock campaign. Not with frigates for me though… it happened with salcaps several times…

The problem in my case seems to be when I use the Player_GrantAllResearch() function. I also tried creating my own function to parse “def_research.lua” and grant all research. The same problem occurred again.

There is some kind of research item in “def_research.lua” that is causing this problem I think. I don’t know what. Or the problem is my custom carrier. Here’s my custom carrier:

NewShipType.displayedName="$1542"
NewShipType.sobDescription="$1543"
NewShipType.maxhealth=getShipNum(NewShipType, "maxhealth", 80000)
NewShipType.regentime=2000
NewShipType = StartShipConfig()
NewShipType.minRegenTime=2000
NewShipType.sideArmourDamage = getShipNum(NewShipType, "sideArmourDamage", 1.0)
NewShipType.rearArmourDamage = getShipNum(NewShipType, "rearArmourDamage", 1.0)
setTacticsMults(NewShipType, "ENGINEACCEL", 1.10, 0.90, 1.0)
setTacticsMults(NewShipType, "THRUSTERACCEL", 1.10, 0.90, 1.0)
setTacticsMults(NewShipType, "ROTATION", 0.95, 1.05, 1.0)
setTacticsMults(NewShipType, "ROTATIONACCEL", 1.10, 0.90, 1.0)
setTacticsMults(NewShipType, "FIRERATE", 0.98, 1.02, 1.0)
NewShipType.isTransferable=0
NewShipType.addedUnitCaps=101
NewShipType.paradeData="hgn_carrier_parade"
NewShipType.defaultROE="Defensive"
NewShipType.defaultStance="Neutral"
NewShipType.mass=1000
NewShipType.collisionMultiplier=1
NewShipType.thrusterMaxSpeed=81
NewShipType.mainEngineMaxSpeed=81
NewShipType.rotationMaxSpeed=8
NewShipType.thrusterAccelTime=6
NewShipType.thrusterBrakeTime=2
NewShipType.mainEngineAccelTime=6
NewShipType.mainEngineBrakeTime=2
NewShipType.rotationAccelTime=0.5
NewShipType.rotationBrakeTime=0.3
NewShipType.thrusterUsage=1
NewShipType.accelerationAngle=30
NewShipType.mirrorAngle=0
NewShipType.secondaryTurnAngle=0
NewShipType.maxBankingAmount=10
NewShipType.descendPitch=10
NewShipType.goalReachEpsilon=25
NewShipType.slideMoveRange=350
NewShipType.controllerType="Ship"
NewShipType.tumbleStaticX=2
NewShipType.tumbleStaticY=4
NewShipType.tumbleStaticZ=3
NewShipType.tumbleDynamicX=1
NewShipType.tumbleDynamicY=2
NewShipType.tumbleDynamicZ=2
NewShipType.tumbleSpecialDynamicX=1
NewShipType.tumbleSpecialDynamicY=2
NewShipType.tumbleSpecialDynamicZ=2
NewShipType.relativeMoveFactor=1
NewShipType.swayUpdateTime=10
NewShipType.swayOffsetRandomX=10
NewShipType.swayOffsetRandomY=10
NewShipType.swayOffsetRandomZ=10
NewShipType.swayBobbingFactor=0
NewShipType.swayRotateFactor=0
setTargetBox(NewShipType, 0, -0.42,-0.4,-0.8, 0.69,0.5,0.55);
NewShipType.useLayoutBounds=1
NewShipType.layoutBoundX=130
NewShipType.layoutBoundY=60
NewShipType.layoutBoundZ=350
NewShipType.layoutCenterX=-20
NewShipType.layoutCenterY=0
NewShipType.layoutCenterZ=50
NewShipType.dustCloudDamageTime=200
NewShipType.nebulaDamageTime=300
NewShipType.MinimalFamilyToFindPathAround="MotherShip"
NewShipType.BuildFamily="SuperCap_Hgn"
NewShipType.AttackFamily="BigCapitalShip"
NewShipType.DockFamily="Carrier"
NewShipType.AvoidanceFamily="SuperCap"
NewShipType.DisplayFamily="Capital"
NewShipType.AutoFormationFamily="CapShip"
NewShipType.CollisionFamily="Big"
NewShipType.ArmourFamily=getShipStr(NewShipType, "ArmourFamily", "HeavyArmour")
setSupplyValue(NewShipType, "Capital", 1.0)
setSupplyValue(NewShipType, "Carrier", 1.0)
NewShipType.AttackPriorityMultiplier=0.96
NewShipType.fighterValue=0
NewShipType.corvetteValue=0
NewShipType.frigateValue=10
NewShipType.neutralValue=5
NewShipType.antiFighterValue=5
NewShipType.antiCorvetteValue=0
NewShipType.antiFrigateValue=0
NewShipType.totalValue=15
NewShipType.buildCost=2800
NewShipType.buildTime=65
NewShipType.buildPriorityOrder=30
NewShipType.retaliationRange=6500
NewShipType.retaliationDistanceFromGoal=160
NewShipType.visualRange=1000
NewShipType.prmSensorRange=5000
NewShipType.secSensorRange=6000
NewShipType.detectionStrength=1
NewShipType.TOIcon="Rectangle"
NewShipType.TOScale=1
NewShipType.TODistanceFade0=14000
NewShipType.TODistanceDisappear0=12000
NewShipType.TODistanceFade1=5500
NewShipType.TODistanceDisappear1=5000
NewShipType.TODistanceFade2=12000
NewShipType.TODistanceDisappear2=35000
NewShipType.TOGroupScale=1
NewShipType.TOGroupMergeSize=0
NewShipType.mouseOverMinFadeSize=0.085
NewShipType.mouseOverMaxFadeSize=0.15
NewShipType.healthBarStyle=2
NewShipType.nlips=0
NewShipType.nlipsRange=10000
NewShipType.nlipsFar=0
NewShipType.nlipsFarRange=0
NewShipType.SMRepresentation="Mesh"
NewShipType.meshRenderLimit=21000
NewShipType.dotRenderLimit=10
NewShipType.visibleInSecondary=1
NewShipType.goblinsStartFade=3200
NewShipType.goblinsOff=3200
NewShipType.upLOD=6150
NewShipType.downLOD=6165
NewShipType.minimumZoomFactor=0.5
NewShipType.selectionLimit=150000
NewShipType.preciseSelectionLimit=7500
NewShipType.preciseATILimit=0
NewShipType.selectionPriority=75
NewShipType.militaryUnit=0
NewShipType.SMHighlightDistMin=20000
NewShipType.SMHighlightDistMax=25000
addAbility(NewShipType,"MoveCommand",1,0);
addAbility(NewShipType,"CanDock",1,0);
NewShipType.dockTimeBetweenTwoFormations=1
NewShipType.dockTimeBeforeStart=2
NewShipType.dockNrOfShipsInDockFormation=1
NewShipType.dockFormation="delta"
NewShipType.queueFormation="dockline"
NewShipType.strikeGroupRadius=200
NewShipType.dontDockWithOtherRaceShips=1
NewShipType.ignoreRaceWhenDocking=0
addAbility(NewShipType,"CanLaunch");
NewShipType.launchTimeBetweenTwoFormations=1
NewShipType.launchTimeBeforeStart=2
NewShipType.launchNrOfShipsInDockFormation=1
NewShipType.launchFormation="delta"
NewShipType.strikeGroupRadius=150
addAbility(NewShipType,"ShipHold",1,40,100,"rallypoint","Fighter, Corvette,Utility",35,{Fighter="36"},{Corvette="75"});
addAbility(NewShipType,"ParadeCommand",1);
addAbility(NewShipType,"WaypointMove");
addAbility(NewShipType,"HyperSpaceCommand",0,1,400,800,0,3);
addAbility(NewShipType,"CanAttack",1,1,0,0,0.35,1,"Fighter, Fighter_hw1, Corvette, Corvette_hw1, Frigate,  SmallCapitalShip, BigCapitalShip, Utility","JustShoot");
addAbility(NewShipType,"GuardCommand",1,3000,1000);
addAbility(NewShipType,"CanBuildShips",1,"Fighter_Hgn, Corvette_Hgn, Frigate_Hgn, Utility_Hgn, Platform_Hgn, SubSystem_Hgn,Shipyard_Hgn, Probe_Hgn","Utility, Fighter, Corvette, Frigate, Platform, SubSystemModule, SubSystemSensors, Capital");
addAbility(NewShipType,"CanBeCaptured",160,0.5,"CapCap");
addAbility(NewShipType,"CanBeSalvageCaptured",0,1,0,0,1,"SalCap");
addAbility(NewShipType,"CanBeRepaired","RepCap");
addAbility(NewShipType,"CloakAbility",0,2,2000,4000,3,100,1,1000);
addAbility(NewShipType,"RetireAbility",1,1);
addAbility(NewShipType,"HyperspaceInhibitorAbility",0,12000);
NewShipType.noCombatGrouping=1
addCustomCode(NewShipType,"data:Ship/Hgn_Carrier_Research0/Hgn_Carrier_Research0.lua","","Create_Hgn_Carrier_Research0","Update_Hgn_Carrier_Research0","","Hgn_Carrier_Research0",4)

--LoadModel(NewShipType,1)
LoadSharedModel(NewShipType, "hgn_carrier")

StartShipWeaponConfig(NewShipType,"Hgn_MSHullDefenseGun2","Weapon_HullDefense1","Weapon_HullDefense1");
StartShipWeaponConfig(NewShipType,"Hgn_MSHullDefenseGun2","Weapon_HullDefense2","Weapon_HullDefense2");
StartShipWeaponConfig(NewShipType,"Hgn_MSHullDefenseGun2","Weapon_HullDefense3","Weapon_HullDefense3");
StartShipWeaponConfig(NewShipType,"Hgn_MSHullDefenseGun2","Weapon_HullDefense4","Weapon_HullDefense4");
addShield(NewShipType,"EMP",10000,20);
StartShipHardPointConfig(NewShipType,"Production 1","HardpointProduction1","System","Production","Destroyable","","Hgn_C_Production_Fighter","","","","","","","");
StartShipHardPointConfig(NewShipType,"Production 2","HardpointProduction2","System","Production","Destroyable","","Hgn_C_Production_Corvette","","","","","","","");
StartShipHardPointConfig(NewShipType,"Production 3","HardpointProduction3","System","Production","Destroyable","","Hgn_C_Production_Frigate","Hgn_C_Production_FrigateAdvanced","","","","","","");
StartShipHardPointConfig(NewShipType,"Generic 1","HardpointGeneric1","System","Generic","Destroyable","","Hgn_C_Module_Research","Hgn_C_Module_Hyperspace","Hgn_C_Module_PlatformControl","Hgn_C_Module_CloakGenerator","Hgn_C_Module_HyperspaceInhibitor","Hgn_C_Module_FireControl_research0","Hgn_C_Module_BuildSpeed","");
StartShipHardPointConfig(NewShipType,"Generic 2","HardpointGeneric2","System","Generic","Destroyable","","Hgn_C_Module_Research","Hgn_C_Module_Hyperspace","Hgn_C_Module_PlatformControl","Hgn_C_Module_CloakGenerator","Hgn_C_Module_HyperspaceInhibitor","Hgn_C_Module_FireControl_research0","Hgn_C_Module_BuildSpeed","");
StartShipHardPointConfig(NewShipType,"Sensors 1","HardpointSensors1","System","Sensors","Destroyable","","Hgn_C_Sensors_DetectHyperspace","Hgn_C_Sensors_AdvancedArray","Hgn_C_Sensors_DetectCloaked","","","","","");
StartShipHardPointConfig(NewShipType,"Engine","Hardpoint_Engine","System","Innate","Damageable","Hgn_C_Engine","","","","","","","","");
StartShipHardPointConfig(NewShipType,"Resource","Hardpoint_Resource","System","Innate","Damageable","Hgn_C_Innate_Resource","","","","","","","","");
SpawnSalvageOnDeath(NewShipType,"Slv_Chunk_Lrg03",1,  0.40,0,0,0, 0,0,0,50,0,0,0,200,0,0,0,50,0,0,0,50);
SpawnSalvageOnDeath(NewShipType,"Slv_Chunk_Lrg02",1,  0.19,0,0,0, 0,0,0, 30,-20,200,25,300,150,85,50,0,0,0,85,0,0,0,50);
SpawnSalvageOnDeath(NewShipType,"Slv_Chunk_Lrg04",1,  0.13,0,0,0, 0,0,0, 50,40,-150,50,65,25,5,25,0,0,0,95,0,0,0,50);
SpawnSalvageOnDeath(NewShipType,"Slv_Chunk_Lrg05",1,  0.10,0,0,0, 0,0,0, 25,10,-100,30,35,75,62,75,0,0,0,80,0,0,0,50);
SpawnSalvageOnDeath(NewShipType,"Slv_Chunk_Sml02",1,  0.06,0,0,0, 0,0,0, 25,0,-125,50,80,35,120,75,0,0,0,60,0,0,0,50);
SpawnSalvageOnDeath(NewShipType,"Slv_Chunk_Sml03",1,  0.05,0,0,0, 0,0,0, 60,95,200,50,15,200,20,125,0,0,0,60,0,0,0,50);
SpawnSalvageOnDeath(NewShipType,"Slv_Chunk_Sml04",1,  0.04,0,0,0, 0,0,0, 10,60,-300,25,35,80,65,75,0,0,0,60,0,0,0,50);
SpawnSalvageOnDeath(NewShipType,"Slv_Chunk_Sml05",1,  0.03,0,0,0, 0,0,0, 60,10,30,75,35,25,65,75,0,0,0,60,0,0,0,50);
NewShipType.battleScarCoverage=4
NewShipType.battleScarBudgetLow = 800
NewShipType.battleScarBudgetNext = 1200
NewShipType.sobDieTime=9.4
NewShipType.sobSpecialDieTime=4
NewShipType.specialDeathSpeed=40
NewShipType.chanceOfSpecialDeath=0
NewShipType.deadSobFadeTime=0.01
NewShipType.trailLinger=6
setEngineBurn(NewShipType,9,0.2,0.5,300,1.02,0.1,0.25,380);
setEngineGlow(NewShipType,1,1,1.02,20,300,50,1.5,{0.27, 0.47, .69, 0.25});
loadShipPatchList(NewShipType,"data:sound/sfx/ship/",0,"Hiigaran/Carrier/Engines/HDestroyerEng","",1,"Hiigaran/Carrier/Ambience/HAssaultCarrierAmb","",3,"Megaliths/RandomEmit/HANGAR_EMITTERS","NavLight_BigBay");
loadLatchPointList(NewShipType,"SalCap","SalvagePoint1","SalvagePoint2","SalvagePoint3","SalvagePoint4","SalvagePoint5","SalvagePoint6");	
loadLatchPointList(NewShipType,"CapCap","CapturePoint1","CapturePoint2","CapturePoint3","CapturePoint4");
loadLatchPointList(NewShipType,"RepCap","RepairPoint0","RepairPoint1","RepairPoint2","RepairPoint3","RepairPoint4");
NewShipType.minFalloffDamageDist=450
NewShipType.maxFalloffDamageDist=450*1.5
NewShipType.maxFalloffScuttleDamageDist=450*3
NewShipType.explosiveScuttleDamageOnDeath=1960
NewShipType.maxFalloffForce=500*10
NewShipType.explosiveDamageOnDeath=275
NewShipType.radiusDamageEvadeMod=1.1													 
NewShipType.hideNormalAttackUICooldown=1
NewShipType.canSurround=1

Not sure if it affects just Hiigarans.

The problem had to do with players being granted stuff from “explicit_grant.lua” that they should not have been granted. Since Player_GrantAllResearch() also seems to be affected, I think this can be considered a game bug.

[edit]

On second thought, I think you’re supposed to restrict the bad stuff before calling this function. So it’s not a game bug. Sorry.