Neo Hazard Lights

by Mernom

Hazard lights, reimagined using entity based technology. Based on Hazard lights by SpaceCat-Chan.

Utilities
1 year, 6 months ago
1.1
426

g credit ?

2 years ago

My mod is based on the original. Credit is due, but to Space cat.

2 years ago

you have the same name, the same code, x)
for originality we'll have to go back to the drawing board.

2 years ago

I have been the maintainer for several years spacecat has not given any news since

2 years ago
(updated 2 years ago)

I do NOT have the same code. I rewrote it from scratch, to achieve the purpose the original had, using an approach that hopefully won't have nearly as much of a UPS impact.
Actually, I'm not sure if saying 'rewrote' is even applicable, since I made it from zero. Nothing was transfered.

2 years ago

cool, would it be possible to work together, then?
I would love to propose an update to the mods I maintain to reduce UPS,
and an option for your colours.
I'd like to see a mod for the vanilla buildings and a mod for the modded ones.

If you have a solution for the red spots that sometimes remain after deleting a building.

2 years ago

Before making this, I tried fixing the original for personal use (I think this was before you took them over), but the code was so antiquated and difficult to read I gave up on it. I don't know if fixing the UPS loss is possible: it's a consequence of using the rendering engine. There are all sorts of weird quirks about it IIRC (for example, sometimes removing all renders and remaking them all is more efficient than removing one render), so it might not be possible to make it work well on a large scale. When I tried, it tanked my ~60 ups game to ~1 ups.

This variant uses entities instead: Spawning 4 small lamps around the entity in question. This avoids the rendering engine entirely, instead increasing the entity count. It also could impose a UPS impact at very large bases, but that can't be helped, except manually removing some of the redundant lights.

To fix your UPS problem, you'd probably need to follow in my tracks and change the approach entirely. At that point, the distinction between the two kinda vanishes...
Also, I don't see a reason to make a distinction between vanilla and modded buildings, I just slap them on on any compatible entity type, as long as it's bigger than a certain value.

Didn't Hazard lights already have a color option? I remember it definitely had some, not sure how well it worked though. My colors simply copy the color values the vanilla lamp can take off of signals.

2 years ago

Would you be willing to discuss on discord with me about the evolution of our respective mods? I would be very curious to know how to reduce the UPS load.
Dae#5125

2 years ago

I have no idea how to pm someone I have no existing contact with. I'm on the SE server, you can contact me from there.

1 year, 11 months ago
(updated 1 year, 11 months ago)

oh hi there
cool stuff, thanks for the credit

but the code was so antiquated and difficult to read I gave up on it

yeah, plain just true

it's unlikely i will ever go back to working on things hazard lights related, i'll let you two take over and do as you wish with the mod and idea

New response