Error with abilities and buffs

After editing a couple of abilities and buffs I've run into an error which makes little sense to me, and I've got no idea how to fix it.

The error is:

Text FileArchive missing Label.

File: C:\Users\Matt\Documents\My Games\Ironclad Games\Sins of a Solar Empire Rebellion\Mods-Rebellion v1.031 Dev\Real Space\GameInfo\BuffHeatGiver.entity
Label: effectInfo
Line Number:58
Line Contents: targetFilter

and

Text FileArchive missing Label.

File: C:\Users\Matt\Documents\My Games\Ironclad Games\Sins of a Solar Empire Rebellion\Mods-Rebellion v1.031 Dev\Real Space\GameInfo\BuffHeatGiver.entity
Label: numPeriodicActions
Line Number:59
Line Contents: targetFilter

and

Text FileArchive missing Label.

File: C:\Users\Matt\Documents\My Games\Ironclad Games\Sins of a Solar Empire Rebellion\Mods-Rebellion v1.031 Dev\Real Space\GameInfo\BuffHeatGiver.entity
Label: periodicAction
Line Number:60
Line Contents: targetFilter

and so on and so forth with the same error up till line 69.

 

Now, in my previous experience this has generally been accompanied by another error which included an invalid value type at some point, confusing the game and making it read the rest of the file in a way that was unexpected. This time, there is no such error. Only "Text FileArchive missing Label".

 

Here is the file it is throwing the fit over:

http://pastebin.com/P56zSamq

 

If anyone has any suggestions on what has gone wrong, I'd love to hear them.

Thanks.

5,693 views 4 replies
Reply #1 Top

That is the most basic syntax error, which means your file is missing crucial lines. When making new files you must be very careful when adding or removing lines, as just one mistake can prevent the game from reading the file structure correctly.

Its also the easiest error to fix, since it tells you what line it was expecting to find. For Example...

Label: effectInfo
Line Number:58
Line Contents: targetFilter
End of quote

The game was looking for an effectInfo block but found a target filter block instead. ApplyBuffToSelf instant actions (and most variants) and several other ones require effectInfo blocks in their structure. Add one and it should fix the problem.

Reply #2 Top

Alright, after a bit of screwing around with adding and removing a lot of stuff finally managed to fix that problem, Thanks Gao.

Is there a specific line or buff type that requires an effect, as many buffs don't, yet obviously some - like this one - do, and I have not yet recognized a pattern.

 

Also, a few questions on what can be accomplished with buffs:

Is there a type of buff, or chain thereof, that boosts a ship's acceleration without affecting deceleration? [Or if the buff used by Sprint does only affect Acceleration is there a way to change Deceleration?]

Is there a type of buff that removes other specific buffs, and if yes can you limit it to only removing a certain number of stacks of said buff per use of that buff?

Is there a way to set up buffs so that a ship gains acceleration speed when moving towards an entity, but not when moving away [And if possible loses acceleration when moving away]?

