PDA

View Full Version : Modding SEV Thread Questions


Pages : [1] 2

Kana
September 18th, 2006, 08:12 PM
Might as well start asking questions, and getting answers, so that we can easily start putting together the mods that will make SEV a great game. I ask that you bold your question, normal type any other explanation or text, and if you have an answer please Quote the Bold, and then Italics your answer.

Thanks...

Kana
September 18th, 2006, 08:14 PM
Can you pick different models for each level increase in a ship class?

This would facilitate the improvement and upgrade of certain vessel classes. A Frigate from WW1 is completely different from a Frigate of modern times. Or another example would be like the progression of a the Enterprise in Star Trek, from the TV version to the Movie version.

Jarena
September 18th, 2006, 08:33 PM
Kana: I don't want to think about how much work that would take to make a complete shipset. Even if it is possible, I don't think you'd find much support.
My question:

Can you impliment action-specific experience types?

I was looking through experience types earlier, and noticed a lot of different catagories. This may be a well-documented feature I've just missed, but I think it would be cool if, say, after n kt of damage towards a planet, a ship gains a "seige experience" modifier. Or picks up "green/experienced/veteran Sniper" after n# successful beam hits.
Something like that.

jowe01
September 18th, 2006, 09:20 PM
Are there any overarching scaling factors for building prices and maintenance somewhere in the text files?
In SE4, I always found that the price of ships was much too low compared to their maintenance cost(or maintenance too high comp. to building cost), meaning that it did not sufficiently hurt to loose a ship. Basically, every 4 turns you paid the building price again through maintenance cost. Why bother to bring back a damaged ship to repair, when during the time you drag it to a shipyard, you spend more resources than it would take to build a whole new ship?
Therefore, I approximately doubled the building cost and time for all hulls and components and halfed maintenance cost. However, while cutting maintenance in half was very easily done in the SE4 text files, doubling production cost requires touching every single hull and component - several hours of work each time a major patch came out.

In SE5, is there a general scaling parameter for production cost, too?

bearclaw
September 18th, 2006, 09:46 PM
Is there a master list of all abilities/restrictions for SEV like SEIV's Abilities.txt file?

Phoenix-D
September 18th, 2006, 09:48 PM
Kana said:
Can you pick different models for each level increase in a ship class?

This would facilitate the improvement and upgrade of certain vessel classes. A Frigate from WW1 is completely different from a Frigate of modern times. Or another example would be like the progression of a the Enterprise in Star Trek, from the TV version to the Movie version.



Can't be done.

You could however make new ship classes available, but you'd have a very cluttered ship design screen.

Fyron
September 18th, 2006, 09:53 PM
jowe01:
You know, with a simple python script, you could double all costs in SE4 in a matter of seconds. See attached file. You will need Python 2.4 installed to run it.

For SE5, it would have to be a little more complex to handle formulas, but that will be easy enough to do.

Of course, it will indiscriminately double unit component costs as it is, but there are a lot of components that can be used on ships, satellites, and drones in stock.

Noble713
September 18th, 2006, 10:30 PM
Can anyone decifer the weapon damage and range formulas?

I'm referring to stuff like this:

Weapon Space Min Damage Modifier Formula := (5 + (([%Level%] - 1) * 2)) - iif([%Range%] > Min(30, (([%Level%] - 1) * 20) + 10), 10000, 0)

I'll try to explain my understanding, taking it piece by piece:
(5 + (([%Level%] - 1) * 2)) Gives a damage rate based on the level of the component.

Min(30, (([%Level%] - 1) * 20) + 10) Compares a number to the value of a function based on the weapon level and returns the lower of the two?

- iif([%Range%] > ..... ,10000, 0) If the range is greater than the value returned above, return 1st number. Otherwise return the 2nd number?


Geesh. I think I'm going to need Excel graphs to tweak damage formulas for my mods.

StarShadow
September 18th, 2006, 10:38 PM
Translastion (please correct me if I'm wrong)

Assume a level 1 weapon..

damage = (5 + (1 - 1) * 2) = 10 (with 0 damage past range 30)

The damage I have almost no trouble with, but I'm not too sure of anything after the 'iif' statement.

Fyron
September 19th, 2006, 12:22 AM
The given formula is for a weapon without any range attenuation, so I will instead use this one:

Weapon Space Min Damage Modifier Formula := (55 + (([%Level%] - 1) * 5)) - (([%Range%] / 10) * 5) - iif([%Range%] > Min(90, (([%Level%] - 1) * 4) + 50), 10000, 0)

=0=

iff(CONDITION, a, b) means:

If CONDITION is true, do a. Otherwise, do b. It is a messy way to put:

if (CONDITION) {
do a
}
else {
do b
}

Sadly, it is the only way to do that when your entire "formula" has to fit on a single line.

Min(x, y) is a function that returns whichever value is smaller, x or y.

=0=

Now to look at the formula:

(55 + (([%Level%] - 1) * 5)) - (([%Range%] / 10) * 5) - iif([%Range%] > Min(90, (([%Level%] - 1) * 4) + 50), 10000, 0)

The first part is pretty straightforward:
(55 + (([%Level%] - 1) * 5))

This evaluates to 5 plus 2 times one less than component level. This part is the base damage value, the damage at range 0.

The next part is the damage attenuation rate (aka: damage reduction over range).

- (([%Range%] / 10) * 5)

For every 10 units of distance, subtract 5 damage.

The last part, the big iff, is the max range setting.

- iif([%Range%] > Min(90, (([%Level%] - 1) * 4) + 50), 10000, 0)

In this case, we have:

CONDITION = [%Range%] > Min(90, (([%Level%] - 1) * 4) + 50)
a = 10000
b = 0

When the range to the target gets larger than a certain value, 10000 will be subtracted from the damage value. This effectively cuts off damage at that range, due to negative value handling.

The CONDITION is the part that is determining the max range; it is the minimum of 90 or (([%Level%] - 1) * 4) + 50). Thus, every instance of the weapon will have at most a range of 90. The second value that we compare 90 to is the range increase via tech levels. It is 50 plus 4 times one less than the level of the component. Isn't that nice wording? hehe.

This breaks out to the following ranges at tech levels:

1: 50 + 0 = 50
2: 50 + 4 = 54
3: 50 + 8 = 58
4: 50 + 12 = 62
5: 50 + 16 = 66
...
10: 50 + 40 = 90
11: 50 + 44 = 94

Note that level 11 gets a value greater than 90, so the Min function call forces the max range down to 90.

StarShadow
September 19th, 2006, 12:29 AM
My head hurts...

Phoenix-D
September 19th, 2006, 12:34 AM
Would this be a bad time to point out that as weapon forumlas go, that's going to be on the SIMPLE end? http://forum.shrapnelgames.com/images/smilies/laugh.gif

Captain Kwok
September 19th, 2006, 12:52 AM
There's actually a number of different ways to construct the formula for the case Fyron used as an example, but when you're sticking in the level and range variables, it always looks messy. But really it's easy. There's the default damage value and the amount that it increases per level; the attenuation; and lastly the range.

----

Bearclaw - There are files that describe the abilities etc., but I think they're only partially complete at this time.

----

Are there any overarching scaling factors for building prices and maintenance somewhere in the text files? - From your examples, instead of doubling build rates, why not just make maint even less like 1/12 or 1/16?

Fyron
September 19th, 2006, 12:54 AM
How about a quick and dirty formula builder app? It requires .NET Framework 2.0.

http://www.spaceempires.net/files/temp/se5_dmg_builder.zip

StarShadow
September 19th, 2006, 12:57 AM
Oh sure...you give me a headache THEN you go and release a simpler way...*takes 2 advil and glares at the screen* http://forum.shrapnelgames.com/images/smilies/Sick.gif

Fyron
September 19th, 2006, 01:12 AM
I have uploaded a better version that uses number boxes instead of text boxes. I set the limits to 1000, figuring only a totally crazy person would go that high... http://forum.shrapnelgames.com/images/smilies/happy.gif

http://www.spaceempires.net/files/temp/se5_dmg_builder.zip

Phoenix-D
September 19th, 2006, 01:22 AM
Except now you can't put in exponents, etc. http://forum.shrapnelgames.com/images/smilies/happy.gif

jowe01
September 19th, 2006, 02:40 AM
Thanks Fyron. Now Python is completely new for me (actually I have not written a program or a macro in 20 years). Where can I get it? Any good newbie documentation you know of?

Fyron
September 19th, 2006, 07:30 AM
http://www.python.org

The official docs on that site are rather good, I find. The great thing about Python is that it is powerful like C++, but designed to have good, well-defined and easy to follow syntax (much better than any Basic attempt for this, IMO). One of the primary design goals was making it easy to learn and use, in fact. http://forum.shrapnelgames.com/images/smilies/happy.gif

jowe01
September 19th, 2006, 01:28 PM
Thanks, I give it a try. However, that address does not seem to work, at least not right now.

Puke
September 19th, 2006, 01:32 PM
bearclaw said:
Is there a master list of all abilities/restrictions for SEV like SEIV's Abilities.txt file?



I saw references to one in some of the data files, so its probably safe to say that one exists but is excluded from the demo.

Kana
September 19th, 2006, 04:25 PM
Can there be more than 17 or 16 different ship/unit pictures in the Empire/Shipset Files?

First off I noticed a 1 image difference between the Ship Set, and Vehicle Main Textures bmp. What I wanted to know, are the sizes of the bmp's set in stone, what if we want to add more vehicle models to the shipset/empire? From viewing the Empire style example on MM, it doesnt appear so.

Ship Set--[Empire Name]_ShipSet.bmp--378x84(each picture is 42x42)

Vehicle Main Texture--[Empire Name]_Vehicle_Main_Texture.bmp--256x256 (each picture is 64x64)

Unit Combat Texture--[Empire Name]_Unit_Combat_Texture.bmp--256x256 (each picture is 128x128)

Phoenix-D
September 19th, 2006, 05:01 PM
Yes, they can.

All those files seem to be able to be lengthed in a manner similar to components.txt in SE4. That is, you can make them longer, but not wider.

Kana
September 20th, 2006, 03:00 AM
Can you target an incoming Beam or Bolt based weapon with an effect?

I was going through the data files, and I noticed that there was a listing of valid targets, like ship, or seeker for instance, but it also said beam and bolt.

What is the difference between Torpedo and Directed Torpedo?

From what I can tell it looks like Directed is seeking, and Torpedo is like direct fire.

Can Shields use supplies?

Do the Formations for the Fleets and Task Forces determine the max number of ships per fleet?

From looking at the formations data file, it shows one formation for fleet as a max of 40 ships, and one for task forces at 74. I was hoping that you could use this to possibly control the total size of any fleets being used.

With out Multiplex Tracking, Do all weapons that can fire from an individual ship fire at the target?

Wont this result in serious overkill of certain ships...?

StarShadow
September 20th, 2006, 03:26 AM
Re: Multiplex Tracking

I'm kind of wondering that too. In SEIV all direct fire shots were instant hit and your weapons fired in sequence, if weapon 4 (out of, say 10) was a kill, weapons 5 - 10 would find a new target. In SEV since combat is real-time, and most direct fire weapons actually have travel-time (the beams aren't so bad, but it's quite noticable with projectile weapons)..it looks to me like ships just completely unload at one ship after another, resulting in some amazing over-kills, unless you micro-manage your combat (ie. tell your ship to fire weapons 1-4 at ship A and weapons 5-10 at ship B, etc).

Puke
September 20th, 2006, 04:10 AM
i think its all configurable in the stratigies. like this:

Targeting Priority 2 := Total Targeted Damage < 150% of Structure

and like this:

Target Type 1 Damage Amount := 100%

and you can configure strategies to be specific to the type of object being engaged. so you might choose to engage a carrier at a diferent range than a sphereworld. and that iss pretty snazzy.

Suicide Junkie
September 20th, 2006, 08:30 AM
Multiplex is basically infinite due to the real time nature.

