Jump to content

[1.1.3] AntennaRange 1.11.4 - Enforce and Encourage Antenna Diversity


toadicus

Recommended Posts

I'm currently launching a new sat every day and sending them towards Moho, to create breadcrumbs behind the first one I lunched to explorer Moho, while trying to get the 300 science to get the 88-88.

The Moho trip is 102 days.... (I think 83 days is optimal for a Moho encounter)

Why Moho, because the transfer window for it came up, so early that I wanted to use it, but AntennaRange killed my plan, my first game with it active, so I hadn't quite pictured the range of the antenna's yet. A little more range would be nice, because 100+ pearls on a string is a bit much.

Link to comment
Share on other sites

@Toadicus - No, performance hasn't been an issue but you mentioned needing a creative solution so I put in my ideas. I imagine most people don't have fifteen hundred satellites floating about, but usually that's what I plan for. I'm most certainly not insisting on more realism or complexity, I'm only speaking in the abstract. The nerd in me likes the idea of the relays talking to each other to form a living organism. I apologize for not meeting the fervor of your response but the basic idea I was describing is less of finding a path from each node back to Kerbin and simply nodes querying each other to find connections back to Kerbin. First I'd cache all transmit ships since those don't change often during the scene, and if they do it should be simple enough to add it at that time, or just grab the data directly from KSP and build a node table. Then, probably each frame, the next node from the list is selected and asked, 'do I have a connection to Kerbin?'. If no, check my recent connections if they have a connection to Kerbin. If yes, we're done. If the answer is no, or our connection is yellow, check all nodes in range and if they have a connection to Kerbin, or are connected to a node connected to Kerbin, cache it and give it an up time. If we check a recent node and it has no connection to Kerbin OR there is no connection to that node, reduce the up time. Since up time is basically just a priority search, as it goes down it becomes a less attractive target to check until it is pruned if it proves useless for a period of time. Once again, I'm not suggesting anything for this mod, but I think that would provide an interesting caveat to building relays in certain ways as nodes that are unreliable for periods of time are dropped as candidates, but might be searched as a positive connection once they are back in range. Certain odd constructions could lead to intermittent connection issues.

There are plenty of flaws here but like I said, it's just a on-paper suggestion. The actual logistics of implementation is pointless since I was completely off about how you decide connections anyways.

Link to comment
Share on other sites

As to the Antenna issue people are discussing, I found that by just moving the large dish up the tech tree, I haven't had any real issues. I've got it so once I get the small antenna, the next tech gives the medium, and the next tech gives the largest. You get them all relatively quick.

Link to comment
Share on other sites

I could maybe see that with just stock dishes but there are mods that have a good handful of dishes where it's hard to fit them in so you have to start changing AntennaRange settings and really IMO his ranges are to far, After all alot of us use this mods to make a networks not just throw one dish up and reach anywhere what fun is that thats whys we use this mods to cut the range of stock and, I have even cut alittle of the range of AntennaRange and thats even if, I'm using just stock dishs, I use this mod to build a network thats it now, I get pretty lines, I'm all happy kerbal for me the Communotron 88-88 would only reach duna and at times a very low com to jool.

I suppose it's ultimately a question of what is the intended gameplay purpose of AntennaRange? Is it intended to promote the construction of an intricately interconnected network of communications satellites? Or merely to provide a basic sense of progression, requiring players to unlock and use larger dishes to communicate longer distances? If toadicus' intent is closer to the latter, then the "Kerbin SOI -> inner planets -> outer planets" progression seems ideal. Also, while I am aware of mods that add dishes of various sizes, it seems to be important to toadicus that the mod function well with only the 3 stock antennae, which I think is a good decision. As such, it seems that the progression should be tuned around the 3 stock parts.

Link to comment
Share on other sites

With what three parts maybe four either way need more dishes to spread out the ranges or really why use the mod ? Guessing he started it because stock part had no limit and this little line right here

 rescaleFactor = * 

Can do magic and stay with stock but add more dishes and antennas to spread out the range alittle.

