.entity to Reality

Through the various times I've tried to make things, I have run into a consistent problem.  A complete lack of understanding of how to take something from a list of entity files and add it to the game.

For what I'm working on right now, I'm giving the Enforcer the ability to knock down armor on the targets it hits.  This is a relatively simple and straightforward modding process.  Eventually, I'm left with AbilityHullCracker.entity, BuffHullCrackerSelf.entity, and BuffHullCrackerTarget.entity.  All of these look as if they would work.  I have added them to entity.manifest and have updated the ability file to have the first wave cannon upgrade as the prerequisite for this ability.  All these things are present, yet when I attempt to run the game, this ability is conspicuously absent.

I am inclined to believe that it has to do with the HUDIcon-Ability file, but I am not sure.  I have absolutely no idea how to handle brush files.  Opening them in notepad reveals some sort of matrix which I suppose deals with where they will go on the screen in game, though I am not sure.  I have looked through tutorials, but they did not seem to answer what I was looking for.  Perhaps I missed it, but regardless, I don't know how to take something from a .entity to something that can actually be seen in the game unless I simply modify an already existing file.  Adding new content simply stupifies me.  I can't seem to get something from a simple data file to something that actually adds to gameplay.

 

So to refresh here's what I've done...

1. created ability and buff files for passive ability of Skarovas enforcers to reduce armor by 2 points (non-stacking)

2. referenced the hud files for the wave2 HUD research button because I didn't feel like designing my own image.  (I get the feeling this may be a problem.)

3. made the first wave cannon upgrade the prerequisite to this ability.

4. updated entity.manifest

5. attempted to use but found it was not present  <_<

 