You simply have to set your strategies to not fire overkill, so instead of 150%, ask for a much smaller percentage for targetting.

Your ships will still opportunity fire at non-priority stuff that comes into range.

StarShadow
September 20th, 2006, 01:06 PM
Maybe I'm not understnding what you're saying (Suicide and Puke), but I think you're still going to get over-kill. For example, in my latest game I have a destroyer with unmounted lvl 100 meson blasters (5 of them) guarding a warp point. Those things do over 600 points of damage, one hit is all that's needed to kill any enemy ship, but if several ships come through the warp, my ship still fires all 5 at each ship, one after the other. That is VERY inefficient and (in theory) exposes my ship to much more harm than it should. I expect it works likes this:

.Target in range
.Weapon1 fires..projectile inbound
.Check target..no damage (projectile hasn't reached it yet)
.Weapon2 fires..projectile inbound
.Check target..no damage (projectile hasn't reached it yet)
.Repeat for weapon 3 to 5

I think the problem is the travel-time for projectiles. If they were instant hit it would be much better (in my opinion), because your ship could find a new target after each kill, instead of unloading all weapons at them, one at a time.

.Enemy ship in range..
.Weapon1 fires..enemy ship hit..enemy ship destroyed
.New target..enemy ship in range..
.Weapon2 fires...target hit..target destroyed
.And so on..

Arralen
September 20th, 2006, 01:36 PM
Is there a way to reduce system size?

I already found in "settings.txt"
<font class="small">Code:</font><hr /><pre>
System Width In Hexes := 26
System Height In Hexes := 20
</pre><hr />
Someone here suggested 20x15, but that crashes the demo. Even 24x18 looks oddly, as if some 'radius' or 'cropping range' is missing or too big - the systems start looking 'squared' at 24x18 again, the 'corners' too much filled up ..
Is it by chance "System Point Radius From Center := 410.0" .. dunno what to do with a point range here, though http://forum.shrapnelgames.com/images/smilies/frown.gif


Is there a way to reduce the chance for nebula sectors?


Thanks!

Captain Kwok
September 20th, 2006, 01:40 PM
To use 20x15 hexes, you need to edit the SystemTypes.txt file so that no items are placed beyond ring 7 - that is what causes the crash.

When changing the system size, multiple the radius by the factor you change the size by. For example, 20/26 is ~ 75%, so the radius should be 315 etc.

You'd need to edit QuadrantTypes.txt to reduce the occurence of nebulas.

Suicide Junkie
September 20th, 2006, 06:38 PM
The way it should work is;
Target has X Hitpoints, figure in overkill %, figure in hit chance, etc. So, Y guns should be enough.

Weapon 1;
Fire on target

Weapon 2;
Fire on target

Weapon Y+1;
Too many guns targetted, skip.


If there are no other targets in range, the ship may just fire the rest because it can.

StarShadow
September 20th, 2006, 07:08 PM
Hmm..I'll pay closer attention in my next set of combats.

"If there are no other targets in range, the ship may just fire the rest because it can. "

That I don't like. Just because there are no targets in range *now*, doesn't mean no targets will present themselves soon (ie before the wastefully discharged weapons can refire/reload). This could be a particularly bad thing for weapons with long reload times.

Noble713
September 20th, 2006, 08:34 PM
In damagetypes.txt if you list multiple requirements how do you make them Req 1 OR Req 2 instead of Req 1 AND Req 2?

So if I set a damage type to destroy engines and weapons, will it destroy only components that are BOTH an engine and a weapon?

Is there no way to add a special damage type (i.e. deplete supplies) to an otherwise normal weapon?

The instructions imply that any weapon with a "Special" function skips the normal damage allocation process. I want a weapon that does both.

StarShadow
September 20th, 2006, 08:37 PM
@SJ

Ok, I think I see what you mean, I was just looking through settings.txt again and noticed:

Estimated Targeting Damage Percent for Torpedo Weapon := 50
Estimated Targeting Damage Percent for Directed Torpedo Weapon := 50
Estimated Targeting Damage Percent for Beam Weapon := 50
Estimated Targeting Damage Percent for Bolt Weapon := 50

I still think my second point is valid though..

Arralen
September 22nd, 2006, 05:02 AM
How does the AI build its ships?

From what I've seen, the AI uses 'fixed' scripts instead of general algorithms and the component properties to build its ships:

If you change the "possible placements" from "Inner Hull, Outer Hull" to "Outer Hull, Outer Hull" (only "Outer Hull" is not accepted by the demo at least) for the basic scanner, the player can only place the scanner into outer hull sections.

The AI however does not use scanners at all in that case - looks like it has a 'build list' which does not order 'scanners' in general, but 'scanners in inner hull'.
Maybe this was bad luck, though - the designs I saw had completely filled outer hull on the upper deck, maybe the scanner came last and simply didn't fit :/

If the AI really uses those fixed lists, I wonder if its possible to do any *greater* mod at all ...

Suicide Junkie
September 22nd, 2006, 05:07 AM
I do agree that strategies will need some more power.

The situation is much improved if weapon damage is relatively small and hitpoints are increased.
In GGmod, there are often lots of ships left crippled, and then cleaned up later by the eventual victor if no enemy reinforcements arrive.

Captain Kwok
September 22nd, 2006, 07:52 AM
You're correct in noting that the AI design algorithm has fixed places (outer, inner) where they stick items.

Rellep
September 22nd, 2006, 08:27 AM
How exactly does scaling work? Setting "Starting Scales" in *_Ships_XFileClasses works as one would assume, but what does Base Model Radius mean? And Maximum Model Size in VehicleSizes? I swapped the numbers for frigate and (light) fighter, and got miniature frigates and gigantic fighters. But Baseships (at least) won't scale, no matter how low the MaxMdlSze. And frigate MaxMdlSze scaling also appeared to not work after I increased their Starting Scales to 1.00 (from 0.01... hehehe)

I was going to use scaling for additional ship sizes in my mod when no own models exist (such as the default shipsets), but is there really no other way then painfull modification of *_Ships_XFileClasses' for all shipsets?

Kana
September 26th, 2006, 03:34 PM
Can you change the range breaks

Instead of 10, 20, etc. Can it be 1, 2, 3, etc? Or something to that effect? How does it effect the combat model? Or is this all hard coded?

Phoenix-D
September 26th, 2006, 03:38 PM
There are no range breaks; that's display-only..

Weapon damage is determined by a formula; as far as I can that uses the exact range the weapon is at, and doesn't break down by 10s. No idea how to change the display part though.

Kana
September 26th, 2006, 04:10 PM
Phoenix-D said:
There are no range breaks; that's display-only..

Weapon damage is determined by a formula; as far as I can that uses the exact range the weapon is at, and doesn't break down by 10s. No idea how to change the display part though.



But the display also shows the to hit modifers, and I would assume that is based on formulas as well, based on range and damage? Then the display would not show accurate info...

Kana
September 26th, 2006, 04:11 PM
Can Formula's be used in any field, or are they restricted to certain hard-coded fields?

Phoenix-D
September 26th, 2006, 04:20 PM
Kana said:

Phoenix-D said:
There are no range breaks; that's display-only..

Weapon damage is determined by a formula; as far as I can that uses the exact range the weapon is at, and doesn't break down by 10s. No idea how to change the display part though.



But the display also shows the to hit modifers, and I would assume that is based on formulas as well, based on range and damage? Then the display would not show accurate info...



To-hit modifiers have their own line for a seperate formula. Range and damage get tossed into the same forumla. The display will always be in what it tells you- it just may not always give *useful* information (eg if all your weapons have a range between 1 and 10, only the very first box will be filled in..I think.)

Kana
September 26th, 2006, 04:22 PM
Phoenix-D said:

Kana said:

Phoenix-D said:
There are no range breaks; that's display-only..

Weapon damage is determined by a formula; as far as I can that uses the exact range the weapon is at, and doesn't break down by 10s. No idea how to change the display part though.



But the display also shows the to hit modifers, and I would assume that is based on formulas as well, based on range and damage? Then the display would not show accurate info...



To-hit modifiers have their own line for a seperate formula. Range and damage get tossed into the same forumla. The display will always be in what it tells you- it just may not always give *useful* information (eg if all your weapons have a range between 1 and 10, only the very first box will be filled in..I think.)



Grim... http://forum.shrapnelgames.com/images/smilies/fear.gif

Phoenix-D
September 26th, 2006, 04:24 PM
I don't know for sure if the display can be changed or not..

Captain Kwok
September 26th, 2006, 04:45 PM
Fields that can use formulas are labeled "Blah blah Formula".

This line details the "range blocks":
Weapon Space At Range Distance Increment := 10.0

If you were to change this to 1.0 and had a weapon go to 9 range, it would likely fill up the first row of range boxes (which would still read 10...90 since they are just a .bmp image).

There's a couple of ways to modify accuracy.

This line can change the rate that accuracy changes at range.
Weapon Space To Hit Modifier Formula := 0 - ([%Range%] * 0.5)

The above example would have accuracy decrease at half the range. That is at 50 range, it would have -25% penalty.

Alternatively you can change this value:
Weapon Space To Hit Modifier Formula := 25.0

Which adds a blanket 25% to hit at all valid ranges.

Kana
September 28th, 2006, 02:00 AM
Captain Kwok said:
Fields that can use formulas are labeled "Blah blah Formula".



This is good to know, and after looking at the data file, I noticed that what I was worried about actually has a Blah Blah Formula label...now the question is find the right formula, and syntax of formula to get what I want...

Basically I was looking for the Plasma Torpedo, from SE3, and Star Fleet Battles. The PT tracks like a seeker, and starts out with a set amount of damage, which decrease in range blocks the longer it takes to get to the target, but can be shot by beam weapons to decrease the damage it does. So basically the structure/HP of the seeker is equal to the current damage of the torpedo.

Weapon Space At Range Distance Increment := 10.0
Weapon Space Min Damage At Range := 0.0
Weapon Space Max Damage At Range := 0.0
Weapon Space Min Damage Modifier Formula
Weapon Space Max Damage Modifier Formula
Weapon Seeker Tonnage Structure Formula
Weapon Seeker Defense Modifier Formula

I figure between all of these I can mod it to get what I want...just have to figure out how...

Phoenix-D
September 28th, 2006, 02:08 AM
Everything except the last part is doable.

I'm not entirely sure if you can tie the fields together like that..

Ed Kolis
September 28th, 2006, 11:33 AM
In SE2 seekers by default lost damage potential as they were damaged... I wonder why Aaron took that out http://forum.shrapnelgames.com/images/smilies/tongue.gif

MasterChiToes
September 28th, 2006, 01:18 PM
Sorry to stretch the thread topic... but has anyone had any luck with planet textures? (in the models directory)
I've made several of them (256x256 24bit bmps) but for some reason they all crash the game when the minimap is used to switch to a system containing the new planet texture. I can't tell if I have the format wrong, if this is bug related, or if there is some tricky requirement for the texture designs.

Captain Kwok
September 28th, 2006, 01:25 PM
I have made a few that have worked fine, but I was lazy and copied over existing textures.

How did you go about adding it?

Q
September 28th, 2006, 01:25 PM
Minesweeping seems still identical to SE IV but as far as I understand you can create new units and the mine-sweeping component has this ability:

Ability 1 Type := Units - Sweeping
Ability 1 Description := Can sweep [%Amount2%] mines per use.
Ability 1 Scope := Space Object
Ability 1 Range Formula := 0
Ability 1 Amount 1 Formula := "Mine"
Ability 1 Amount 2 Formula := 2 + (([%Level%] - 1) * 5)

So could you create "supermines" which can't be swept by the normal minesweeping component but only by the "superminesweeping" component (replace "mine" in the above formula by "supermine")??
That would be absolutely great as mines could be made useful even for later games!

MasterChiToes
September 28th, 2006, 01:31 PM
I also copied over existing textures (backing up the original of course). The new textures are the same size (192KB) and work fine when I switch to the system using the Planet menu... but when I switch to the system using the minimap, I get the endless loop of popping up errors over a white screen.

Phoenix-D
September 28th, 2006, 02:34 PM
You could definitely do that, Q. I think you can also make a component that "sweeps" FIGHTERS, not that it makes any sense. http://forum.shrapnelgames.com/images/smilies/tongue.gif

Kana
September 28th, 2006, 06:15 PM
Phoenix-D said:
Everything except the last part is doable.

I'm not entirely sure if you can tie the fields together like that..



Well if the 'formula' lines can take any formula with the right syntax...I see it as being possible. Basically the health/structure remaining would be equal to the remaining damage, so you should be able to use the same formula, that the range to damage ratio would be using...Or at least I hope it can be...Question is I dont think you can decrease the damage done by damaging the health/structure, unless we can make a formula that can loop back the remainder to the range/damage line.

aegisx
September 30th, 2006, 10:32 AM
What is the deal with the csf files? Will they be moddable by the players?

Mephisto
September 30th, 2006, 11:17 AM
The .csf-files are the compiled script files. You will be able to compile them with the included editor.

aegisx
September 30th, 2006, 11:32 AM
Neat, what do the 2 that are there do now?

Captain Kwok
September 30th, 2006, 12:40 PM
If you are referring to the events and intel scripts in the data folder - they are just the compiled scripts for random events and intel projects.

Kana
September 30th, 2006, 03:00 PM
I was taking a look at the data files again today, and was looking at the damage types.txt file. It seems that a leaky shields/leaky armor option can be implemented by just typing in a penetration percentage for each damage type you are using.

Damage Type Name := Skips Normal Shields
Description := Damage which skips normals shields but will be stopped by other kinds of shields.
Picture Number := 32
Cannot Penetrate Any Kind Of Shields := FALSE
Cannot Penetrate Any Kind Of Armor := FALSE
Number Of Vehicle Types := 0
Number of Shield Types := 1
Shield Type 1 Name := Normal Shields
Shield Type 1 Penetration Percent := 100
Shield Type 1 Damage Percent := 0
Number of Armor Types := 0
Internal Damage Percent := 100
Facility Damage Percent := 100
Population Amount Killed Per Damage Point := 0.25
Crew Amount Killed Per Damage Point := 0
Is Viral Weapon := FALSE
Number Of Special Effects := 0
Number Of Requirements := 0
Number Of Abilities := 0

With the 3 entries above, I think there will be many possiblities...I now have more hope for my SFB mod as well...

Captain Kwok
September 30th, 2006, 03:04 PM
Even better now is that as a weapon increases with technology, you can have it do different damage types. For example, increasing penetration vs. armor, etc.

Kana
September 30th, 2006, 03:06 PM
Captain Kwok said:
Even better now is that as a weapon increases with technology, you can have it do different damage types. For example, increasing penetration vs. armor, etc.



I assume we can do this my making certain restrictions and qualifiers...based on the the level of weapon tech in relation to the damage ability?

NM, I assume you mean just by the damage formula, and the level adding an amount by level...

aegisx
September 30th, 2006, 03:31 PM
Looks like the csf files handle alot for the AI's. Hopefully there are alot of functions exported to the scripts. If so, you should be able to do alot.

aegisx
September 30th, 2006, 03:51 PM
Also, if you turn on the scripting debug printout, it shows alot of what you can do.

Phoenix-D
September 30th, 2006, 04:51 PM
Yep. Check out the top of the damage type file- it specifies exactly how the damage routine works.

reen
October 1st, 2006, 09:08 AM
Is it possible to mod a crew factor to weapons, something like "phaser 5 -&gt; ship needs 50 more crew than without it"?

Suicide Junkie
October 1st, 2006, 10:28 AM
GGmod has that.

An empty hull requires no crew, but the bridge requires 5 crew, and the engines require a couple, and the guns require more. Fighter bays need quite a few techies too.

Lifesupport requirements are based on the crew capacity as well (IE: how many crew quarters you install).

The GGmod computers replace 30 crew each (reducing the lifesupport needed indirectly).
And aside from the basic crew quarters, there are gunnery quarters which give a bonus that applies only against weapons (Less crew per kt for general stuff, but the +50% vs weapon requirements is quite useful).

aegisx
October 1st, 2006, 11:10 AM
Can the GUI be modded in a way to show the crew requirements?

Suicide Junkie
October 1st, 2006, 06:03 PM
All unsatisfied requirements show up in the warnings list (top right)

Jarena
October 2nd, 2006, 01:27 AM
Throwing around mod ideas earlier today, and I came up with a few questions:

1) Can components support +ability per (whatever)? As in, could I have, say, Laser Beam I that does n damage per number of Battery Is on the ship? Or +morale per ships in fleet? Or +movement per stars in system? Anything like that?

2) I've seen this, I think, in some form when I was browsing the components.txt file. The Stupifier psychic weapon renders a crew bereft of experience for a time. Can this be expanded? I have two things in mind, one being (almost RPG-esque) "status ailments" - switch sides, lose engine power, defense down, weakened weapons, etc, all on a timer. Also, can I expand this to damage over time attacks? Say, 20kt of structural damage per second for 10 seconds on a successful hit.