EDIT- Well take that back be more lines then that but not many, I give a example and this is a rough one

+PART[commDish]
{
@name = commDish2
@rescaleFactor = 0.5
@title = Communotron 44-44
@mass = 0.013

@MODULE[ModuleDataTransmitter]
{
@name = ModuleLimitedDataTransmitter
nominalRange = 40000000000
maxPowerFactor = 8
maxDataFactor = 4
}

%MODULE
{
name = ModuleScienceContainer

dataIsCollectable = true
dataIsStorable = false

storageRange = 2
}
}

And now we have more parts so we can spread it out :)

Edited by Mecripp2
Link to comment
Share on other sites

So, here are my current thoughts about revising the ranges on the antennæ. As I mentioned before, I think it's important that missions to Duna and the inner solar system be feasible before the 88-88 is available, because that's definitely how Stock's progression goes. But, I didn't want to just make the first two antennas even longer range without doing anything else to change things up a bit, so, here's my proposition:

  • The Comm. 16 gets a huge boost; out to just past Minmus, but not far enough for even a nearby solar probe. Otherwise, the behavior doesn't change at all.
  • The DTS also gets a huge boost; out to just past Duna, when Kerbin is on the other side of the sun. Careful planning could get you a Dres mission with this one. This antenna now also gets an extra boost to speed when used at short range, but has a shorter extended range.
  • The Comm. 88-88 stays roughly consistent; it can still reach well past Eeloo with a maximum range nerf of about 0.6%. Its nominal range, though, is nerfed by about 30% while its extended range is increased to make up the difference. This means the antenna spends more time getting a penalty to power use or data rate (depending on your option), and gets less of a bonus at short range. Hopefully this makes it less of a "cop out" part once you research it.

If I implement additive range, all of the range numbers would be cut exactly in half. Kerbin would have an equivalent range which would increase as you upgrade the tracking station, so you'd never have to build a home satellite network, but building deeper networks e.g. to get high speed communications from Jool using DTS relays might be more rewarding. IMO it's basically just a "more options" change, and doesn't enforce any added complexity.

Here's the patch, for the curious:

// Maximum distance 51,696 km, about 10% past Minmus
@PART[longAntenna]:FOR[AntennaRange]:NEEDS[!RemoteTech2]
{
@MODULE[ModuleDataTransmitter]
{
@name = ModuleLimitedDataTransmitter
nominalRange = 18277500
maxPowerFactor = 8
maxDataFactor = 4
}

MODULE
{
name = ModuleScienceContainer

dataIsCollectable = true
dataIsStorable = false

storageRange = 2
}
}

// Maximum distance 37,152,180 km, about 5% past Duna
// Bonus data transmission when at short range
@PART[mediumDishAntenna]:FOR[AntennaRange]:NEEDS[!RemoteTech2]
{
@MODULE[ModuleDataTransmitter]
{
@name = ModuleLimitedDataTransmitter
nominalRange = 18576090000
maxPowerFactor = 4
maxDataFactor = 8
}

MODULE
{
name = ModuleScienceContainer

dataIsCollectable = true
dataIsStorable = false

storageRange = 2
}
}

// Maximum distance 224,770,770 km, about 75% past Eeloo
@PART[commDish]:FOR[AntennaRange]:NEEDS[!RemoteTech2]
{
@MODULE[ModuleDataTransmitter]
{
@name = ModuleLimitedDataTransmitter
@packetResourceCost /= 1.414213
nominalRange = 56192692500
maxPowerFactor = 16
maxDataFactor = 2
}

MODULE
{
name = ModuleScienceContainer

dataIsCollectable = true
dataIsStorable = false

storageRange = 2
}
}

MeCripp, the problem with adding more parts via MM like that is that they still go away if AntennaRange is uninstalled, so you still break saves. For safest compatibility with otherwise-stock installations, a mod has to add zero parts. I'm not saying adding parts is never an option, but it's not something I will ever take lightly, and it would have to be optional, e.g. I would have to write conditional MM patches to rebalance the stock parts in response to the presence of the expansion parts.