How do I get it to actually exist?  I'm assuming it is because of brush files, but I don't know... :(

9,220 views 20 replies
Reply #1 Top

Its not the hudicons, they are purely cosmetic and you can just leave that line as "" if you wanted.

Did you actually give your ability to the enforcer? Also are you sure your mod checksum is not zero?

Reply #2 Top

I did add it to the enforcer's file.  Forgot to mention that.  And no, my checksum is not zero.

Reply #3 Top

What levelSourceType are you using?

Reply #4 Top

ResearchWithoutBase

Reply #5 Top

There shouldn't be any change to a research file in order to unlock an ability.  Something is off with your description here.

Reply #6 Top

Quoting Volt_Cruelerz, reply 4
ResearchWithoutBase

Research without base requires you to have the listed research researched before you can access that ability. If you meant to have the ability available right way use fixedlevel0.

Reply #7 Top

I can try that, but I was intending it to be accessed only after research (the first wave cannon upgrade).

 

EDIT: that didn't do anything.  It doesn't show up.  Somehow the stupid thing just isn't getting sent into the game...

Reply #8 Top

Can you put the whole ability file up?

Quoting Volt_Cruelerz, reply 7
EDIT: that didn't do anything. It doesn't show up. Somehow the stupid thing just isn't getting sent into the game...

I'm sure it's something extremely basic, like enabling the wrong mod, using other mods, or something like that.

Reply #9 Top

Is it possible that you're enabling the mod, but don't apply?

Reply #10 Top

I'm using the correct mod.  In fact, this is just a segment of an entire mod I'm working on.  Rebalancing/switching around old abilities is something I've been doing that is functional.  This segment and another that I'm assuming has a similar problem are what are not working (it is a researchable that I created that isn't showing up in the tree).  Any time there's something clicky/buttony that I try to add to the game, it never shows up.  I'm assuming it's the same problem.

 

Anyways, here's the ability file:

 

TXT
entityType "Ability"
buffInstantActionType "ApplyBuffToSelf"
instantActionTriggerType "AlwaysPerform"
buffType "BuffHullCrackerSelf"
effectInfo
effectAttachInfo
attachType "Invalid"
smallEffectName ""
largeEffectName ""
soundID ""
needsToFaceTarget FALSE
canCollideWithTarget TRUE
moveThruTarget FALSE
isUltimateAbility FALSE
maxNumLevels 2
levelSourceType "ResearchWithoutBase"
improveSourceRresearchSubject "RESEARCHSUBJECT_WEAPONDAMAGE_WAVE0"
aiUseTime "Invalid"
aiUseTargetCondition "Invalid"
isAutoCastAvailable FALSE
isAutoCastOnByDefault FALSE
pickRandomPlanetToExploreForAutoCastTarget FALSE
ignoreNonCombatShipsForAutoCastTarget TRUE
onlyAutoCastWhenDamageTakenExceedsPerc 0.000000
useCostType "Passive"
researchPrerequisites
NumResearchPrerequisites 1
ResearchPrerequisite
Subject "RESEARCHSUBJECT_WEAPONDAMAGE_WAVE0"
Level 1
nameStringID "IDS_ABILITY_HULLCRACKER_NAME"
descStringID "IDS_ABILITY_HULLCRACKER_DESCRIPTION"
hudIcon "HUDICON_RESEARCHSUBJECT_WEAPONDAMAGE_WAVE2"
smallHudIcon "HUDICON_RESEARCHSUBJECT_WEAPONDAMAGE_WAVE2"
infoCardIcon ""
Reply #11 Top

Add the research to the manifest and the player file research list?

 

:fox:

Reply #12 Top

Quoting Volt_Cruelerz, reply 10
Any time there's something clicky/buttony that I try to add to the game, it never shows up.

The buttons have nothing to do with it, in fact you've even given the game a valid icon to display there. I think you have a more fundamental problem somewhere. Anyways, assuming you haven't touched the research trees that ability is only supposed to appear after researching the wave damage upgrade. Any other reasons may include.

1. Not properly referencing the ability in the ship entity file.

2. Enabling another mod that also changes the ship entity file.

3. Not having the ability file in the entity.manifest (note you must have .entity at the end of the file name).

4. Not updating a count somewhere.

Are you by chance using the developer.exe? It may throw some error messages at you if its due to say a spelling mistake or entity error.

Reply #13 Top

@Kitkun: I did that with the researchable, but it didn't do anything...  Anyways, I'm focusing on the ability right now, sorry...

@Goa...  entityName "AbilityHullCracker.entity" is what is what that line is in the manifest.

ability:0 "AbilityGravityField"
ability:1 "AbilitySelfRepairHeavy"
ability:2 "AbilityHullCracker"
ability:3 ""
ability:4 ""
Is what's present in the enforcer's file.

 I'm not using any other mods.  

What counts?

And no, I'm not using the dev.  Just standard Sins at this point.

 

It should look like the wave cannon upgrade.  That was the idea, but I have no idea how to get the stupid thing to show up...  #:(

 

EDIT: Running the dev version quickly, it kept hating this line:

improveSourceRresearchSubject "RESEARCHSUBJECT_WEAPONDAMAGE_WAVE0" in the ability file.  Any ideas why?

Reply #14 Top

Quoting Volt_Cruelerz, reply 13
improveSourceRresearchSubject "RESEARCHSUBJECT_WEAPONDAMAGE_WAVE0" in the ability file.  Any ideas why?

It's elementary, my dear Volt.

You've added an additional "R" in "improveSourceResearchSubject".

Reply #15 Top

Oh...  :\   Well, it's there now...  Thanks lol...  ^_^

So, ability problem solved...  As for the researchable...  Here's the code...

 

  1. TXT
  2. entityType "ResearchSubject"
  3. hudIcon "HUDICON_ABILITY_DISABLEIMMUNE"
  4. smallHudIcon "HUDICON_ABILITY_DISABLEIMMUNE"
  5. infoCardIcon ""
  6. NameStringID "IDS_RESEARCHSUBJECT_PLANETBOMBING_REDUCEDPOPULATIONKILLED_NAME"
  7. DescriptionStringID "IDS_RESEARCHSUBJECT_PLANETBOMBING_REDUCEDPOPULATIONKILLED_DESCRIPTION"
  8. researchWindowLocation
  9. block 0
  10. pos [ 4 , 3 ]
  11. ResearchField "NonCombat"
  12. Prerequisites
  13. NumResearchPrerequisites 1
  14. ResearchPrerequisite
  15. Subject "RESEARCHSUBJECT_PLANETBOMBING_REDUCEDPOPULATIONKILLED"
  16. Level 2
  17. MinimumArtifactLevel -1
  18. BaseUpgradeTime 60.000000
  19. PerLevelUpgradeTime 5.000000
  20. BaseCost
  21. credits 1000.000000
  22. metal 150.000000
  23. crystal 250.000000
  24. PerLevelCostIncrease
  25. credits 100.000000
  26. metal 25.000000
  27. crystal 25.000000
  28. Tier 4
  29. onlyWorksIfTierLabsExist FALSE
  30. MaxNumResearchLevels 3
  31. priority 1.000000
  32. researchBoolModifiers 0
  33. researchFloatModifiers 1
  34. researchModifier
  35. modifierType "HullPointsRegenAdjustment"
  36. baseValue 0.000000
  37. perLevelValue 0.05000
  38. researchModifier //--------------------------it is calling this the bad line in dev
  39. modifierType "ArmorBaseAdjustment"
  40. baseValue 0.000000
  41. perLevelValue 0.500000
  42. artifactPicture ""

 

 

 

Reply #16 Top

Quoting Volt_Cruelerz, reply 15
Oh... Well, it's there now... Thanks lol...

Told you. ;)

As to that research, you forgot to update the count.

Quoting Volt_Cruelerz, reply 15

researchFloatModifiers 1
researchModifier (1)
modifierType "HullPointsRegenAdjustment"
baseValue 0.000000
perLevelValue 0.05000
researchModifier (2)//--------------------------it is calling this the bad line in dev
modifierType "ArmorBaseAdjustment"
baseValue 0.000000
perLevelValue 0.500000

Looks like 2 modifiers to me.

Reply #17 Top

Lol it does to me as well lol.  Thanks again.

 

EDIT: okay, well it looks like everything works except for one other file in the mod

 

  1. TXT
  2. entityType "ResearchSubject"
  3. hudIcon "HUDICON_RESEARCHSUBJECT_WEAPONDAMAGE_BEAMTECH1"
  4. smallHudIcon "HUDICON_RESEARCHSUBJECT_WEAPONDAMAGE_BEAMTECH1"
  5. infoCardIcon ""
  6. NameStringID "IDS_RESEARCHSUBJECT_WEAPONDAMAGE_BEAMTECH1_NAME"
  7. DescriptionStringID "IDS_RESEARCHSUBJECT_WEAPONDAMAGE_BEAMTECH1_DESCRIPTION"
  8. researchWindowLocation
  9. block 1
  10. pos [ 3 , 1 ]
  11. ResearchField "Combat"
  12. Prerequisites
  13. NumResearchPrerequisites 1
  14. ResearchPrerequisite
  15. Subject "RESEARCHSUBJECT_WEAPONDAMAGE_BEAMTECH0"
  16. Level 2
  17. MinimumArtifactLevel -1
  18. BaseUpgradeTime 60.000000
  19. PerLevelUpgradeTime 5.000000
  20. BaseCost
  21. credits 1000.000000
  22. metal 150.000000
  23. crystal 250.000000
  24. PerLevelCostIncrease
  25. credits 100.000000
  26. metal 25.000000
  27. crystal 25.000000
  28. Tier 3
  29. onlyWorksIfTierLabsExist FALSE
  30. MaxNumResearchLevels 2
  31. priority 1.000000
  32. researchBoolModifiers 2
  33. researchModifier
  34. modifierType "WeaponDamageAdjustment"
  35. baseValue 0.000000 //----------------------------It was on this right before a minidump
  36. perLevelValue 0.025000
  37. linkedWeaponClass "LASERTECH"
  38. researchModifier
  39. modifierType "WeaponDamageAdjustment"
  40. baseValue 0.000000
  41. perLevelValue 0.050000
  42. linkedWeaponClass "BEAM"
  43. artifactPicture ""

 

Reply #18 Top

I'm trying to expand this to include things across the races so that each race gets a new ability on its HC's.  For Kodiaks, I've created a Ram ability that does exactly that.  It goes after the target and runs into it, dealing damage to itself.  That's all well and good except that it doesn't actually damage the target...  As a result, I began looking and saw on the line 

buffInstantActionType "ApplyBuffToSelfWithFilter"

that it was targeting itself rather than what it should.  As a result, I changed it to ApplyBuffToTargetNoRange.  Now, it throws weird errors when I run the mod.  Why?  Here's the rest of the code...

 

TXT
  1. entityType "Buff"
  2. onReapplyDuplicateType "PrioritizeNewBuffs"
  3. buffStackingLimitType "ForAllPlayers"
  4. stackingLimit 1
  5. allowFirstSpawnerToStack FALSE
  6. buffExclusivityForAIType "ExclusiveForAllPlayers"
  7. isInterruptable FALSE
  8. isChannelling FALSE
  9. numInstantActions 4
  10. instantAction
  11. buffInstantActionType "DoDamage"
  12. instantActionTriggerType "OnDelay"
  13. delayTime 0.000000
  14. damage
  15. Level:0 150.000000
  16. Level:1 0.000000
  17. Level:2 0.000000
  18. damageAffectType "AFFECTS_SHIELDS_AND_HULL"
  19. damageType "PHYSICAL"
  20. isDamageShared TRUE
  21. instantAction
  22. buffInstantActionType "InitializeRandomMotion"
  23. instantActionTriggerType "OnDelay"
  24. delayTime 0.000000
  25. minRandomAngularSpeed 0.150000
  26. maxRandomAngularSpeed 0.500000
  27. minRandomLinearSpeed -15.000000
  28. maxRandomLinearSpeed -30.000000
  29. instantAction
  30. buffInstantActionType "ApplyBuffToTargetNoRange"
  31. instantActionTriggerType "OnDelay"
  32. delayTime 0.000000
  33. buffType "BuffRamTargetEngines"
  34. targetFilter
  35. numOwnerships 1
  36. ownership "Enemy"
  37. numObjects 2
  38. object "CapitalShip"
  39. object "Frigate"
  40. numSpaces 1
  41. space "Normal"
  42. numConstraints 0
  43. instantAction
  44. buffInstantActionType "ApplyBuffToTargetNoRange"
  45. instantActionTriggerType "OnDelay"
  46. delayTime 0.000000
  47. buffType "BuffRamTargetStatic"
  48. targetFilter
  49. numOwnerships 1
  50. ownership "Enemy"
  51. numObjects 2
  52. object "StarBase"
  53. object "PlanetModule"
  54. numSpaces 1
  55. space "Normal"
  56. numConstraints 0
  57. numPeriodicActions 0
  58. numOverTimeActions 0
  59. numEntityModifiers 0
  60. numEntityBoolModifiers 0
  61. numFinishConditions 1
  62. finishCondition
  63. finishConditionType "AllOnDelayInstantActionsDone"
 
The minidump log said
Text FileArchive missing Label.

File: C:\Users\Michael\AppData\Local\Ironclad Games\Sins of a Solar Empire\Mods-Diplomacy v1.21\Kodiak\GameInfo\BuffRamSelf.entity
Label: effectInfo
Line Number:43
Line Contents:instantAction
 
It seems to think there should be an effect there or something.  
All I want it to do is send either BuffRamTargetEngines or BuffRamTargetStatic. 

 

It just doesn't really make sense to me why it would...  (Engines and Static are variations of the buff based upon whether the target is capable of movement or not.  The main function of both is to deal damage.)  It is definitely worth noting that the mod does end up running and functions as intended (damage is dealt), but I just want to know why it thinks there should be an effect or something there...

Reply #19 Top

Quoting Volt_Cruelerz, reply 18
File: C:\Users\Michael\AppData\Local\Ironclad Games\Sins of a Solar Empire\Mods-Diplomacy v1.21\Kodiak\GameInfo\BuffRamSelf.entity
Label: effectInfo
Line Number:43
Line Contents:instantAction

Each Instant Action Type has its own formatting, and ApplyBuffToTargetNoRange requires an effect section at the end. You don't need to use it for anything, but it still needs to be there. That's why you should always look at preexisting abilities that use these types so you see which lines are needed, just don't blindly pick from a list of them and expect them to all work the same.

Reply #20 Top

Quoting GoaFan77, reply 19
Each Instant Action Type has its own formatting, and ApplyBuffToTargetNoRange requires an effect section at the end. You don't need to use it for anything, but it still needs to be there. That's why you should always look at preexisting abilities that use these types so you see which lines are needed, just don't blindly pick from a list of them and expect them to all work the same.

In fact, there's a ramming ability in the BSG mod.....you might want to D/L it and give it a lookover.