3) components capable of system-wide buffs?

4) can ground defense weapons be added to facilities? Say, I build a Garrisoned Research Facility II that has three Ground Cannon IIIs for use in planetary battles - or even a non-component ranged attack used only by that facility.

5) I'm guessing this is possible, judging by the name of the file (componentenhancements.txt rather than weaponmounts.txt), but can "mounts" be extended to any component type? I know it was done in many IV mods, but I think SEV might have really fleshed out that system.

6) Am I missing an Abilities.txt file somewhere?

Thanks in advance

Fyron
October 2nd, 2006, 01:52 AM
2) Some of those damage types already exist. I don't think you can add such effects if they do not yet exist, though.

3) Sure, set the ability scope to system instead of object.

5) Yep. For an example, see my "mod out LCX as early warship" thread for a way to make a mount that applies to components with a specific ability.

6) Is there not a "Description_Abilities.txt" in the demo Data folder?

Kamog
October 2nd, 2006, 03:49 AM
No, the demo does not have the "Description_Abilities.txt" file. http://forum.shrapnelgames.com/images/smilies/fear.gif

Captain Kwok
October 2nd, 2006, 07:23 AM
None of the Description_X files were included in the demo...

Suicide Junkie
October 2nd, 2006, 10:48 AM
In case you think squares are boring:
http://www.shrapnelcommunity.com/threads/uploads/451082-Dlg_Combat_CommandBar_QuadMap.png

Suicide Junkie
October 2nd, 2006, 11:57 AM
http://imagemodserver.mine.nu/other/MM/SE5/Tools/SE4+5PopModifier.zip

Type in whatever formula you want, and press go!
Automatically Generates the Population Modifiers for your settings.txt

Jarena
October 2nd, 2006, 02:18 PM
I remember reading that someone said that Ringworlds take up a ring of six inner hexes (or something like that) I think it may have been Cpt. Kwok.
Dear sir, I ask of you two things:
Is this, in fact, true?
Also, will I be able to create my own with user-defined shapes and sizes?

Baron Munchausen
October 2nd, 2006, 02:46 PM
If you want to take the time and effort to create the 3D images, I don't know why you couldn't mod the game to use them.

Building ring and sphere worlds is messy now. You have to make sure everything is out of the way. It won't build if there is anything in the space it will occupy (base, ship, unit, etc.) so one enemy ship or unit can hold up your gigantic construction project.

Jarena
October 2nd, 2006, 03:49 PM
I would think I could impliment them as far as the .x file goes, but I'm wondering about the actual hex space it will take. If I make an object, could I assign it to a 2x4 hex area? or, say, an L-shape? Anything like that?
This ringworld thing has me excited enough as it is.

Kana
October 2nd, 2006, 07:15 PM
Things I found while going through the abilities section of main strings.txt:

Government Center -- Possible Palace type ability?
Multiplex Tracking -- Yes or No ??
Planet Colonize Type 4 and 5 -- There are only 3 in stock
Point Generation-Culture -- Is this morale or something else?
Warp Point - Periodic -- Sometimes its there, sometimes not?

Noble713
October 2nd, 2006, 07:50 PM
Suicide Junkie said:
GGmod has that.

An empty hull requires no crew, but the bridge requires 5 crew, and the engines require a couple, and the guns require more. Fighter bays need quite a few techies too.

Lifesupport requirements are based on the crew capacity as well (IE: how many crew quarters you install).

The GGmod computers replace 30 crew each (reducing the lifesupport needed indirectly).
And aside from the basic crew quarters, there are gunnery quarters which give a bonus that applies only against weapons (Less crew per kt for general stuff, but the +50% vs weapon requirements is quite useful).



Oooo, that's nifty. I think I'll have to steal your idea, if you don't mind.

Kana
October 3rd, 2006, 07:08 PM
Are there any high and/or low number restrictions in any of the fields?

In SEIV, there was the 65000, 255, and not less than 1 or a fraction problems. What is possible in SEV? Can I have numbers less than 1? Fractions? What is the largest possible number?

Noble713
October 3rd, 2006, 11:53 PM
I've heard that SE5 uses 32bit instead of 16bit strings, so the ~65000kT limit is effectively limitless. The number of systems is still limited to 255. As for fractions....I've seen a variety of numbers in the data files represented as decimals, but I don't know which fields you can use them for and which you can't.

Fyron
October 4th, 2006, 03:39 AM
A lot of places will accept decimals, but some still use ints. The armor penetration in damagetypes.txt, for example, treats all decimals as a flat 0. http://forum.shrapnelgames.com/images/smilies/frown.gif

Kana
October 4th, 2006, 04:51 PM
Abilities Added To Parent When In Cargo

This is attached to the Weapon Platform code in the Vehicle Unit Type.txt file. Now I assume this allows the WP to fire from the cargo space of a planet. Yet this doesnt seem specific, so if you loaded these on a cargo ship...

Could the WP fire from the cargo bays during space combat?

Phoenix-D
October 4th, 2006, 04:58 PM
Doesn't seem to work. If that ability works for ships I haven't found the way to make it work.

Ed Kolis
October 4th, 2006, 05:12 PM
Weapons fire is not an "ability"; it is a special attribute. A proper test would be to give troops this capability, then see if loading troops with Small Combat Sensors onto a ship increases the ship's to-hit. Of course, since to-hit isn't actually displayed anywhere in the UI, you'd have to get some pretty powerful combat sensors on your troops for testing purposes, but this is a useful idea for modding in "hero" units - give them an exorbitant build and/or maintenance cost and presto! http://forum.shrapnelgames.com/images/smilies/wink.gif

Phoenix-D
October 4th, 2006, 05:26 PM
True. However this IS an ability for that..
Can Fire Into Space From Ship Cargo

which is what I tested..

jimbob
October 5th, 2006, 11:06 PM
Ed, a fun technology would be genetic engineering. I've often thought it would be nice to be able to "engineer" subraces that do well with different atmospheres, etc. but the game just doens't support that.

However engineering individuals for specific occupations (ie super gunners with genetically engineered depth perception = better sensors, or super pilots with genetically improved spacial relations = better ECM) would be interesting.

Could you make units that have non-combat values and put them "in cargo" on a planet as governors?

Elsemeravin
October 7th, 2006, 09:39 AM
About sensors and cloaking, is there really now only one kind of cloaking/sensors ?
I mean compared to SEIV were you could mod 5 classes of cloaking/sensors...

Q
October 7th, 2006, 10:10 AM
Elsemeravin said:
About sensors and cloaking, is there really now only one kind of cloaking/sensors ?
I mean compared to SEIV were you could mod 5 classes of cloaking/sensors...



But in fact the 5 sensors in SE IV did all the same. You could mod them a little bit to make them more useful in combination but it was not a big deal.
I will be happy with only one sensor/cloaking type, if (and that is a big if) we can make range dependent.

