Jump to content

ohgodspidersno

Member
  • Content Count

    136
  • Joined

  • Last visited

About ohgodspidersno

  • Rank
    Advanced Member

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. I can't find anything in the code. It might just be in the Java with no way for us to access it via lua. Perhaps you could try changing the item lighbulb to have MaxCondition = 1500 ?
  2. Oh yea, that. I always thought that was weird, especially since the lamps you find in the world don't ever need to be replaced
  3. Is it possible to make the game reload xml files whenever the player enables/disables a mod that changes them? Right now it only seems to reload lua files and txt scripts.
  4. Clothes that you find on zombies should always be 100% dirty
  5. I'm quite certain I didn't accidentally destroy it myself. I have a backup from earlier to do a side-by-side. Before leaving on a looting trip: after returning:
  6. So you want to lower the amount of power they drain from a generator?
  7. Zombies are biting me but it does no damage, makes no sound, and my character doesn't react. I am carrying a large flashlight in my primary hand, a duffelbag in my right, and a hiking bag on my back (with two attachment points from that mod). I am also have an "Extremely Heavy Load" moodle.
  8. Perhaps, but it might be realism. I feel like it would be exceedingly difficult to light a molotov cocktail using a match in one hand.
  9. One thing I've learned is that whenever you change xml files you need to quit and reboot the game for the changes to show up. You probably knew that already, but it really threw me for a loop because it seemed like no matter what I changed it didn't affect anything in the game, when really I just wasn't actually loading the changes
  10. Do you want to make it You're welcome! Do you want the lamps to work even if they aren't linked to a power source?
  11. Here's another anecdote: I got infected with "Never", took antibiotics, and then the moodle went away. However, it came back, so I took another round of antibiotics to make it go away. It came back a third time and this time I had no antibiotics so I died. I wish I could try again and see if 1. Taking a third round would have been enough to save me 2. Taking two rounds back to back, rather than waiting for the infection to regain strength, would have cured me permanently
  12. I discovered a trick to get more out of gas runs. It's probably common knowledge, though, since it's quite easy to stumble into it. 1. In your main inventory, have as many fuel cans as you can possibly hold 2. Fill them all up at the pump. Don't set any of them down. 3. Your character will always be able to fill up an empty canister even after you've far exceeded your normal weight capacity. 4. Hop into your car and drive back to base. This lets you carry as much fuel as you have empty canisters regardless of how much cargo space you actually have in your trunk. I don't do it anymore because it feels like cheating, but it's a good trick.
  13. For the curious, here's what's happening local ISLightSource_create_original = ISLightSource.create That line makes a copy of the original function in charge of constructing new light source, like Lamp on Pole. This copy is called "ISLightSource_create_original". I'm calling it "original" because we're about to change the one that the game will actually use. ISLightSource_create_original, is a backup of the original, vanilla, unchanged function. function ISLightSource:create(x, y, z, north, sprite, ...) ..... end This is now overwriting the function in charge of constructing a new light source. Everything that happens inside this function is what will run when you build a light source Now looking at the contents: function ISLightSource:create(x, y, z, north, sprite, ...) ISLightSource_create_original(self, x, y, z, north, sprite, ...) self.javaObject:setLifeDelta(0); end The first line, "ISLightSource_create_original(self, x, y, z, north, sprite, ...)" executes the copy of the function we made at the beginning. In other words, this line just makes the function do what it normally would. Now let's look at the second line, "self.javaObject:setLifeDelta(0);" "self" is how the function refers to itself, including all of the various variables and stuff that belong to it, so self.javaObject is the specific javaObject that the function is creating right now (in our case, the lamp pole your character is building). LifeDelta is the amount of battery power it consumes every millisceond. so "setLifeDelta(0)" is saying "use 0 (zero) energy every millisecond" which means it will never use up any battery and will last forever.
  14. This will do the trick: Create a lua file: media/lua/server/memmorath_infinite_lamp.lua Paste this in the file: local ISLightSource_create_original = ISLightSource.create function ISLightSource:create(x, y, z, north, sprite, ...) ISLightSource_create_original(self, x, y, z, north, sprite, ...) self.javaObject:setLifeDelta(0); end Note: This will only affect lamps that are built while the mod is enabled. That means: 1. Existing lamps you made before loading the mod will still drain power 2. Any new lamps you make will be infinite forever, even after you disable the mod.
  15. I'm still looking up how to change lamps... In the meantime (if you were wondering) you can make flashlights infinite/last longer by going to their item script and changing their Type or their UseDelta. Smaller UseDelta will make it last longer. I think if you change the Type to "Normal" it will last forever, but you'd have to check for yourself. I'll let you know when I find out how to modify stationary lamps
×
×
  • Create New...