Miravlix, that's dedication. ;)

Hyomoto, that's also dedication. ;) I'll re-read your stuff tomorrow and see if I come up with a response. :)

Link to comment
Share on other sites

So, here are my current thoughts about revising the ranges on the antennæ. As I mentioned before, I think it's important that missions to Duna and the inner solar system be feasible before the 88-88 is available, because that's definitely how Stock's progression goes. But, I didn't want to just make the first two antennas even longer range without doing anything else to change things up a bit, so, here's my proposition:

  • The Comm. 16 gets a huge boost; out to just past Minmus, but not far enough for even a nearby solar probe. Otherwise, the behavior doesn't change at all.
  • The DTS also gets a huge boost; out to just past Duna, when Kerbin is on the other side of the sun. Careful planning could get you a Dres mission with this one. This antenna now also gets an extra boost to speed when used at short range, but has a shorter extended range.
  • The Comm. 88-88 stays roughly consistent; it can still reach well past Eeloo with a maximum range nerf of about 0.6%. Its nominal range, though, is nerfed by about 30% while its extended range is increased to make up the difference. This means the antenna spends more time getting a penalty to power use or data rate (depending on your option), and gets less of a bonus at short range. Hopefully this makes it less of a "cop out" part once you research it.

If I implement additive range, all of the range numbers would be cut exactly in half. Kerbin would have an equivalent range which would increase as you upgrade the tracking station, so you'd never have to build a home satellite network, but building deeper networks e.g. to get high speed communications from Jool using DTS relays might be more rewarding. IMO it's basically just a "more options" change, and doesn't enforce any added complexity.

Here's the patch, for the curious:

// Maximum distance 51,696 km, about 10% past Minmus
@PART[longAntenna]:FOR[AntennaRange]:NEEDS[!RemoteTech2]
{
@MODULE[ModuleDataTransmitter]
{
@name = ModuleLimitedDataTransmitter
nominalRange = 18277500
maxPowerFactor = 8
maxDataFactor = 4
}

MODULE
{
name = ModuleScienceContainer

dataIsCollectable = true
dataIsStorable = false

storageRange = 2
}
}

// Maximum distance 37,152,180 km, about 5% past Duna
// Bonus data transmission when at short range
@PART[mediumDishAntenna]:FOR[AntennaRange]:NEEDS[!RemoteTech2]
{
@MODULE[ModuleDataTransmitter]
{
@name = ModuleLimitedDataTransmitter
nominalRange = 18576090000
maxPowerFactor = 4
maxDataFactor = 8
}

MODULE
{
name = ModuleScienceContainer

dataIsCollectable = true
dataIsStorable = false

storageRange = 2
}
}

// Maximum distance 224,770,770 km, about 75% past Eeloo
@PART[commDish]:FOR[AntennaRange]:NEEDS[!RemoteTech2]
{
@MODULE[ModuleDataTransmitter]
{
@name = ModuleLimitedDataTransmitter
@packetResourceCost /= 1.414213
nominalRange = 56192692500
maxPowerFactor = 16
maxDataFactor = 2
}

MODULE
{
name = ModuleScienceContainer

dataIsCollectable = true
dataIsStorable = false

storageRange = 2
}
}

MeCripp, the problem with adding more parts via MM like that is that they still go away if AntennaRange is uninstalled, so you still break saves. For safest compatibility with otherwise-stock installations, a mod has to add zero parts. I'm not saying adding parts is never an option, but it's not something I will ever take lightly, and it would have to be optional, e.g. I would have to write conditional MM patches to rebalance the stock parts in response to the presence of the expansion parts.

Miravlix, that's dedication. ;)

Hyomoto, that's also dedication. ;) I'll re-read your stuff tomorrow and see if I come up with a response. :)

I only understand about 1/3 of all that, but what I do understand, I like.

Link to comment
Share on other sites

Toadicus,

I've been considering the pros and cons of additive ranges. One advantage is that additive range ensures reciprocal connectivity. That is, it guarantees that if Antenna A can reach Antenna B, Antenna B can reach Antenna A. Given that the connections are being used both to send scientific data back to Kerbin, and to control probes from Kerbin (if the option is enabled), a reciprocal connection is intuitive.