Elsemeravin
October 7th, 2006, 10:20 AM
The truth is I was disappointed a little bit in SEIV has the sensor system was not really logical.
But I was thinking that if the following rule could be applied it could make things interesting:

A Sensor can detect a ship if at least one of its "sight" (as called in SEV it seems) for a "type" (if there would be several, using for example the Amount2 value) is higher than the cloak value (Amount 1 of cloaking component) of the same type.

Then the following scenarios could be created:
type 1 : mass
type 2 : spirit
type 3 : visual

Ship 1 has:
Level 2 type 1 cloak (small ship has little mass)
Level 4 type 3 cloak (almost-invisible ship)
Level 1 type 3 sensor (visual sight through space)

Ship 2 has:
Level 3 type 2 cloak (psychic crew shielding)
Level 3 type 2 sensor (psychic crew)
Level 1 type 3 sensor (visual sight through space)

Then we would heve:
Ship 1 can see Ship 2 (visual)
Ship 1 cannot see Ship 1
Ship 2 can see Ship 2 (visual)
Ship 2 can see Ship 1 (psychic)

Do you think that I should forget such objectives for SEV again (as happened with SEIV)?

EDIT: Well at least we got the range now. (Both range and types would have been perfect but range is better than types, I agree with you)

Elsemeravin
October 7th, 2006, 02:09 PM
Does anyone have an idea of the use of the following setting in the damage data file:

Number Of Vehicle Types

It isn't used in the demo (as with so many other settings...) and not talked about in modding threads (as much as I can say). http://forum.shrapnelgames.com/images/smilies/shock.gif

