Jump to content


  • Content Count

  • Joined

  • Last visited

Everything posted by ohgodspidersno

  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
  16. I didn't fully read your post before commenting, so apologies if my response doesn't help at all. I'll leave it up in case it does.
  17. Check out FMJ's lockpick mod (not mine, it has to be FMJ's) and poke around. He adds a few traits, two of which are nearly identical except one is automatically given to burglars for free and the other can be selected for a few points. Essentially there is a bit of code that creates the trail, and then another bit that actually puts it on the list. There's also an optional third bit that gives it automatically to certain professions.
  18. Also, it has to be a lighter, specifically, in your other hand. Matches won't do.
  19. Combat speed, running speed, and stomp power. Maybe more. You can't run as fast in boots as you can in sneakers, but they crush heads better. Firefighter jackets have great protection but your melee movements will be slower.
  20. It's supposed to but a few releases ago they disabled that because they're still fixing some bugs. It's possible they've reintroduced it but I personally don't remember reading anything about that in the changelogs.
  21. Yes, and possibly also a lamp or light switch but I'll have to look at the rest of the file first to say for sure. The main point is that this code is all about a player action, and not how the item itself behaves.
  22. that chunk of code you linked is not the right one, I know that much. That block of code relates to the character action of physically interacting with a lightsource, e.g. actually pressing the light switch. Those numbers are milliseconds I believe; definitely less than a second. I'll see if I can find you the correct chunk.
  23. Oh good point! I hadn't even thought about long hair and beard keeping you warm, but it absolutely would. It would probably have a dramatic effect, in fact.
  24. At the very least it would be nice to be able to use showers at all, even if it was functionally identical to using a bathtub, sink, or toilet (ew). (sidenote: I like to assume that the character is using only the water that's in the tank, not the bowl. But I'll never quite know for sure.)
  25. If this turns out to be a bug I'm going to be a little miffed because we have been laboring under the assumption that adding new guid was something we just were not allowed to do for whatever reason. OP, you can "steal" a GUID from another item if you want but this makes your mod likely to break saved games, and create extremely hard conflicts with other mods. I think the ideal solution to your problem is to add extra alternate skins to existing items. So like, make it so the police bullet proof vest has an alternate swat version. You do this by adding new<texturechoices> lines in the item's xml file. Also, if you change an xml file you have to quit the game to desktop and reload. It's not enough to simply reload the Lua.
  • Create New...