cc-tweaked / CC-Tweaked

Just another ComputerCraft fork
https://tweaked.cc
891 stars 208 forks source link

Rebalancing Ender Modems #955

Open SquidDev opened 2 years ago

SquidDev commented 2 years ago

TLDR: Ender modems are OP.

CC 1.6 introduced the repeat program, which allows rednet to relay messages between computers. The intent here was to allow more long-distance wireless communication through the use of repeater stations. However, 18 months later CC introduced ender modems, which allow for infinite range communication, making both wired modems and the repeat system obsolete.

Nowadays there's very little reason to craft a normal wireless modem, aside from very early game. This has several side effects:

This has undoubtedly made things easier and more accessible, and so I don't think there's any harm leaving things as is. However, modded Minecraft (tech mods especially) is basically a big infrastructure management game. It makes me sad that CC trivialised one of its hardest problems, and it would be nice to rebalance things.

I think I'd propose the following changes:

Basically what I'm trying to encourage is having to think about (and build) infrastructure around your turtle setups. You can't just plonk down a few turtles and set your mining swarm loose. You need to place down an ender modem to communicate with them over a long distance, need to make sure they stay within range of the repeater station. Maybe you need a GPS tower too?

I don't know, maybe this is just adding complexity for the sake of it[^2]. I'm very wary that what I'm suggesting here is making things actively harder for the player, maybe it's just too late to change things. Thoughts?

[^1]: While the BitNet Communication Tower is not the aesthetic I'm going for, I do really like the concept and mechanics - definitely an inspiration here. [^2]: And I'm very aware that CC (CC:T especially) has far more OP features. Looking at you item transfer.

EmmaKnijn commented 1 year ago

@Lupus590 Yup, SquidDev has talked about how this should be a tweak.

I really don't want to add any new mechanics here, just tweak existing ones. Same goes for energy costs, which I know were mentioned elsewhere.

powerboat9 commented 1 year ago

Maybe give ender modems only ~16 times the range of a normal modem, but allow them to spoof their location? An ender modem at (0, 64, 0) in the overworld could be reconfigured to act as if it was at (5000, 64, 5000) in the nether for the purposes of range/distance calculation. You'd have to use some offset based off the modem's position and rotation.

EmmaKnijn commented 1 year ago

@powerboat9 Why would spoofing the location help? That is just a sidegrade from the current modem, can just grab enough modems, place them centrally and repeat commands, infinite range in theory

EmmaKnijn commented 1 year ago

I'd propose a larger range, and mapping the ender modem to be in the end and nether. In the end just a direct map and in the nether a 8x map. In case of the modem being placed in the nether just scale the map 8x down for the other dimensions

powerboat9 commented 1 year ago

@powerboat9 Why would spoofing the location help? That is just a sidegrade from the current modem, can just grab enough modems, place them centrally and repeat commands, infinite range in theory

You can always get practically infinite range by placing enough modems. Location spoofing would add a directional element to long range ender modem usage, incentivizing the creation of more complex repeater networks for long distance communication (one ender modem for settlement 1 <-> 2, one for 1 <-> 3, one with a custom program to track the player and their pocket computer, one to handle settlement 1 <-> blaze farm, etc.).

osmarks commented 1 year ago

Configurable locations are an interesting intermediate point between linked modems and the current anywhere-to-anywhere thing.

rdrpenguin04 commented 1 year ago

Would 1.20 be a good update to do this on?

ajh123 commented 1 year ago

Would 1.20 be a good update to do this on?

Probably, its a nice round number.

SquidDev commented 5 months ago

One can build a single GPS tower at spawn and cater to the whole server.

One of the major blockers I've had here is what to do about GPS. I don't feel great about how trivial GPS is right now, but having access to GPS everywhere is incredibly useful, especially for pocket computers.