Considering that the list of available target is defined per weapon (in the component data file), I cannot see the use of this settings in the damage data file (but I guess something in someone's mind must have created this for a reason...) http://forum.shrapnelgames.com/images/smilies/confused.gif

Phoenix-D
October 7th, 2006, 02:13 PM
SEIV and SEV both have a lot of stuff in there that was planned, and not implimented. That might be one of those.

Otherwise..I have no idea.

Elsemeravin
October 7th, 2006, 04:43 PM
Yet another question:

It seems from the DamageTypes.txt file that the Crew Conversion is hardcoded not to be able to be applied on master Computer.
However it seems that using a requirement opposite of somethig like Does_Ship_Have_Component_With_Ability("Master Computer") would do the same except that it would be possible to mod it (like to make a virus affecting only master computer taking control of the enemy ship).

Do you know about this ? Is the requirmeent currently really hardcoded (legacy from SEIV?) ?

Desdinova
October 7th, 2006, 09:46 PM
is there any option to modify the max population of a planet as a racial trait similar to what can be done about cargo space. i found the Storage Cargo Space Percent and was shown the Storage Facility Space Percent abilities in mainstrings.txt but i see nothing that looks like i can increase max population in the same way. http://forum.shrapnelgames.com/images/smilies/confused.gif

Captain Kwok
October 7th, 2006, 11:47 PM
The Facility Space Percent ability works as you want to increase facility space and I've requested A Population Space Percent ability as well - hopefully that will come through.

Desdinova
October 8th, 2006, 09:42 AM
thanks. hopefully it will be added. http://forum.shrapnelgames.com/images/smilies/biggrin.gif
another question.
i figured out how to expand the system map size however i am having trouble placing planets beyond ring 10. they seem to end up all in the same hex as the sun. is the ring 1-10 a hard coded limit or did i miss changing something is settings.txt. i have the warppoints out around the outer 3 rings and asteroid belts beyond ring 10 (i think)

Kamog
October 8th, 2006, 01:47 PM
There is going to be a fix for that in the first patch.

Version 1.04:
1. Fixed - In SystemTypes.txt, the "Ring" position would not register rings 10 or above.

Fyron
October 8th, 2006, 01:50 PM
The ring limit (up to 16 in theory) is why I made my system resizing script convert everything to circle radius. It is attached to this post. It's a python script, and you will want to change the scale factor variable to the amount you are scaling the systems. You might have to fiddle a few times to get it just right, since SE5 will place systems outside the hex grid readily enough if you are not careful to make all positions inside it.

Kamog
October 9th, 2006, 02:25 PM
If you put an ability such as resource generation on a component, and put the component on a ship, will the ability continue to operate if you mothball the ship?

Barnacle Bill
October 11th, 2006, 06:17 AM
What governs the availability of an empire to include in a new game?

I created a mod for my own preferences (essentially just settings.txt) and basically copied the Terrans to a new name. OK, I start a new game with my mod and run some cheat codes to look at the state of the galaxy - all the usual suspects are there, even though I did not copy them to the "Empires" folder in my mod. That's not really a problem for what I want to do (except maybe I'd like to turn off the Terrans until I've made my own flags, etc...), but what if I was doing a Star Trek mod or something where I didn't want the stock SE races in the game? Is there a way to turn them off in a mod without editing the standard SE data structure?

Also, one of the neutral empires turned up with the same flag as the Terran one that I'm using (temporarily) on my race. Doesn't it check to see if a flag is already in use?

Captain Kwok
October 11th, 2006, 08:04 AM
The flag problem was corrected in a patch after the version 1.00 build.

The modinfo.txt file included with a mod can specify whether the default empires are added or not.

Q
October 11th, 2006, 08:24 AM
What are the minimum files needed for a mod in SE V?
Just the data files?

Captain Kwok
October 11th, 2006, 09:41 AM
You need a 192x192 image (can just copy the standard one) along with a modinfo.txt file. For the data files, you just need to include the ones you have modified.

Q
October 11th, 2006, 10:14 AM
Excellent, so you can easily create test-Mods, where you only change a few items.
Thank you for you answer Kwok.

Kana
October 11th, 2006, 04:35 PM
Captain Kwok said:
You need a 192x192 image (can just copy the standard one) along with a modinfo.txt file. For the data files, you just need to include the ones you have modified.



What image? Whats it do?

Phoenix-D
October 11th, 2006, 04:40 PM
Its just an icon that shows up when picking a game type in the main screen. You don't actually need it- if its not there SEV uses the default icon.

Captain Kwok
October 11th, 2006, 04:40 PM
It's the image displayed when choosing "Game Type". If you don't include one it might just use the default but I've never tried it.

Phoenix-D
October 11th, 2006, 04:45 PM
A few modding tricks:
If you have a lot of components, some of them might be obselete at high tech levels, and unlike SE4 it doesn't seem like you can get rid of them.

But this isn't correct. http://forum.shrapnelgames.com/images/smilies/happy.gif All components take formulas for their requirements, and those accept "less than" as an option. So you can make a component that disappears once some research level is reached, and a better replacement becomes available.

Say you want the Cannon to appear from levels 1-5 in Projectile Weapons, where its replaced by the DUC. You'd put this in the requirement field:
(Get_Empire_Tech_Level("Projectile Weapons") &gt;= 1) AND (Get_Empire_Tech_Level("Projectile Weapons") &lt;= 5)

the (s are important- they let SEV know where a funtion like Get_Empire_Tech_Level ends.

Kana
October 11th, 2006, 05:34 PM
Phoenix-D said:
A few modding tricks:
If you have a lot of components, some of them might be obselete at high tech levels, and unlike SE4 it doesn't seem like you can get rid of them.

But this isn't correct. http://forum.shrapnelgames.com/images/smilies/happy.gif All components take formulas for their requirements, and those accept "less than" as an option. So you can make a component that disappears once some research level is reached, and a better replacement becomes available.

Say you want the Cannon to appear from levels 1-5 in Projectile Weapons, where its replaced by the DUC. You'd put this in the requirement field:
(Get_Empire_Tech_Level("Projectile Weapons") &gt;= 1) AND (Get_Empire_Tech_Level("Projectile Weapons") &lt;= 5)

the (s are important- they let SEV know where a funtion like Get_Empire_Tech_Level ends.



If I understand how this is working...

Do you think you could do this in the Vehicle Size file, in conjunction with other vehicle models...?

So basically for example, you have a Original series Star Treck Constitution class ship, and then when you get to a certain level of ship construction, you could upgrade to the Movie era ship image, yet they are all in the say class level of ship?

Phoenix-D
October 11th, 2006, 05:36 PM
The old class should disappear, but your Upgrade button won't upgrade any ships to the new class.

Speaking of, let me check to make sure this doesn't cause problems..

EDIT: ok, with components it works fine. If you press Upgrade, the existing components are simply left on the ship. See the note below.

EDIT final:
Ok, it does work fine for ships; I just had the syntax on the forumla wrong.

A little note- once something is removed in this fashion, you can NOT use it in a new design, or upgrade a design that uses it. You must remove all the removed components to satisfy a "You have used technolgy our empire does not understand" warning.

Baron Munchausen
October 11th, 2006, 06:29 PM
StarShadow said:
My head hurts...



Here, this will make your head hurt a little more. It is possible to get tech levels from other fields than what the weapon (or other component) itself requires. For example, I like to link seeker structure to Armor tech, and defense modifier to Defense (ECM) tech.

Weapon Seeker Tonnage Structure Formula := 30 + (Get_Empire_Tech_Level("Armor") * 2)
Weapon Seeker Defense Modifier Formula := 30 + (Get_Empire_Tech_Level("Defense Systems") * 2)

A little more tweaking (such as linking damage to warhead tech or linking seeker speed to engine tech, which is tricky with each engine type being a seperate tech now) and you could have missile launchers as a stand-alone tech and missile performance being completely independent of them. In this case, I am tempted to put missile launchers into an industrial tech field because they are a sort of 'automation' technology. Missile launchers could get smaller and/or faster as tech increases, but the actual missiles would be better as soon as your propulsion or armor or ECM tech improved. Mod the ordnance storage out of the launcher and you've got a missile system ready for an "Honor Harrington" mod.

Phoenix-D
October 11th, 2006, 06:32 PM
the tricky part is making this all obvious to the player, and balancing it!

Captain Kwok
October 11th, 2006, 06:53 PM
You can use blank abilities that can utilize formulas in for amount1 and amount2 that can report to the player how much resistance a missile has or how fast it goes etc - or for any description that you want really. http://forum.shrapnelgames.com/images/smilies/tongue.gif

Kana
October 11th, 2006, 07:35 PM
Baron Munchausen said:
Here, this will make your head hurt a little more. It is possible to get tech levels from other fields than what the weapon (or other component) itself requires. For example, I like to link seeker structure to Armor tech, and defense modifier to Defense (ECM) tech.

Weapon Seeker Tonnage Structure Formula := 30 + (Get_Empire_Tech_Level("Armor") * 2)
Weapon Seeker Defense Modifier Formula := 30 + (Get_Empire_Tech_Level("Defense Systems") * 2)

A little more tweaking (such as linking damage to warhead tech or linking seeker speed to engine tech, which is tricky with each engine type being a seperate tech now) and you could have missile launchers as a stand-alone tech and missile performance being completely independent of them. In this case, I am tempted to put missile launchers into an industrial tech field because they are a sort of 'automation' technology. Missile launchers could get smaller and/or faster as tech increases, but the actual missiles would be better as soon as your propulsion or armor or ECM tech improved. Mod the ordnance storage out of the launcher and you've got a missile system ready for an "Honor Harrington" mod.



Absolutely brilliant...mind if I rip it off? http://forum.shrapnelgames.com/images/smilies/tongue.gif

I'm planning on an HH mod, and and SFB mod, and this will help tons...

Also I hope some industrious persons start adding this to the modding section of the wiki...

Suicide Junkie
October 11th, 2006, 09:22 PM
If you want to get really fancy:

instead of GETL, or [Level], use (min(GETL,[Level]+5])

That way, you get 5 "free upgrades" before you have to retrofit to gain more improvements.

Kana
October 11th, 2006, 11:43 PM
Someone is going to have to write down all these equations with good explanations...I feel like I'm back in algebra class again...and that was 20 years ago...

Phoenix-D
October 12th, 2006, 03:31 PM
A few more little bits:

A seeker speed of .001 is equal to a ship speed of 1.
Weapon ranges are capped at 500ls- about 2 and a half combat screens, with the default zoom level.

Baron Munchausen
October 12th, 2006, 05:54 PM
Hey! Now why did he cap weapon ranges? Why shouldn't battles across the map be possible? Especially with seekers. (HH mod again... ) Time for another request. http://forum.shrapnelgames.com/images/smilies/happy.gif

Phoenix-D
October 12th, 2006, 05:57 PM
You have to use units for a proper HH mod anyway- no laser-heads otherwise. http://forum.shrapnelgames.com/images/smilies/happy.gif

Suicide Junkie
October 12th, 2006, 10:30 PM
SE3 style seekers were the best thing since sliced bread.

Kana
October 13th, 2006, 02:20 AM
Suicide Junkie said:
SE3 style seekers were the best thing since sliced bread.



Agreed...

StarShadow
October 13th, 2006, 08:55 AM
In what way? I installed the SE3 demo a little while ago and after giving it a try, I have to say I couldn't stand it. Although I did think the race set-up was pretty good, it had an interesting selection of race traits. Anyway, I didn't notice anything special about missiles, so could someone please detail why they were great?

Kana
October 13th, 2006, 12:08 PM
Well from what I remember there were two types...

First Type, was your standard missile. Basically it has fuel/distance, and a set amount of Hit Points, and Damage. It travels up to the distance it can, will take up to its HP before being destroyed, and will do set damage at any range it travels to.

Second Type, was the plasma missile. It has a limited distance that it can travel, and loses damage for every range band that it travels, and the health and damage of the warhead are combined, so its health decreases as its damage decreases. Also any point defense will decrease the damage along with the health.

That is if I remember that correctly...

Hoping that there will be some ways to fiddle with formulas and fields and such to get it to work somewhat like this in SEV.

Fyron
October 13th, 2006, 01:12 PM
In SE3, seekers have a firing range limit, but no travel range limit. Plasma missiles would expire after a while by virtue of losing a few points of damage for every range traveled, but CSMs would never expire until they hit the target or were shot down.

Barnacle Bill
October 13th, 2006, 03:50 PM
Is there a syntax for comments in the SEV data files?

For example, in the data files of the Paradox games, anything between a # and a carriage return is ignored, so you can insert either entire lines of comments or comments at the end of a line of code. Very handy for remembering what you did later...

Captain Kwok
October 13th, 2006, 04:00 PM
Yes, // is used for comment lines and is used throughout the data files.

StarShadow
October 13th, 2006, 05:57 PM
Ah, ok. I understand now.

President_Elect_Shang
October 13th, 2006, 09:09 PM
I was looking through the files and there are three things I don’t get.

1. I noticed “Can Use Warp Points”; does that mean you can finally make small crafts that can use warp points?

2. Isn’t there a list of all the abilities that can be used?

3. What are the weapon types and weapon delivery types? Isn’t there a list of them?

Suicide Junkie
October 13th, 2006, 10:07 PM
Weapon types are whatever you decide to write components for.

Delivery types are pretty much seekers (with variable turning rate limits), beams and projectiles. Plus ramming warheads.
Hit/miss for beams/projectiles is decided by ECM/sensors.

Available damage types are whatever you write in the damagetypes.txt file.

President_Elect_Shang
October 13th, 2006, 10:21 PM
I have been looking into this and I think you have it backwards. After looking at each weapon in the components file and reading the manual I see that Weapon Type is one of the four aforementioned types and that Weapon Delivery Type is what you make it.

The manual says there should be various files that are Description_xxx but I don’t see them. Did MM take them all out and if so how can we get them?

Suicide Junkie
October 13th, 2006, 10:36 PM
Oh, I gotcha.
The arbitrary one is just a hook; you can make things (racial traits, talisman-ish components, etc) multiply damage amounts caused by the named weapon delivery type.

For example, in GGmod, I set them all to "generic"
Then for the disposable culture I set +100% damage from "generic" weapons, and for preservationists, -50% to damage from "generic" weapons.

President_Elect_Shang
October 14th, 2006, 01:07 AM
Why are there both Min and Max Damage Modifier Formulas? I’m going to take a stab and say the Min formula is for the min damage the weapon will do and the max formula is for the max damage the weapon will do? How does SE know which formula to apply?

Captain Kwok
October 14th, 2006, 01:17 AM
It specifies a range of damage for the weapon. For example if the min is 30 and the max is 40, the weapons will do between 30-40 damage.

President_Elect_Shang
October 14th, 2006, 01:22 AM
Perfect thanks; is there a utility or aid of some sort to help calculate the formula for the Hit Modifier?

President_Elect_Shang
October 14th, 2006, 01:35 AM
Wait no; I just don’t get that line. What is it doing? I read the description earlier but it makes no sense. For example:

0 – ([%Range%] * .5)

Is this saying that at range 50 I lose x accuracy? What value is x and how can I change it?

Can I make a weapon that will have the following hit probability?

Range : 0 – 10 – 20 – 30 – 40 – 50 – 60 – 70 – 80 – 90 – 100
% to hit: 90 – 90 – 90 – 80 – 80 – 80 – 70 – 60 – 50 – 30 – 10

Phoenix-D
October 14th, 2006, 01:45 AM
That line is sayng that you'll lose 0.5% of accuracy per LS of distance. So at 50 LS you'll have a -25% modifier. You change the X by changing .5 to something else, or inputing a different forumla.

Doing that line won't be easy and it won't be short- you'll need lots of tested ifs.

Elsemeravin
October 14th, 2006, 02:13 AM
President_Elect_Shang said:

Can I make a weapon that will have the following hit probability?

Range : 0 – 10 – 20 – 30 – 40 – 50 – 60 – 70 – 80 – 90 – 100
% to hit: 90 – 90 – 90 – 80 – 80 – 80 – 70 – 60 – 50 – 30 – 10



At least you can easily do
Range : 0 – 10 – 20 – 30 – 40 – 50 – 60 – 70 – 80 – 90 – 100
% to hit: 100 – 90 – 80 – 70 – 60 – 50 – 40 - 30 – 20 - 10 - 0

by simply adding 100 to the current formula and changing the multiplication factor. However 0 means "hit every time" while 100 would mean that you could have -100 malus from other component and still hit every time..

(Big guys may correct me if I'm wrong on this)

Phoenix-D
October 14th, 2006, 02:18 AM
The final forumla, or one way of doing it, looks like this:
0 - iif([%Range%] &lt; 30, 10, iif([%Range%] &lt; 60, 20, iif([%Range%] &lt; 80, (30 + ([%Range%] - 60)), (50 + (([%Range%] - 80) * 2)))))

Just a bit messy. Most forumlas will not be anywhere NEAR this complicated, you just happened to pick a difficult one to do.

Here's the breakdown..
<font class="small">Code:</font><hr /><pre>
0 -
iif([%Range%] &lt; 30, 10,
iif([%Range%] &lt; 60, 20,
iif([%Range%] &lt; 80, (30 + ([%Range%] - 60)),
(50 + (([%Range%] - 80) * 2)))))
</pre><hr />

First, a little note: %RANGE% is a variable- it is whatever the current range to the target is. If he's at 50ls its 50, if he's at 10ls its 10, 5 at 5ls, etc.

First line: 0 is just there to make the rest of the numbers negative by using the following - sign. The base to-hit in SE5 is 100%, so what this means is "100% - the result of the following formula" (call that X).

Second line: iif is an if/then statement. The format is iif(value (sign), (then), else). This says IF the range is less than 30, THEN X is 10. ELSE it runs the next IF statement. Why 30? Because that's where your values start to change from that flat -10% chance. Same with all of the breakpoints below- the value checked for is the value where the result changes.

Third line: Same thing. IF the range is less than 60, THEN x is 20. ELSE it runs the next IF statement.

Fourth line: Last if/then. This one says IF the range is less than 80, THEN run the formula (30 + ([%Range%] - 60) and set X to that. If not run the formula (50 + (([%Range%] - 80) and set X to that.

The tricky part is keeping all the blasted parathesis straight..

Elsemeravin: you've got it pretty much right. By default all SE5 weapons hit all the time; unless there's some negative number in the to-hit field you'll never miss.

President_Elect_Shang
October 14th, 2006, 08:23 AM
Ok now I understand and I have to say that formula is a work of beauty. I printed it out as a guide for future formulas. One more question and I think I will be up to par with range.

Let’s say for example that I want to hit a target at range 30 for -20 (80% accuracy). When I set up my formula wouldn’t I want to write the formula for:

Greater than or equal to 21 and less than or equal to 30.

If I don’t explicitly restrict the range I want that one accuracy percent at won’t SE spill it over to the next range IF the next range is undefined? One more time using the example formula you gave; SE will apply the -10 to hit on all ranges from 0 to 30 since your formula said &lt;30 correct?

New question I was reading an earlier post in this thread I came to the impression SE does all ranges in 10’s; which I assume is what you are calling 10 LS, by default. You can change the max range but the base 10’s is programmed. What is the max range; 290 LS?

Captain Kwok
October 14th, 2006, 09:27 AM
President_Elect_Shang said:0 – ([%Range%] * .5)

Somebody was playing the Balance Mod. http://forum.shrapnelgames.com/images/smilies/wink.gif

The max range is 500.

Suicide Junkie
October 14th, 2006, 10:03 AM
If you want over-realism, you can just throw in a 1/r (for 2D accuracy, or 1/r^2 for 3D accuracy falloff.

The major problem is that additive modifiers screw this up bad, so you have to really lock down the available bonuses.

Fyron
October 14th, 2006, 01:12 PM
President_Elect_Shang said:
SE will apply the -10 to hit on all ranges from 0 to 30 since your formula said &lt;30 correct?

Actually, it will apply -10 from ranges 0 to 29. At range 30, you get -20. That is what your chart asked for, right? If it said "&lt;= 30", it would be -10 from 0 to 30 instead.

New question I was reading an earlier post in this thread I came to the impression SE does all ranges in 10’s

No, it does not. Range has a degree of 1, not 10. Actual damage done will be whatever is calculated at the exact range, for example. The damage charts for component display only display every 10 ls because it would be insane to try to show every 1 LS. Also, I think Aaron didn't want to confuse new players by showing the actual formulas.

President_Elect_Shang
October 14th, 2006, 01:13 PM
@CPT Kwok: Yes You Are Correct Sir! It’s the only one the two kids and I play now that you let it out.

@SJ: I’m not sure if that was English; but I am reasonably sure it isn’t what I’m after. I am converting a weapon chart from a board game into a Mod and the chart has the hit probabilities. I want to use these same probabilities so I needed help figuring the formula.

Suicide Junkie
October 14th, 2006, 01:23 PM
I suppose it was more math &amp; geometry than english.
Just throwing that into a hit-chance discussion.

Fyron
October 14th, 2006, 01:25 PM
1/r and 1/r^2 are fundamental ratios in distance equations (such as gravitational force).

President_Elect_Shang
October 14th, 2006, 01:57 PM
Suicide Junkie said:
I suppose it was more math &amp; geometry than english.
Just throwing that into a hit-chance discussion.



As in letting the topic take its own wings; or, developing a hit-miss table that could be applied across the board for weapon types. In this case if a standard was developed for say all “missiles” and all “beams” el-etc and the various modders agreed to said standard it would (speculatively) allow any two or more mods to be fused. This in turn would allow for the combination and recombination of “Super-Mods”.

Phoenix-D
October 14th, 2006, 02:19 PM
Having a standardized to-hit forumla wouldn't help all that much.

Seekers don't miss by the way. Even if they have no turn rate, they only miss if the ship physically moves out of the way of the shot.

President_Elect_Shang
October 14th, 2006, 02:38 PM
Phoenix-D said:
The final forumla, or one way of doing it, looks like this:
0 - iif([%Range%] &lt; 30, 10, iif([%Range%] &lt; 60, 20, iif([%Range%] &lt; 80, (30 + ([%Range%] - 60)), (50 + (([%Range%] - 80) * 2)))))



In the case of the example I gave below couldn’t I do something like:

0- iif ([%Range%] &lt;30, 10, iif ([%Range%] &lt;60, 20, iif ([%Range%] &lt;70, 30, iif ([%Range%] &lt;80, 40, iif ([%Range%] &lt;90, 50, iif ([%Range%] &lt;100, 70, iif ([%Range%] &lt;110, 90)))))))

Phoenix-D
October 14th, 2006, 02:48 PM
Looks ok to me.

President_Elect_Shang
October 14th, 2006, 05:24 PM
I need another formula help. What if I want to create a damage formula with the following values:

Range: 0 – 10 – 20 – 30 – 40 – 50 – 60 – 70 – 80 – 90 – 100 – 110 – 120
Damage inflicted: 30 – 30 – 20 – 20 – 20 – 10 – 10 – 10 – 10 – 10 – 10 – 10 – 10

How would I do this? I know that I only need to do the formula once as I want a flat damage rate so the min and max formula would be the same. Apologies but the formatting isn’t coming out and I don’t want to make it into columns.

aegisx
October 14th, 2006, 05:28 PM
AI colonies...

-Main script calls function to give ship orders.
-If its a colony ship, it calls the colony minister function.
-The minister looks for a planet to colonize (doesn't seem to care about any details, just if it can).

The AI has a function to pick a colony type, what calls that? It also seems to base what colony type based off of how many other colonies of the same type there are?

Noble713
October 14th, 2006, 05:29 PM
I may have asked these before but I don't think I got an answer:

What does Base Model Radius in mpire_ships_xfileclasses.txt do?


The scale setting in each xfileclass seems to affect both the display of ships in the system display as well as in the combat engine. I want a different scale for each. For example, I would scale ships so they are all approximately the size of a hex in the system screen (making them clearly visible but not overly large), but I don't want every ship to be the same size in tactical combat. Is this possible now, or is it something I need to ask Aaron to add? It's essentially two seperate scale settings for strategic/tactical views as opposed to the one setting we have now.

Elsemeravin
October 14th, 2006, 05:29 PM
Why don't you use the exact same formula as for accuracy (below) but changing the weight and limits ?

kind of :
iff %range% &lt;=10 ,30,iff %range% &lt;=40 , 20,iff %range% &lt;=120,10,0

President_Elect_Shang
October 14th, 2006, 05:47 PM
Elsemeravin said:
Why don't you use the exact same formula as for accuracy (below) but changing the weight and limits ?

kind of :
iff %range% &lt;=10 ,30,iff %range% &lt;=40 , 20,iff %range% &lt;=120,10,0



Can I do that? SJ, CPT Kwok, Phoenix-D? Is that a legal formula to use for the damage? How would I place the range limit on it? Something like

&gt;=121, 10000, 0
The &gt;= is for the cut off point.
The 10000 is to change all damage to 0 past that point.
I have no idea why the last 0 is in there(?).

Suicide Junkie
October 14th, 2006, 06:10 PM
You don't want 10000 damage; that would be huge.

Give me 10 minutes, and I'll tweak my equation parser program to show values at range.

Kana
October 14th, 2006, 06:17 PM
Yaa...I know what PES is working on...

http://forum.shrapnelgames.com/images/smilies/biggrin.gif

Suicide Junkie
October 14th, 2006, 06:38 PM
http://imagemodserver.mine.nu/other/MM/SE5/Tools/ValueAtRangeLister.zip

The one thing to keep in mind is that SE5's formula parser is not as flexible as this one.
SE5 demands whitespace everywhere, for example.

Note:
If you're not sure what is causing an error condition, press the "verbose" button, and it will tell you what it thinks is wrong with your formula.

President_Elect_Shang
October 14th, 2006, 06:46 PM
Kana said:
Yaa...I know what PES is working on...

http://forum.shrapnelgames.com/images/smilies/biggrin.gif



http://forum.shrapnelgames.com/images/smilies/redface.gif

Kana
October 14th, 2006, 06:47 PM
Imperator Fyron said:
No, it does not. Range has a degree of 1, not 10. Actual damage done will be whatever is calculated at the exact range, for example. The damage charts for component display only display every 10 ls because it would be insane to try to show every 1 LS.



So what value will it display per each 10 LS, if there are different values from 1-10 etc...?

Suicide Junkie
October 14th, 2006, 07:05 PM
The value AT range 10, 20, etc I believe.

http://imagemodserver.mine.nu/other/MM/SE5/Tools/ValueAtRangeLister.zip

Phoenix-D
October 14th, 2006, 07:08 PM
It displays the value AT ten.

As for the forumla..

iff %range% &lt;=10 ,30,iff %range% &lt;=40 , 20,iff %range% &lt;=120,10,0

aside from the formating, that should work. The spaces have to be in the proper spot and you're missing ( and ) marks as well as the [ around %range%
iff([%range%] &lt;= 10, 30, iff([%range%] &lt;= 40, 20, iff( [%range%] &lt;= 120, 10, 0))) should work.

EDIT:
&gt;=121, 10000, 0
The &gt;= is for the cut off point.
The 10000 is to change all damage to 0 past that point.
I have no idea why the last 0 is in there(?).

You set the range limit in the DAMAGE forumla, not the to hit formula. EDIT2: and that's what you did. Oops. Anyway, despite SJ's protest 10000 works fine in that role.

Even if the to-hit is -99999, a ship will still fire and waste supplies, and the "max range" strategy will use that to determine its range.

The second 0 is the ELSE part of the statement; its what the formula uses if the range isn't above 120.

Captain Kwok
October 14th, 2006, 07:24 PM
aegisx said:The AI has a function to pick a colony type, what calls that? It also seems to base what colony type based off of how many other colonies of the same type there are?

The file Script_AI_ColonyType.txt contains the syntax for the AI to choose a colony type. In stock, it chooses a colony type based on a set percentage desired for each type. If it picked a resource type, then it would pick what resource by the value. Of course this meant a lot of times the AI was using good resource planets for stupid things. However, in the Balance Mod I switched this for the AI to pick a one of the resource colonies if the planet value was good to excellent and if it was poor in value to pick one of the other types based on a desired percentage in the empire.

aegisx
October 14th, 2006, 07:28 PM
Kwok: Nice, Ill have to check that out.

What I was looking for is what actually calls the Pick_ColonyType function. Or is it event driven, so the internal engine calls that function onColonize() or something.

Captain Kwok
October 14th, 2006, 07:47 PM
aegisx said:What I was looking for is what actually calls the Pick_ColonyType function. Or is it event driven, so the internal engine calls that function onColonize() or something.

The Script_AI_Orders_Ships.txt file has the colony minister choosing a planet from the colonizable list but I'm not sure how its determining which one to go to first other than maybe closest.

aegisx
October 14th, 2006, 09:51 PM
If I remember right, it is just the first in it's list. That could be another useful place to mod, so they colonize more intelligently.

President_Elect_Shang
October 15th, 2006, 03:39 AM
Next few questions:

1. Can small craft (i.e. fighters or “shuttles”) be given the ability to make warp transits now?

2. Can the same small craft be given the cargo ability to transport troops or other goodies?

3. If they can transport troops can they be set to land troops?

Fyron
October 15th, 2006, 04:43 AM
1. Take a look at VehicleUnitTypes.txt and weep with joy.

2. They can act like troops and participate in ground combat. Dunno about actually carrying other units though. There isn't anything in VehicleUnitTypes.txt about it, but it would be really easy to test. Somehow, I doubt that units would be able to carry units, however, due to circular capacities and infinite storage space.

Barnacle Bill
October 15th, 2006, 09:16 AM
I'm looking at the AI setup scripts and wondering how the Racial Traits section is used...

Do the "random empires" that get added if you select "Generate random computer controlled players" use this to determine their racial traits?

If so, I would assume that they do so in order as listed in the script, until the point limit of the game is reached. However, you can select 2000, 3000 or 5000 point limits and I've checked 4 races so far and they don't add up. For the Abbidon, Amonkrie &amp; Cue Cappa it comes evenly to 2000 and 3000 if you add them in order, but the total list in the script is less than 5000. For the Drushocka, adding them in order jumps you from 1500 to 2500, and the point total of all the traits listed in the script is 6000. So how does this work -

In a 5000 point game, would the Abbidon, Amonkrie &amp; Cue Cappa take additional traits based on something else (what?)to get to 5000? Or would they just soldier on with &lt;5000 in a 5000 point game? Do they get something else for their unused racial points? In a 2000 point game, would the Drushocka skip over that 1000 pt trait at 1500 to get to the next 500 pt trait on the list, or act as if the list didn't contain enough traits to reach the game point total.

Similarly, do I assume correctly the neutral players use the "default" script? In that, the raciat trait section actually contains formulas - a list of if statements in the form...

if (Sys_Get_Random_Long(1, 4) = 1) then
call Add_Racial_Trait("Advanced Storage Techniques")
endif

How does this work -

Does it go down the list until it fills the point total for the game? Again what if it is 500 points under the limit and the next one it gets is a 1000 pt trait? What if it gets through the whole list without hitting the limit? Do the regular races default to this when their list contains fewer pts worth of traits than the game limit?

Also, I haven't seen any negative point trait being called out in the scripts...

President_Elect_Shang
October 15th, 2006, 12:26 PM
Imperator Fyron said:
1. Take a look at VehicleUnitTypes.txt and weep with joy.




Finally... There’s no “weep” emoticon; that sucks?

Has anyone tested to see if it works though?

Spectarofdeath
October 15th, 2006, 03:37 PM
Are we able to build or mod in a certain structure that can only be built once?

President_Elect_Shang
October 15th, 2006, 08:56 PM
What if I have a ship component and I want the first version of it to be open for development at tech level x1 and tech level y1. However, I do not want the second version to be developed till tech level x12 and tech level y3. Can that be coded? Put another way:

I want to make a ship component “Funky Monkey 1” and “Funky Monkey 2”.

Funky Monkey 1 can be developed at tech level x =1 and tech level y =1.
Funky Monkey 2 can be developed at tech level x=12 and tech level y=3.

I want this to be generational (one component) so I can write the component Maximum Level as 2. At this time I have them written as two components with Funky Monkey 1 set to disappear when research for Funky Monkey 2 has been completed.

Phoenix-D
October 15th, 2006, 09:13 PM
Possible.

requirement 1:
Get_Empire_Tech_Level("x") &gt;= (1 + ([%Level%] - 12))
requirement 2:
Get_Empire_Tech_Level("y") &gt;= (1 + ([%Level%] - 3))

should do it..

Suicide Junkie
October 15th, 2006, 09:46 PM
I think you meant to put multiplication instead of subtraction.

This should work better:
requirement 1:
Get_Empire_Tech_Level("x") &gt;= ([%Level%] * 11 - 10)
requirement 2:
Get_Empire_Tech_Level("y") &gt;= ([%Level%] * 2 - 1)

Level 1 requires X &gt;= (11-10 = 1) and Y &gt;= (2-1 = 1)
Level 2 requires X &gt;= (22-10 = 12) and Y &gt;= (4-1 = 3)

President_Elect_Shang
October 15th, 2006, 11:06 PM
Apologies gentlemen; however, I am just too slow to follow those examples. I have decided to leave them as separate components that phase out. Now how about something a little less complex, how would I tackle this one?

I have the component “Bottomless Fiend Grinder” and I want another generation to come available every [b]other level. So for example:

At tech level 1 you get BFG 1.
At tech level 3 you get BFG 2.
At tech level, ya Ok you get the idea…

How would I do that?

Suicide Junkie
October 16th, 2006, 01:35 AM
Requirement:

GETL("x") &gt; [%Level%] * 2

Captain Kwok
October 16th, 2006, 07:40 AM
Suicide Junkie said: GETL("x") &gt; [%Level%] * 2

...or GETL("x") &gt; (([%Level%] * 2) - 1) for an odd series.

President_Elect_Shang
October 16th, 2006, 08:52 AM
Ok; now I understand this and the other formula (1st and 12th tech level)! I was way over thinking the whole thing. Thanks guys, back to the grind till the next question.

President_Elect_Shang
October 16th, 2006, 10:45 AM
If I use a formula that generates a fraction what will SE do? Choke and die, round up, round down, or ignore all fractions?

Captain Kwok
October 16th, 2006, 11:11 AM
Most formulas can do decimal entries and the result is either rounded off or used as is depending on what it is affecting. For example, damage is rounded to whole number, while population reproduction or sight level is not. Formula fields that don't use decimals usually return a value of 0.

President_Elect_Shang
October 16th, 2006, 11:22 AM
Captain Kwok said:
Most formulas can do decimal entries and the result is either rounded off or used as is depending on what it is affecting. For example, damage is rounded to whole number, while population reproduction or sight level is not. Formula fields that don't use decimals usually return a value of 0.



How about the build rate for a construction yard; dropped I would think.

President_Elect_Shang
October 16th, 2006, 11:45 AM
If space yards are in space why were they given the ability to repair facilities?

Captain Kwok
October 16th, 2006, 12:22 PM
Are you asking about the Space Yard component or Space Yard facility?

For gameplay resasons it's probably a good idea to keep it that way since there is no inherent repair rate for a planet. I requested that some lines be added to settings.txt that allow you set a repair rate for a planet without a SY...

President_Elect_Shang
October 16th, 2006, 12:52 PM
The component; how does a space yard in space fix a facility on a planet? You do have a good point though!

Spectarofdeath
October 16th, 2006, 12:59 PM
Construction crews shuttle down to the planet and repair the facilities using supplies from the planet?

Q
October 16th, 2006, 01:08 PM
A basic repair for colonies is essential IMO. Otherwise damaged facilities will never be repaired and it is quite unlogical that you can build new facilities, upgrade facilities but not repair them!

President_Elect_Shang
October 16th, 2006, 01:14 PM
Is there a way to build a component which has a restriction that limits the total number that can be carried? For example:

The Mega Toaster
The mega toaster can toast all bread in the blink of an eye; however, due to the power draw only 1 per 100 hull spaces can be used.

*Mega Toaster Inc. is not responsible for burnt slices or charring of crust. http://forum.shrapnelgames.com/images/smilies/tongue.gif

Tampa_Gamer
October 16th, 2006, 01:52 PM
President_Elect_Shang said:
Has anyone tested to see if it works though?



Yes and no. It [VehicleUnitTypes.txt] has some issues that are still on Aaron's to-do list (I hope). This file will be incredibly powerful once its working correctly. This file will allow us to create leaders, gunships, and many other things that we have been requesting since 2001. Unfortunately, it's not quite there yet, since Aaron needs to add some more hooks in the actual engine to make the new units behave (and be recognized) like the default units. My fingers are crossed that this can be accomplished easily.

Ed Kolis
October 16th, 2006, 02:22 PM
President_Elect_Shang said:
Is there a way to build a component which has a restriction that limits the total number that can be carried? For example:

The Mega Toaster
The mega toaster can toast all bread in the blink of an eye; however, due to the power draw only 1 per 100 hull spaces can be used.

*Mega Toaster Inc. is not responsible for burnt slices or charring of crust. http://forum.shrapnelgames.com/images/smilies/tongue.gif



Sure, I guess you'd have to give it some unique ability that does nothing (like "AI Tag 1"), then do a requirement that Get_Component_Ability_Count("AI Tag 1") &lt;= Get_Vehicle_Hull_Tonnage() / 100... (not entirely sure about the names of those functions)

Now if you could just restrict based on component NAME that would be much easier... but I never tried that and don't have the function list handy, so it might already be possible http://forum.shrapnelgames.com/images/smilies/tongue.gif

Phoenix-D
October 16th, 2006, 02:26 PM
Note: depending on where you use it, Get_Vehicle_Hull_Tonnage has a tendancy to return 0.

It works in the weapon enhancement file, but I've yet to have it work in components.txt.

Fyron
October 16th, 2006, 02:40 PM
President_Elect_Shang said:
Is there a way to build a component which has a restriction that limits the total number that can be carried?

You must have missed this thread:

http://www.shrapnelcommunity.com/threads/showflat.php?Cat=&amp;Number=447917

President_Elect_Shang
October 16th, 2006, 02:59 PM
Imperator Fyron said:You must have missed this thread:



I do not want to force a ship type to have x many of weapon Toaster. If the designing player wants to put toasters on his ship I want to restrict how many they can emplace based upon the total tonnage; one per 100 tons to be exact. I did miss that thread and after scanning it I can see where you made 50% of the hull dedicated to fighter bays; however, as I mentioned this is not the type of restriction I want.

Suicide Junkie
October 16th, 2006, 03:28 PM
If you know the size of the hull, (which you do) then you know how many are allowed simply by doing the X per 100kt math.
Limit to that many. Done.


Restrictions are each an equation. If the equation evaluates to false, then the design is illegal. If it is true, the design is OK.

Fyron
October 16th, 2006, 03:34 PM
President_Elect_Shang said:
I did miss that thread and after scanning it I can see where you made 50% of the hull dedicated to fighter bays; however, as I mentioned this is not the type of restriction I want.

Well good, cause that is not at all what the thread is talking about. http://forum.shrapnelgames.com/images/smilies/happy.gif The 50% fighter bay requirement is already a part of SE5. The thread is about how to set up a max number or percentage of space you can use for specific types (or groups) of components (eg: weapons); it is in fact exactly what you want to do. You can't do it from the component itself, it has to be a restriction on each hull.

President_Elect_Shang
October 16th, 2006, 04:30 PM
So you are saying give the component say “tag 1” then each ship size the restriction 1 tag 1 per 100 hull spaces. Won’t this cause the ship to NEED that component or else it will warn of an illegal design? Your light cruiser needs 50% fighter bays or it can’t be created correct?

From your thread:

Requirement 7 Description := This vehicle must have at least 50% of its hull dedicated to Fighter Bays

Making a ship take a certain number of a component is an old trick I know well. If I code something along this lines I will be forcing the player to take the component or else. Is there something else that I am missing? The Ultra-Toaster component MUST be purely optional. I managed a very dirty way to do this in SE4 but with SE5 it is another creature. I am trying to learn to mod all over again.

On another question is Aaron going to release a detail of the abilities that can be used for components, et-el?

Fyron
October 16th, 2006, 04:33 PM
Huh? The example is a carrier, so it has a fighter bay requirement as the source vehicle from the data file does. That is not what the thread is about though; look at the last requirement (the one the post tells you to add). It is a max space for AI Tag 01. There is no requirement to have any AI Tag 01 abilities present to have a legal design, just a maximum.

Aaron is working on some modding docs.

Suicide Junkie
October 16th, 2006, 05:31 PM
You can put whatever you like for the formulae; plug math and comparisons and boolean logic together like legos, and you can make whatever you want.

What is the source of confusion?

Phoenix-D
October 16th, 2006, 05:35 PM
Shang, you're taking the example too literally.

First, the design requires LESS than 1 per 100; 0 is perfectly fine. Look at the engines for a stock example- every ship has a requirement that limits the amount of Standard Move you can have.

Second, the design linked is for a *carrier*. That is why it has the Fighter Bay requirement. Ignore that part, it isn't even relevent.

President_Elect_Shang
October 16th, 2006, 05:44 PM
Now that question I can answer. The source of my confusion is in the Boolean and SE5. Specifically my experience with either is limited to what; three or four days now? I am learning as I go. My tech skills end at the tips of my fingers so-to-speak.

Ok now I have my focus on requirement 8. So you give all weapons AI Tag 01 and now the AI will only add three weapons. And this restriction will pass on to the player as well? They will only be able to add three weapons? Excellent! That is much better than my solution.

This misunderstanding/confusion is my fault, I’m so conditioned to looking at the “Requirement” list that I stopped reading when I reached the break between 7 and 8. As for it being a carrier I only noticed the post title “SE5 - Mod Out LCX as Early Warship”. LC to me is Light Cruiser and X means Experimental. What I will do now is read the thread in its entirety. As I said below I only scanned the thread.

Fyron
October 16th, 2006, 06:04 PM
SE4/5 make the Carrier's abbreviation be "CX", so I just appended a L to it. But I see that SE5 has just "LX" for light carrier. Sorry for the confusion.

President_Elect_Shang
October 16th, 2006, 06:25 PM
No it’s my fault, allow me to explain where it started and it will become clear.

SE4 may have used CX; however I made the StarFire mod and started playing it exclusively. In StarFire the CX becomes the CV and the Light Cruiser the CL. When I read the title I figured the LC was a simple type-o; a letter reversal either not noticed by you or noticed and discarded as being to minor to warrant correction. A simple mistake compounded by me working on a StarFire Mod for SE5; which happens (as Kana pointed out already) to be the current source of all my annoying questions.

AngleWyrm
October 17th, 2006, 11:48 AM
About the case statement of the form:

case my_var
1:
2:
call Task_One
3:
call Task_Two
endcase

1). if my_var = 1, does it call Task_One?
----- Invalid (empty) case statement; won't compile
2). if my_var = 2, does it also call Task_Two?
----- No.
3). if my_var = 0, does it skip both tasks?
----- Yes.

Elsemeravin
October 17th, 2006, 04:44 PM
I was thinking it would be nice to extend the current plague system, maybe as follow:

1] Be able to use a formula for the amount of damage each turn, depending on the turn number (could make damage go down, like plague becoming less active, or up exponentially to force a quick resolve and simulate pandemia).

2] To be able to use amount2 as a "plague type". In that case a plague prevention component/factory could only cure the corresponding "plague type" (or several if several such abilities modded in the facility).
This way we could create plague used as virus, destroying only master computers, or facilities and so on.

Kana
October 17th, 2006, 05:31 PM
Well if the plague entry has a formula line then you can make some kind of formula. Any line in the data files, that has the word 'formula' in it, can have a formula.

Elsemeravin
October 17th, 2006, 06:01 PM
But do you know the variable (like %range%) corresponding to the number of turns ?

President_Elect_Shang
October 18th, 2006, 12:45 AM
This line comes from the components text but where is “Beam 10”? In the effects folder I see Beams_01 to 07 and there appears to be 4 beams per bit map. What if I want to change a weapon to another display beam type? I hope the modding gets easier as the game is developed more, or at least a really good guide is created!

Anti-Proton Beam
Weapon Space Display Effect Name = Beam 10

Phoenix-D
October 18th, 2006, 01:22 AM
That's specified in BitmapEffects_SpaceCombat.txt.

President_Elect_Shang
October 18th, 2006, 01:35 AM
You see now I was thinking that, hence the reference to 4 per bit map. I just didn’t want to say it and sound nuts. http://forum.shrapnelgames.com/images/smilies/frown.gif

Kana
October 18th, 2006, 01:45 AM
Just think of it as a wealth of modding possiblities...

Elsemeravin
October 18th, 2006, 03:08 AM
Would someone know about the functions that can be used in facility requirement ?
I would like to create requirement such like :
Planet already has one facility with ability X
Sum of amount1 of ability Y on Planet &lt;= Y

Would you know such functions (like I know already for component) ?

(My SEV boxed copy arriving beginning of next week http://forum.shrapnelgames.com/images/smilies/happy.gif)

President_Elect_Shang
October 18th, 2006, 04:58 PM
I’m a little confused here, I see this descriptor however how does SE5 know to only place one per ship?

Ability 3 Type := Description Only
Ability 3 Description := Only 1 Survey Instruments per vehicle effective.
Ability 3 Scope := Space Object
Ability 3 Range Formula := 0
Ability 3 Amount 1 Formula:= 0
Ability 3 Amount 2 Formula:= 0

Is there another entry that controls this, there must be but what is it? What is the limit for how many I can place; as in SE4 where I could place up to 10 per?

Fyron
October 18th, 2006, 05:00 PM
That is not any sort of restriction, it is just a tag to inform the player that the other abilities of the component do not stack. The AI is generally set up to only add one such component per ship, since extras are redundant.

Adding a max per ship can be done via the vehicle hulls, as in that LCX thread, or you could probably work something into the placement requirements of the component.

President_Elect_Shang
October 18th, 2006, 05:03 PM
Ya the “Description Only” thing was kind of a dead give away. http://forum.shrapnelgames.com/images/smilies/biggrin.gif

What I was asking is where is the control for this? What line?

Phoenix-D
October 18th, 2006, 05:10 PM
You can control how many are placed by the player by using restrictions. Controlling how many the AI places requires messing with the AI scripts, which I haven't done much of yet.

(and if you think components.txt is weird, the AI scripts are going to make your head explode).

If you mean the controller for how many actually work, that's defined by the ability itself IIRC.

President_Elect_Shang
October 18th, 2006, 06:01 PM
I’m looking to control how many the player can put in. For example in SE4 if I wanted to keep the player from using more than four I would add the restriction “Four Per Vehicle”. In SE5 I am not seeing this except I have noticed that when the description says “Only 1 _blank_ per vehicle effective” another ability will have a number “2” in the Amount 2 Formula line. I will check to see if they are connected.

If it is controlled by hard coding now why did Aaron remove it? More importantly can he add it back in?

OMG I haven't even thought about the AI. http://forum.shrapnelgames.com/images/smilies/Sick.gif

Phoenix-D
October 18th, 2006, 06:05 PM
You control the number per vehicle with requirements. Just look at the engine limits in VehicleSize.text and apply that to the actual components.

President_Elect_Shang
October 18th, 2006, 06:14 PM
President_Elect_Shang said:
In SE5 I am not seeing this except I have noticed that when the description says “Only 1 _blank_ per vehicle effective” another ability will have a number “2” in the Amount 2 Formula line. I will check to see if they are connected.



Nope that’s not it; suppose it’s time to write Aaron and ask him? Thoughts?
Ops, need to READ before I write. My bad Phoenix-D

Phoenix-D
October 18th, 2006, 06:20 PM
Try again:
Requirement 5 Description := This vehicle can only have a maximum of 12 movement.
Requirement 5 Formula := Get_Design_Ability_Component_Count("Movement Standard") &lt;= 12

"Movement Standard" is the ability used in the component in question. If your component doesn't use an ability, just give it a useless ability or an AI-Tag and refer to that, instead.

President_Elect_Shang
October 18th, 2006, 06:24 PM
Phoenix-D said:
You control the number per vehicle with requirements. Just look at the engine limits in VehicleSize.text and apply that to the actual components.



I see what you are saying. So if I want to keep a player from putting more than one Burger King on a battleship I would have to include the restriction in the battleship section of the vehiclesize.txt. Wow, now that’s nifty and has lots of potential!

Edited I posted before I read your answer then took off to teach consonant diagraphs. Then came back read your first reply and wrote this one.

Phoenix-D
October 18th, 2006, 06:28 PM
If you want to do it just for the battleship, yes. You can do it for all ships by putting the requirement on the component itself, I think.

Captain Kwok
October 18th, 2006, 06:48 PM
It's important to note that the amounts of Engines/LS/CQ that the AI will add to a vehicle size is "hard-coded" and they will continue to follow them regardless of how you change the data file. You'll need to edit Script_AI_GlobalSettings.txt file to correct for this and recompile all the AIs.

Fyron
October 18th, 2006, 08:13 PM
I see my answer was missed earlier:


Imperator Fyron said:
Adding a max per ship can be done via the vehicle hulls, as in that LCX thread, or you could probably work something into the placement requirements of the component.

President_Elect_Shang
October 18th, 2006, 11:23 PM
No I was just using the battleship as an example; I thought the “Burger King” gave it away (he-he). My dry humor doesn’t work in written word either I see! At least I’m consistent.

The good news is that Fyron’s AI Tag (his example) works as will any actual ability. For example I used sight range and it worked.

The bad news is the ability will not work in the components; it will only work in the vehicles.

On a last note, I have no idea why I want to stick an “a” in digraph. At this point it has become the joke of the class.

President_Elect_Shang
October 18th, 2006, 11:53 PM
Would this be a legal statement and a self terminating seeker at range 40?

Weapon Seeker Tonnage Structure Formula := 10 - iif ([%Range%] &gt;= 40, 0)

Suicide Junkie
October 19th, 2006, 12:01 AM
No, but that's because your iif only has two parts.
iff( &lt;condition&gt;, &lt;do-if-true&gt;, &lt;do-if-false&gt; )

In addition, subtracting zero from 10 equals 10.
There is also the question of what range means to a seeker in flight.

Suicide Junkie
October 19th, 2006, 12:04 AM
President_Elect_Shang said:
...
On a last note, I have no idea why I want to stick an “a” in digraph. At this point it has become the joke of the class.

Perhaps because you are thinking of "diagram"?

President_Elect_Shang
October 19th, 2006, 12:22 AM
I keep getting the error: Could not parse formula.

So I will have make a note of how they work, I have a feeling there will be plenty of other errors when I do a first test run. Hard way to learn but I will learn. I don’t have the slightest notion how it would treat range, I needed a way to make the seeker either inflict no damage or what I am truly trying for is to “self destruct” itself (so-to-speak) at a certain cutoff range. How about:

iif ([%Range%] &lt;= 40, 10, 0)

I draw diagrams for some of the more complex digraphs so that could be it. Or maybe because it makes the kids laugh and that has reinforced it to the point of habit. http://forum.shrapnelgames.com/images/smilies/cool.gif

Edit:
Need to correct myself: I already have the seekers doing no damage past a certain range, well I am fairly confident that is what I did.

Phoenix-D
October 19th, 2006, 12:25 AM
The syntax for the forumlas has to be fairly exact.

DON'T put that space between the iif and the (, for example. Just plain iff(

President_Elect_Shang
October 19th, 2006, 12:37 AM
YES!!!!!!!!!!!!!!!!

Ladies and gentlemen the seeker self-destructed at a range of 40! The weapon flew at the other ship and at the correct range there was an explosion and the seeker disappeared even though it was nowhere close to the other ship!

Formula used: iif([%Range%] &lt;= 40, 10, 0)

Suicide Junkie
October 19th, 2006, 12:45 AM
What's the range of the missile tho? They do naturally fizzle when their damage at range hits zero.

Captain Kwok
October 19th, 2006, 12:49 AM
That's very cool!

President_Elect_Shang
October 19th, 2006, 12:58 AM
Suicide Junkie said:
What's the range of the missile tho? They do naturally fizzle when their damage at range hits zero.



The test range was 40 whatever unit of measurement. I was looking for the explosion. I know your probably thinking what a pointless discovery. It’s just my personal taste; something about the explosion that makes me say ahhh. Hmm, honestly this has no practical application other than to say the seeker structure can be based off range. Hay, what about a weapon that grows in power up till a certain range then decreases again? That wouldn’t be useful to me but maybe someone else could use it? Now that I think about it you could do that in the damage formula anyway. Ok so I just like the flipping explosion! http://forum.shrapnelgames.com/images/smilies/evil.gif

Suicide Junkie
October 19th, 2006, 02:07 AM
Missiles explode when they hit max range regardless.

President_Elect_Shang
October 19th, 2006, 02:11 AM
Suicide Junkie said:
Missiles explode when they hit max range regardless.



Really? In the stock game I didn’t see an explosion, they just fizzled or maybe disappeared is a better descriptor.

Edited in: We are both talking about seekers? These seekers (in my rather pointless experiment) whose max damage and range had not been reached exploded when their structure reached zero which had no effect on the amount of damage they inflicted.

As I said it was a rather pointless attempt to test a thought I had.

Kana
October 19th, 2006, 02:54 AM
I was hoping that the structure could use outside data...Now I will be able to make a formula for the damage/structure of a SFB plasma torpedo, that will fizzle with range, do less damage, and hopefully take damage that will reduce the amount it does when it hits the target...

I'm sure that will be either one complex formula, or a combination of formula between range, damage, and structure.

Kana
October 19th, 2006, 03:28 AM
So what are the units of measurement in Combat? The Light-Second (LS) for range, and KM/Second (KM/S) for the movement speed of the craft, correct?

Well a LS, is like 300,000 KM, that is a really long range. I dont take it there is any way to change any of the units in the game?

For SFB, that is like range 30, max range for most photons, and disruptors.

For Starfire, that is only range 2. Lucky PES...

I know it doesnt really matter what its called range 30 is range 30. Yet in some ways it would be nice to be able to compare directly between the resource material, and Space Empires.

Fyron
October 19th, 2006, 03:43 AM
Check out MainStrings.txt.

Captain Kwok
October 19th, 2006, 07:29 AM
I don't even recall where it displays LS as the units of range, but I've switched things like mount range descriptions to Km myself and will probably do so to the different mainstrings.txt references to LS.

Kana
October 19th, 2006, 03:59 PM
Well when you find it share, the only thing I found was an LS reference to ground combat which really doesnt make much sense...

Kamog
October 19th, 2006, 10:10 PM
Where are the Description_X files such as "description_abilities.txt"? They were not included in the demo, and I couldn't find them in the full game either.

Fyron
October 19th, 2006, 10:13 PM
Aaron took them out, pending rewriting them to be up to date and more complete.

Kamog
October 20th, 2006, 12:45 AM
OK, thanks, Fyron. http://forum.shrapnelgames.com/images/smilies/smile.gif

Elsemeravin
October 20th, 2006, 02:39 AM
Imperator Fyron said:
Aaron took them out, pending rewriting them to be up to date and more complete.



Do you think it possible to have an incomplete version ? Would it be ok to post only the description files, although incomplete, so that we could start real modding (I still need functions for facility requirement) ?

Kamog
October 20th, 2006, 02:53 AM
I'm trying to create a weapon mount that increases the damage but slows down the reload rate. Is it possible to make a mount that changes the firing rate of a weapon?

Is there an ability like "Component - Weapon Reload Rate Percent" that we can use?

Kana
October 20th, 2006, 03:21 AM
Kamog said:
I'm trying to create a weapon mount that increases the damage but slows down the reload rate. Is it possible to make a mount that changes the firing rate of a weapon?




Well each weapon has this...

Weapon Reload Rate MS Formula

Which means you can use some kind of formula here.

Didnt see anything having to do with component-XXXXX. As it is I would say no.

President_Elect_Shang
October 20th, 2006, 11:57 AM
Does the Min and Max damage modifier formula have to be populated? For example can I enter a zero (0) there and use the Min and Max Damage at Range for my weapons with fixed damage [at all ranges] amounts?

Fyron
October 20th, 2006, 01:47 PM
Do you think it possible to have an incomplete version ?

No. As I said, they are also out of date. Some information in them is not correct any more. It was a year ago, but things have changed since then. http://forum.shrapnelgames.com/images/smilies/happy.gif

Does the Min and Max damage modifier formula have to be populated?

Yes, they must have data. If you put a 0 for min, damage will range between 0 and max. If you put a 0 for max, who knows what will happen. To get a fixed damage amount, just put the same formula for each.

President_Elect_Shang
October 20th, 2006, 02:50 PM
I was looking over the components and noticed there was one for negating damage from energy weapons. So this isn’t anything new but it did give me a new thought. What would happen if you had a device that negated the damage from a tractor beam? Would this also negate the effects of the tractor (pulls target) or would it just negate the damage and still pull the target? Has anyone tried this before? Is there a way to build a component that negates the pulls target ability?

Yoda
October 20th, 2006, 03:11 PM
I am trying to create a shield mount, but I cant figure out how to modify the shield output. I could do it in SEIV, is it possible in V? What abilities can be modified with mounts other than those used in the stock files?

Kana
October 20th, 2006, 07:10 PM
A general question...

When you make a mod, what process to you follow?
How much pre planning do you do? What do you do?
Which data file do you start with first? Second?
Do you start from scratch, or do you just type over other entries?