On the other hand, I'm concerned that the range differences between antenna types would become relatively insignificant as you progress to higher tiers. Consider the following chart, which takes the maximum ranges from your post above (Comm 16 = 51696, DTS = 37152180, Comm 88-88 = 224770770), and applies the equation, Range = [Antenna A]/2 + [Antenna B]/2:

[table=width: 500]

[tr]

[td][/td]

[td]Comm 16[/td]

[td]DTS[/td]

[td]Comm 88-88[/td]

[/tr]

[tr]

[td]Comm 16[/td]

[td]5.17E+04[/td]

[td][/td]

[td][/td]

[/tr]

[tr]

[td]DTS[/td]

[td]1.86E+07[/td]

[td]3.72E+07[/td]

[td][/td]

[/tr]

[tr]

[td]Comm 88-88[/td]

[td]1.12E+08[/td]

[td]1.31E+08[/td]

[td]2.25E+08[/td]

[/tr]

[/table]

This problem could be mitigated using a non-linear equation. For example, Range = Sqrt([Antenna A]2 + [Antenna B]2), gives the following chart:

[table=width: 500]

[tr]

[td][/td]

[td]Comm 16[/td]

[td]DTS[/td]

[td]Comm 88-88[/td]

[/tr]

[tr]

[td]Comm 16[/td]

[td]5.17E+04[/td]

[td][/td]

[td][/td]

[/tr]

[tr]

[td]DTS[/td]

[td]1.39E+06[/td]

[td]3.72E+07[/td]

[td][/td]

[/tr]

[tr]

[td]Comm 88-88[/td]

[td]3.41E+06[/td]

[td]9.14E+07[/td]

[td]2.25E+08[/td]

[/tr]

[/table]

Edit:

If you want something in-between the two above options, you could play around with X in the following equation:

Range = (([Antenna A]^(1/X))/2 + ([Antenna B]^(1/X))/2)^X

At X = 1, it is identical to the first equation above. As X approaches infinity, it becomes equivalent to the second equation. At X = 2.8, the range of Comm 16 + Comm 88-88 ≈ DTS + DTS, which strikes me as a nice balance.

Edited by Fraz86
Link to comment
Share on other sites

And some cosmetic requests:

1. a hotkey/button during flight to toggle the pretty lines - to much on screen during node/orbit contemplation

2. pretty lines only checking once every second (or so, maybe even rarer) if range/line of sight are ok - at least I think that is the reason for what I would describe as a laser show :wink:

Link to comment
Share on other sites

I just spent way too long looking at antenna theory and doing maths, and it looks like that's not far off from how antennas actually work. I may just do gain modeling instead of additive range; get it done right. ;)

- - - Updated - - -

Update: KerbMav, I'll add both of those to the to-do list; for item #2 I'll make the refresh rate configurable.

Link to comment
Share on other sites

New dev build up! Fewer tech changes, more gameplay changes. The gameplay changes are pretty significant, but I think it'll provide a more rewarding experience when used with stock contracts.

[zip] [tar.gz] [tar.xz]

CHANGELOG:

* Range changes to all three antennas, see [URL="http://forum.kerbalspaceprogram.com/threads/56440?p=1974841#post1974841"]here[/URL].
* No longer hangs / crashes the game in certain circumstances at high warp.
* No longer checks for LOS when we're not enforcing it.
* Added support for "update delay" to the space center config. Minimum delay is 16ms, max is 2500ms.
* Added Pretty Lines toggle functionality to the map mode buttons.

Edited by toadicus
Link to comment
Share on other sites

Wooo, TEST ALL THE THINGS!!!!

I am bad at math, so how are these additive ranges going to affect custom made CFGs for other antenna parts? Will we need to add these additive ranges to the custom CFGs? It will not be only nominal and max ranges anymore?

Link to comment
Share on other sites

