RimWorld

RimWorld

Self Lit Hydroponics
44 Comments
OganessonG 19 May @ 1:21am 
Hi Aidan,
I am trying to make a sun lamp mod that illuminates square areas instead of vanilla circle ones, and could I use some part of your code? Thanks!
cosmicpintobean 16 May @ 8:17pm 
Is this safe to remove if you have hydroponics? It's not working and my crops are dying so I need to use regular sunlamps
Vaarelsauce 4 May @ 10:20pm 
goated mod, even after the lights 1.5 bug/feature
Vartarhoz 19 Apr @ 2:21am 
I wish this mod adds another one instead of editing already one, because sometimes you don't need light of hydroponic only soil of it. (aka deserts)
Preen 1 Oct, 2023 @ 7:18am 
Being able to place these basins in any pattern or quantity is a huge advantage over vanilla sunlamp . 250 seems reasonable to give these a practical use (like the 5 basins in the picture) without totally invalidating vanilla sunlamps.
Rivelda 30 Sep, 2023 @ 11:02am 
Or at least instead of 250W, 200W would be a nice round number if you want to incur a small penalty for using neat self-lit basins over a sun lamp with regular hydroponics.
General Profit 23 Apr, 2023 @ 2:28am 
I thought it worth mentioning that with 250W as default output when lit it is costing you far more in power than a regular sunlamp with hydroponics

You can get 24 regular hydroponics per sun lamp, a sun lamp costing 2900w of power, so 4580 for 24 regular hydroponics+sun lamp, 1680 during night time

24 self lit would require 6000 per day, 1680 per night

So to determine the average that a self lit should have during the day would be 4580/24, this gets us 190.833333333 which we can just round up to 191 or round down to 190 to get as close to matching the same power use value as a regular sun lamp+hydroponics
lordneador 29 Oct, 2022 @ 1:16am 
@Aidan I wondered if that was the problem, yet (with plants planted) the light were off for the whole day, until I cycled the basins power on/off once... Quick fix would most likely be to turn of said option in the settings
Aidan  [author] 28 Oct, 2022 @ 3:57pm 
@lordneador

The lights mirror the plant resting period by default (when `On Schedule` mod setting is enabled) and so the lights should turn back on around 6/7h in the morning.
lordneador 28 Oct, 2022 @ 2:48pm 
Ive got the problem that the basins shut of their light at night, but dont turn it on again. Is this known and is there a cause or fix? Ty in advance :)
ZzZombo 23 Oct, 2022 @ 8:27am 
Error in static constructor of SelfLitHydroponics.OnStartUp: System.TypeInitializationException: The type initializer for 'SelfLitHydroponics.OnStartUp' threw an exception. ---> System.NullReferenceException: Object reference not set to an instance of an object
at SelfLitHydroponics.SelfLitHydroponics.SetPowerConsumption () [0x0002f] in <05a6e254e6b94951adf4481f7590013c>:0
at SelfLitHydroponics.OnStartUp..cctor () [0x00007] in <05a6e254e6b94951adf4481f7590013c>:0
--- End of inner exception stack trace ---
MercuryDoll 14 May, 2021 @ 11:02am 
Would it be possible to add a gizmo to manually toggle the lights off? For plants (mostly mushrooms) that die in light and need darkness to grow.
[82AD] era 25 Apr, 2021 @ 8:56am 
Any chance we get compatibility for the farming module of Vanilla Expanded?
Aidan  [author] 4 Oct, 2020 @ 9:22am 
@MysticForces

So I've just downloaded that mod and tried to uninstall and reinstall the Hydroponics Basin. The lights seem to despawn for me upon the basin being minified :/ So perhaps a different mod is causing the problem?
MysticForces 29 Sep, 2020 @ 12:53pm 
Minify Everything
https://steamproxy.net/sharedfiles/filedetails/?id=872762753

But it's almost becoming ungentlemanly to ask someone about his mods. All of them okay. I use all of them. *sob* ;)
Aidan  [author] 28 Sep, 2020 @ 10:56am 
@MysticForces

Hey, I don't use any mods that allow the Hydroponics Basin to be uninstalled. Which mod are using so I can take a look?
MysticForces 27 Sep, 2020 @ 11:50am 
When you uninstall a self lit hydroponics basin it creates a hydroponics basin and a hydroponics light. The hydroponics light can't be destroyed or sold and doesn't deteriorate so you're pretty stuck with it. Any ideas?
Aidan  [author] 4 Aug, 2020 @ 12:12pm 
That weird, I've just tried a fresh install and mine was 250W / 70W.

Does it keep its value if you change it from 0W ?
Jacki 4 Aug, 2020 @ 12:07pm 
The mod's settings are by default 0W when lights are on, 70W when lights are off
Aidan  [author] 4 Aug, 2020 @ 12:06pm 
Was that in the Mod Settings or during play?
Jacki 4 Aug, 2020 @ 11:57am 
I have discovered 1 possible issues, when activating the mod, it's by default set to use 0W while it's on and 70W when it's off.
Aidan  [author] 4 Aug, 2020 @ 9:58am 
@Jacky

Happy to help :) Let me know if you have any issues!
Jacki 4 Aug, 2020 @ 9:43am 
Dude, I had put my save on hold for this moment, thank you so much, I didn't expect it to be done so fast. <3
Aidan  [author] 4 Aug, 2020 @ 8:49am 
@Jacky