Is there a way to apply a buff to a killing ship? [I.E: Ship A kills ship B, ship B has an ability that adds a buff to ship A. I could probably do this with two abilities, but I'm trying to make sure I stay under the 5 per entity limit].

 

Once again, thanks for any help.

Reply #3 Top

Quoting Joccaren, reply 2
Is there a specific line or buff type that requires an effect, as many buffs don't, yet obviously some - like this one - do, and I have not yet recognized a pattern.
End of Joccaren's quote

It depends how the buff type is set up. Best way is to look at an in game file that uses that buff type for reference. Personally I use Zombie's Eclipse plugin that would tell me if I miss a block like that, but that's probably overkill just for basic problem like this.

Quoting Joccaren, reply 2
Is there a type of buff, or chain thereof, that boosts a ship's acceleration without affecting deceleration? [Or if the buff used by Sprint does only affect Acceleration is there a way to change Deceleration?]
End of Joccaren's quote

I do not believe you can change Deceleration except the default value in the entity file in the ship. Thus just using the Acceleration modifier (its called linear thrust or something like that) should work.

Quoting Joccaren, reply 2
Is there a type of buff that removes other specific buffs, and if yes can you limit it to only removing a certain number of stacks of said buff per use of that buff?
End of Joccaren's quote

There is RemoveBuffOfType or AddOrRemoveBuffOfType (I'm not using quotes so they might not be spelled exactly that way). I think RemoveBuffOfType Removes all buffs of a given type though, while AddOrRemoves adds the buff if present and removes it if not, so you could only have 1 stack of it. I know this was a pain to several other modders as well...

Quoting Joccaren, reply 2
Is there a way to apply a buff to a killing ship? [I.E: Ship A kills ship B, ship B has an ability that adds a buff to ship A. I could probably do this with two abilities, but I'm trying to make sure I stay under the 5 per entity limit].
End of Joccaren's quote

I have made an ability like this, but if its very important it works... imperfectly. I set it up so that a buff is applied to a target on weapons fire. The buffs lasts for a few seconds, and has an "ApplyBuffToLastSpawner" set to trigger OnOwnerDeath, with a stacking limit of 1 and PriortizeNewBuffs. This ensures only the last target to fire on this ship has the buff, and if the ship dies it applies a buff back to the ship that kills it. Problem is, if you have other ships not using the ability, if they fire at the same time the ship with the ability will get the kill, even if the other killed it. Also if the ship was killed by an ability it might also misfire.

Reply #4 Top

Quoting GoaFan77, reply 3

It depends how the buff type is set up. Best way is to look at an in game file that uses that buff type for reference. Personally I use Zombie's Eclipse plugin that would tell me if I miss a block like that, but that's probably overkill just for basic problem like this.
End of GoaFan77's quote

Hrrm. The buff that I'd copies as a template for the one I'm using didn't have it, which was the reason I didn't include it in the first place. I guess the Dev.exe will probably be what'll help me there, though I might look for Zombie's Eclipse if its updated for Rebellion.


Quoting GoaFan77, reply 3

I do not believe you can change Deceleration except the default value in the entity file in the ship. Thus just using the Acceleration modifier (its called linear thrust or something like that) should work.
End of GoaFan77's quote

I had been hoping that there was some way to affect deceleration and acceleration, though independently, and its kinda a shame that the default value is all it will ever be.

I remember looking at the Guardian's repulse ability some time during diplomacy in the entity files, and seeing it as being able to set the minimum and maximum speeds for a ship. If one were to leave the maximum as a positive number, and the minimum as a negative, when decelerating would a ship continue to do so until it hit that negative value, or only until it became stationary?

Quoting GoaFan77, reply 3
There is RemoveBuffOfType or AddOrRemoveBuffOfType (I'm not using quotes so they might not be spelled exactly that way). I think RemoveBuffOfType Removes all buffs of a given type though, while AddOrRemoves adds the buff if present and removes it if not, so you could only have 1 stack of it. I know this was a pain to several other modders as well...
End of GoaFan77's quote

Slightly problematic, though since the buffs I'd want to remove would be simple stat editing debuffs I could probably counter that by applying an opposite buff with equivalent stat boosts to what the number of buffs I'd like to 'remove' would add to right?

And just to check, the way Sins works out that sort of stuff for its bonuses/detriments is that the value = (1+[Bonus Percent as Decimal])/(1+Detriment Percent as Decimal])  Correct?

If so, this does mean that were I to apply a 20% debuff, then a 20% buff to said stat, it would end up still being equivalent to its normal value, as opposed to its normal value -20%, then 20% of that new value added on [I.E: 100 - 20% = 80. 20% of 80 = 16. Therefore 80+20% = 96 instead of 100 if a 20% debuff is applied then a 20% buff whilst the debuff is still in effect].


Quoting GoaFan77, reply 3
I have made an ability like this, but if its very important it works... imperfectly. I set it up so that a buff is applied to a target on weapons fire. The buffs lasts for a few seconds, and has an "ApplyBuffToLastSpawner" set to trigger OnOwnerDeath, with a stacking limit of 1 and PriortizeNewBuffs. This ensures only the last target to fire on this ship has the buff, and if the ship dies it applies a buff back to the ship that kills it. Problem is, if you have other ships not using the ability, if they fire at the same time the ship with the ability will get the kill, even if the other killed it. Also if the ship was killed by an ability it might also misfire.
End of GoaFan77's quote

Thankfully the system I'll be trying to implement this for isn't too important, so it shouldn't matter if it misfire's occasionally. Thanks for explaining how to make such a system though.

 

A few more questions I've come up with:

- Is there a way to apply a buff on weapon impact, as opposed to weapon firing? If not, does weapon firing take into account the chance to miss, or does that only end up being a glorified DPS reduction?

- Is there an easy way to have a buff apply different effects to ships of different races, or would I have to take a roundabout route like applying a buff from production factories and construction ships that would place a 'marker' buff that allocates each ship to the race that created it?

- Is there any way to get fighter movement to even remotely work on Capital Ships?

Also, after the 1.04 update I've started to receive a couple of new errors that I'm not entirely sure how to deal with:

 

[Assert @ C:\Projects\P4\SinsRebellion\main\CodeSource\Engine/String/StringLibrary.h(83)

result == 1]

Which only occurs to the game when I attempt to run it with my mod enabled, or attempt to enable my mod whilst running the game, which rules out my original thoughts that Rebellion might have updated incorrectly [Like it had previously, and deleted several files that I had to copy across from Harpo's reference files to get it working] seeing as it says its an engine error of some sort, or seems to imply such.

The other error is:

[Entity Ref not found: RESEARCHSUBJECT_SHIPBOARD_LABS_2]

Which also only occurs when I attempt to load my mod. The thing is, I cannot think of any files I have that would need to reference it in my mod. I have one TEC capital ship entity file, a bunch of planet files, three abilities, 6 buffs and the entity.manifest.

I would assume that the entity.manifest is where this error will come from, though I'm not sure whether its saying that I don't have that entity referenced in the entity.manifest, or if its in the entity.manifest but not in the game. Some clarification on that would be much appreciated.

 

Again, thanks for any help.