PDA

View Full Version : How is the Lightning Rod Supposed to Work?


Sophie-David
3rd Jan 2008, 05:24 PM
Frankly I haven't played too much with the weather in Seasons and up until now had never used a lightning rod. My recent antenna project (http://www.modthesims2.com/showthread.php?p=1860089#post1860089) was based on a Seasons lightning rod, and after it was completed I realized that it should behave like one.

In looking at the BHAV coding later I can see that there is some GUID specific code that looks for the original lightning rod GUID, but that is not my concern at the moment. I have been using Paladin's (http://www.simwardrobe.com/) "Wrath of the Gods" object to induce lightning - and Paladin specifically says that he just calls the game's built-in lightning code to produce the effect (I haven't checked this yet). I used a hack-free AnyGameStarter environment, with just Seasons and Nightlife installed.

What I found was that neither my antenna nor the Seasons lightning rod ever took a direct hit from lightning. Instead the lightning would go everywhere else in the yard, but particularly to the trees. I did run tests in a treeless yard also, so then the lightning had to look for little objects like outdoor lights to strike instead. Is this the way the lightning rod is supposed to work, erecting some kind of forcefield so that lightning never strikes the rod or the house, but hits the trees instead? This seems like a very unrealistic way for a lightning rod to work!

I have found that the lightning rod is flagged as "Lightning Strikeable" (Attribute 10H), so it is not immune to lightning. However the probability seems low. I am just curious if anyone has ever seen lightning strike the lightning rod during game play.

Rapsheba555
4th Jan 2008, 10:45 PM
Yeah, it happened to me. I actually played with it using the weather machine, and made a thunderstorm. I put it next to a sim, and after 3 hours(real-time) it finally struck, not the sim, but the rod. That's probably just a conicidence. I don't think it prevents lightning from striking anything else, I think that it's just another option for the lightning to strike. I think it works better when it's on a roof though, because that's how it's supposed to work. Also, i don't think lightning CAN strike a house or roof. I think the rod is just more for effect.

Sophie-David
4th Jan 2008, 11:54 PM
Thank you for the information, Raphsheba. At least you have seen it happen. But three hours real time makes it very low odds. Probably in that same period it was striking everywhere else.

Actually it looks to me like the lightning strike code is not sophisticated enough to discriminate according to height. That is also what have I observed in my tests so far - it didn't matter where I put the other objects. I had some little lights that were on a flat roof, and the lightning really liked those. But when I moved them to ground level it liked them just as much. And I have noticed that it likes little trees and bushes as much as big ones.

Lightning just prefers some objects a lot more than others, and the lightning rod seems to be at the bottom of the list. I think that's literally true, the lightning rod has its own BHAV that is called after all several other object types are called, including Sims. There is however some randomness built-in, so occasionally the lightning should strike the rod, as you have seen.

So I am coming to the conclusion that the antenna is acting just like the lightning rod, so in a sense that is just fine. But perhaps I should take the opportunity to make the antenna more attractive, and therefore behave more the way that the lightning rod should behave. I will think about that.

Phaenoh
5th Jan 2008, 05:09 AM
Perhaps you could come up with a mod that changes the probability of lightning hitting trees? I have never used it (didn't know we had them till I saw your post) and lightning ALWAYS goes for my trees. Currently I've got one thats glitched so it is still on fire 3 sim days later. Cool effect for my Mad Scientist's house, but annoying all the same.

Sophie-David
5th Jan 2008, 04:01 PM
Yes, I am so fed up with the behaviour of this so-called lightning rod that it is going right to the top of the list to make a patch for it! It is incredible that it took three real time hours for a strike to hit it. I guess I haven't had quite enough patience so I have yet to see it happen!

Sophie-David
6th Jan 2008, 11:22 PM
After further experimentation and study of the code, I have found that the lightning rod works very well at attracting lightning, provided it is located on the ground or on a flat roof. It appears that when it is placed on a sloping roof, the game considers that it is located inside a building. Lightning is not permitted to strike objects located inside a building.

Having discovered that the problem occurs at a very fundamental level, I have no further plans to make a patch for the lightning rod.