Power consumption is now tweakable :)
Jacki 4 Aug, 2020 @ 7:30am 
I am just happy you are able to fill out a niche I didn't even know I had until I saw this mod.
Aidan  [author] 4 Aug, 2020 @ 7:10am 
@Jacky

Thanks for the suggestion and the maths! I'll look at adding that as a mod setting :)
Jacki 4 Aug, 2020 @ 6:27am 
I really want to use this mod for an alternate way to make hydroponic labs, but it costs 50% more power than using a sun lamp.

I would adore if you'd allow us to tweak the power usage settings, since 190W when it's on would make it exactly as if you were to use a sun lamp instead.

24 basins can be powered by a single sunlamp, which is 96 growable tiles;
2900W ÷ 96 = 30,2W per plant
(250 - 70) * 24 ÷ 96 = 45,9W per plant.
Aidan  [author] 26 Jul, 2020 @ 8:06am 
You can now toggle if you wish the Hydroponics Basin to work on a schedule or not.
Aidan  [author] 26 Jul, 2020 @ 7:20am 
@r3xm0rt1s

Sure I'll look at adding that as an option in the Mod Settings :)
r3xm0rt1s 26 Jul, 2020 @ 6:50am 
Might you add an option to grow plants all day? It was the primary reason I got the mod. I suppose that makes the game easier but I just want to grow stuff faster.
Aidan  [author] 26 Jul, 2020 @ 3:02am 
Just updated the mod so the Hydroponics Basin now works on a schedule.

It will be off during the plant resting period and so will require 70W (Same as Vanilla). It will turn back on during the plant growing period and require 250W.
Aidan  [author] 14 Jul, 2020 @ 12:11am 
@Liwet

Ah, can't believe I didn't notice that...

I've fixed it now however, you may need to use the Dev Mode Destroy to cleanup any extra light if it isn't deleted after reloading though. Or you can edit the save file itself and remove the `HydroponicsLight` at the position you wish to remove...

Alternatively disable this mod, load your save, save your save, re-enable the mod and load your save again and everything should be fine :) (You'll probably get error messages after disabling the mod but this is seemingly harmless)

Please let me know if you have any issues ^^
Liwet 13 Jul, 2020 @ 5:08pm 
@Aiden

Lighting range and strength looks good, I got no other changes to recommend on that front. However, there does seem to be a slight bug when arranging a basin vertically. There's 1 spot above the basin that's 100% light and the bottom spot of the basin itself is 50%. The lights just need to be shifted down 1 spot for the vertical arrangement.
Aidan  [author] 11 Jul, 2020 @ 2:54pm 
Just rolled out another update. The 100% light is now confined to just the Hydroponics Basin.

Please let me know if you have any issues :)
Aidan  [author] 9 Jul, 2020 @ 8:23am 
I've rolled out an update to allow you to toggle between the light being purple and white (it is purple by default) and also nerfed the light radius a little. Please let me know if there are any issues :)

@Liwet

I did not realise it what was that bad, thanks for pointing it out! I've nerfed it a little now so it shouldn't be as bad. I'll continue looking at how I can confine it more...
Liwet 9 Jul, 2020 @ 6:21am 
Like 50% light or less should be ok but once you hit 51%, you can stick a hydroponics basin inside a garden area and use its light to grow plants. It lights up 41 spots around it at 100% light.
Aidan  [author] 9 Jul, 2020 @ 3:39am 
@Liwet

I'll add some Mod Settings in the next few days so that the colour of the light can be set by the user themselves or at the very least give the option to toggle between white and purple.

I'll also look into how confining the light would work, but can't make any promises on that just yet.
Liwet 8 Jul, 2020 @ 12:48pm 
@BestToasterNA

I think that might have been me!

@WaxWorm

But how much power do they require? It's break even at 191 power per basin but this leaves in the paradox that exists with the vanilla basins: you can grow enough rice to turn into chemfuel to power the basins with chemfuel generators and still have some rice left over.

@Aidan

Any chance we can get a toggle for the light to make it white instead?

And can you confine the light to the hydroponics basin only? They are generating 100% light on the ground around them
Spectre Incarnate 8 Jul, 2020 @ 10:31am 
@WaxWorm I've never liked those ones. These have purple lighting and feels like the light is coming from above the tables with a soft glow instead of resembling a gaudy fashion runway. :P
GoldLeader 6 Jul, 2020 @ 9:34am 
This is great because having to come up with 2900W just to turn up a single table is crazy. Looks really cool in that purple color too. Nice job.
BestToasterNA 4 Jul, 2020 @ 4:20pm 
Well yeah but these look cool
WaxWorm 4 Jul, 2020 @ 11:45am 
Hydroponics with integrated sunlamps have been a thing for years though.

https://steamproxy.net/sharedfiles/filedetails/?id=943373441 and https://steamproxy.net/sharedfiles/filedetails/?id=1330587565 for example.

But the UV-style light looks nice.
j.gladfly 3 Jul, 2020 @ 11:42pm 
From meme to mod in two days. Nice!
BestToasterNA 3 Jul, 2020 @ 5:06pm 
I just saw someone talking about this exact mod and here it is