The design in the OP makes ender modems (or ansibles, following Wojbie's suggestion) a one-way long-range modem, which means that GPS would no longer work from normal wireless modems (as the initial PING would never be received). However, I was discussing this elsewhere, and it occurred to me that we could still allow for server-wide GPS if GPS hosts broadcasted a position packet periodically (every second or so). This way normal wireless modems will still receive the position packet and so will be able to trilaterate, just with higher latency.

Obviously we can't actually enforce how often the position packet is broadcast (you could write a program to do it every tick). Which is a bit of a shame - it would give you a nice tradeoff of local GPS (immediate) vs server wide (some delay, and thus less accurate) - but I don't think there's any way we can practically limit the number of modem messages if someone really wants to send them.

powerboat9 commented 5 months ago

Could modems have a distance beyond which messages to/from them don't come with distance information? It would prevent GPS from working at longer ranges, but keep long range message transmission.

Lupus590 commented 5 months ago

Maybe ender modems don't have a distance return value at all and thus can't be used for GPS.

osmarks commented 5 months ago

Distances at long ranges could have added noise (scaling with distance), but this would break a lot of things and require smarter numerical algorithms in GPS.

powerboat9 commented 5 months ago

Distances at long ranges could have added noise (scaling with distance), but this would break a lot of things and require smarter numerical algorithms in GPS.

That would incentivize modem spam in order to average out the noise, unless the noise could be made systematic.

EmmaKnijn commented 5 months ago

I just thought of a couple things, including adding latency, adding packet loss (both depending on range from an ender modem) along with decreasing overall range. You could also change the throughput of modem messages scaling with distance. While offering upgrades with something like nether stars increasing one parameter a bit per nether star. This is more akin to a real life cellular network and is reasonably easily balanced by changing base stats and upgrade amounts.

KnightMiner commented 5 months ago

I would be warry of any solution which just requires the player to add more ender modems to compensate. A lot of people download programs, so such a thing would just lead to more ticking block entities for the same result.

osmarks commented 5 months ago

You could design against modem spam by doing things like limiting transmissions in an area by channel or group of channels and making distance errors systematic and variable by location, but at some point you would just be reinventing real-world radio and it could get annoying.

powerboat9 commented 5 months ago

Ender modems being able to spoof their location would work well with a smaller distance measurement range, especially if time/energy is required to retarget ender modems. You could still set up a GPS for your pocket computer (location spoofing with small changes in location over time), but multiple GPS towers would be incentivized.

powerboat9 commented 5 months ago

On second thought, GPS which dynamically retargets a pocket computer as described above would require knowledge of the pocket computer's current location, requiring some form of GPS access to begin with

MageCoven commented 2 months ago

I am very much in favor of adding a config for making Ender Modems only talk with other Ender Modems. It would make it very easy to balance them on a per server basis, especially if recipes can be modified with data packs. Making it a config will let the players make the choice of keeping it as it was or to use the change.

Since Wireless Modems have a longer range the higher up they are it would allow for some variable distance and additional difficulty in setup of relays that can cover an area. Although I don't even know how practical it would be with the current implementation of the variable range since I never had a reason to use it due to Ender Modems.

One could even have an area that is covered by a bunch of Wireless Modems and a central server that has both an Ender Modem and a Wireless Modem to talk between areas when there is a vast distance/different dimensions.

The GPS script could also probably be changed so that it would work more like how satellites work with only needing a connection to the closest three and outside the area it would need an Ender Modem to work. Although this would probably lead to Ender Modems being spammed whenever GPS is needed, but I suppose that if the server owner wants to avoid Ender Modem spam then they could change the recipe themselves.

Making it an opt-in option would also solve compatibility since it would have to be up to the server owner whether to change it or not.

powerboat9 commented 2 months ago

Another possibility would be using the communication range of the normal wireless modem during normal<->ender modem communication.

As a separate suggestion, in order to allow GPS to continue working, ender modems could be allowed to "overcharge" themselves for a single transmission. The transmission would have to be limited in size (number or <=32 byte string?) and would start a (~5 second? ~10 second? ~30 second?) cool down before the modem could be used again, but would bypass ender modem nerfs. This would incentivize local GPS relative to global GPS, but allow global GPS to still work in a limited fashion.