FYI, in the real world, we check link budgets by adding up gains; because gains are in decibels, which are logarithmic, the equivalent formula for AntennaRange would be to multiply ranges. A decent formula would probably be the geometric mean of the maximum ranges (i.e. sqrt(range1*range2)), which would be compared to the distance to see if the link closes. You could then take the geometric mean of the nominal ranges and compare that to the actual range to work out power and bandwidth impacts.

For the numbers in your patch, the max-range results are:

[TABLE=width: 500, align: left]

[TR]

[TD]Range (m)[/TD]

[TD]Comm 16[/TD]

[TD]DTS-M1[/TD]

[TD]Comm 88-88[/TD]

[/TR]

[TR]

[TD]Comm 16[/TD]

[TD]5.17e7[/TD]

[TD][/TD]

[TD][/TD]

[/TR]

[TR]

[TD]DTS-M1[/TD]

[TD]1.4e9[/TD]

[TD]3.72e10[/TD]

[TD][/TD]

[/TR]

[TR]

[TD]Comm 88-88[/TD]

[TD]3.41e9[/TD]

[TD]9.15e10[/TD]

[TD]2.25e11[/TD]

[/TR]

[/TABLE]

1.4 million km (the Comm 16 to DTS-M1 range) isn't far enough to reach any planets (though it may be suitable for near-Kerbin asteroid missions), but would be long enough for Comm 16s on the moons of Jool to chat with DTS-M1s or Comm 88-88s in Jool orbit (in fact, an 88-88 could talk to any antenna in Jool's SOI), which could then relay back to Kerbin, making for a more aesthetically pleasing Jool network than the current "every moon gets an 88-88 and talks directly to Kerbin" approach (because the stock DTS-M1 -- current dev release aside -- cannot reach Jool from Pol or Bop). This would allow mini-probes too small for a DTS-M1 to be useful for outer solar-system exploration (maybe after being carried out to the system by a mothership -- think Cassini-Huygens).

If you incorporate tracking-station upgrades, then each level could correspond to the next level of antenna. (It would be great if this could be in a config as well, so that e.g. Outer Planets Mod could patch the level 3 station to reach all the way out to Plock or whatever the last planet is.)

Edit: I see that these numbers are similar to the RMS numbers that Fraz86 generated, so if that operation is more efficient, it wouldn't be far from the truth.

Edited by Kerbas_ad_astra
Link to comment
Share on other sites

Fraz86, Kerbas_ad_astra (et al), I'm working on an implementation using the geometric mean, which looks to be working well so far. It also means that relays will prefer "better" connections over "closer" ones, e.g. a distant ship will usually talk straight back to an upgraded Kerbin instead of to a satellite in LKO with a Comm 16, even if the latter is in range, which I think is fairly cool.

Link to comment
Share on other sites

Fraz86, Kerbas_ad_astra (et al), I'm working on an implementation using the geometric mean, which looks to be working well so far. It also means that relays will prefer "better" connections over "closer" ones, e.g. a distant ship will usually talk straight back to an upgraded Kerbin instead of to a satellite in LKO with a Comm 16, even if the latter is in range, which I think is fairly cool.

Excellent! Now my poor Kerbin scanners can focus on scanning instead of serving as a relay for my entire Mun constellation. :)

Link to comment
Share on other sites

The geometrically-additive ranges work in the lab; I'll get a dev build up tonight. :) Also a handful of other minor improvements: transmit ranges show up properly in the right-click menu when you're out of range, links to Kerbin will correctly show as "Blocked by XX" when they are thusly blocked.

Also, DudewHorns, sorry for your misfortune. Just remember... you can't stop the signal. ;)

Link to comment
Share on other sites

Dev build is up! [zip] [tar.gz] [tar.xz]

CHANGELOG:

* Range changes to all three antennas, see [URL="http://forum.kerbalspaceprogram.com/threads/56440?p=1974841#post1974841"]here[/URL].
* Antenna ranges are now "additive" using the geometric mean of both antennas in the link. Kerbin's range scales up as you upgrade the Tracking Station.
* Added support for "update delay" to the space center config. Minimum delay is 16ms, max is 2500ms.
* Added Pretty Lines toggle functionality to the map mode buttons.
* No longer hangs / crashes the game in certain circumstances at high warp.
* No longer checks for LOS when we're not enforcing it.
* Transmit distance is now correctly shown when the target relay is out of range.
* Context menus will now correctly report Kerbin as "Blocked by <Something>" when it is thusly blocked.

- - - Updated - - -

Update: Just put in a toggle for additive ranges (defaults to on). If you don't like it, turn it off! :)

Link to comment
Share on other sites

Yay. Now I get to play with the custom MM cfg that someone made for the Origami dishes. Unless you want to support them via your own MM?

This is what I have now(pre-additive range, which I still don't understand):


# Reduce Toadicus' range for Communotron 16
@PART[longAntenna]:AFTER[AntennaRange]:NEEDS[!RemoteTech2]
{
@MODULE[ModuleLimitedDataTransmitter]
{
@nominalRange = 1500000
}
}

# Reduce Toadicus' range for Comms DTS-1
@PART[mediumDishAntenna]:AFTER[AntennaRange]:NEEDS[!RemoteTech2]
{
@MODULE[ModuleLimitedDataTransmitter]
{
@nominalRange = 7000000
}
}

# Reduce Toadicus' range for Communotron 88-88
@PART[commDish]:AFTER[AntennaRange]:NEEDS[!RemoteTech2]
{

@TechRequired = electrics

@MODULE[ModuleLimitedDataTransmitter]
{
@nominalRange = 20000000
}
}

// Add the Origami 69Gm Dish
@PART[NAU_ORI69Gm]:FOR[AntennaRange]:NEEDS[!RemoteTech2]
{
%TechRequired = electronics

@MODULE[ModuleDataTransmitter]
{
@name = ModuleLimitedDataTransmitter
nominalRange = 30000000000
maxPowerFactor = 8
maxDataFactor = 4
}

MODULE
{
name = ModuleScienceContainer

dataIsCollectable = true
dataIsStorable = false

storageRange = 2
}
}

// Add the Origami 350Gm Dish
@PART[NAU_ORI350Gm]:FOR[AntennaRange]:NEEDS[!RemoteTech2]
{
%TechRequired = specializedElectrics

@MODULE[ModuleDataTransmitter]
{
@name = ModuleLimitedDataTransmitter
nominalRange = 150000000000
maxPowerFactor = 8
maxDataFactor = 4
}

MODULE
{
name = ModuleScienceContainer

dataIsCollectable = true
dataIsStorable = false

storageRange = 2
}
}

I don't know how additive ranges will affect the so put additive ones, but I will try to do something with it and post it here.

I also can't seem to transfer the Nominal range to meters or kilometers, what is the used measurement and what is the starting point? Kerbol? Because, for example Minmus is about 46,000.00 km away from Kerbin, but the Communotron 16's range comment states that it has "Maximum distance 51696km, about 10% past Minmus", but the nominal range of the antenna is 18277500.

My plan for now is to have the following:

1. Long antenna(16) - Lander antenna - So a range of no more than 3 Mm

Link to comment
Share on other sites

smunisto, a cool thing about using the geometric mean is that we don't need to adjust the ranges unless we're trying to accomplish a different result. Ranges are calculated like this:

√(r1×r2)

So, if you've got two similar antennæ, like your modified commDish:

√(20000000×20000000) = 20000000

What's more interesting is dissimilar pairs. For example, your commDish and your 69Gm dish:

√(20000000×30000000000) = 774596669

This is a much short range than the arithmetic mean:

(20000000 ÷ 2 + 30000000000 ÷ 2) = 15010000000

It's a more interesting result, and a more realistic result, and it doesn't have the effect of making every antenna an everywhere antenna the moment you unlock tracking station level 3.

Here's a terrible calculator I whipped up to help you see how different combinations will affect each other: http://ksp.hawkbats.com/geo_add.php

Link to comment
Share on other sites

This thread is quite old. Please consider starting a new thread rather than reviving this one.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...