

Xyberviri
Member-
Posts
34 -
Joined
-
Last visited
Recent Profile Visitors
The recent visitors block is disabled and is not being shown to other users.
Xyberviri's Achievements
-
Sorry i diverged there for a sec, this was about allowing end users to customize if a object is going to get added to the loot tables entirely by using a sandbox option. I would rather not resort to having a "EnableSettingA,EnableSettingB,EnableSettingC, etc, etc, etc" mod just to enable a setting. I guess i could break up the items and assets into sub mods and just tell people to load the options they want and build my settings based off that if i really had to. It appears the game has a copy of the loot tables in the java side and the "real" loot tables get built when ItemPickerJava.Parse() is called, If we wait until OnInitGlobalModData we have access to the sandbox variables but we cant add anything to SuburbsDistributions or ProceduralDistributions. Well correction, anything we insert appears to be in the loot tables when you inspect a container with lootzed but its never going to actually drop, i tried turning up the weight to 100 and had loot showing 97% against everything else and nothing ever dropped. but if you just deal with loot in OnPostDistributionMerge, your added items actually drop in game. All good i figured out i can just call ItemPickerJava.Parse() and it loads my changes.
-
Hi, sorry for the late reply, the main reason is when i want to add my own sand box variables to allow the end users to adjust the rarity of the items I'm adding to the game itself, whatever weight i end up choosing to add my items a server owner / end user will inevitably ask for the ability to adjust my items to spawn more or less than whatever i choose. Alternatively i would like the ability to turn off the spawning of some of my items depending on the sandbox options a user sets. Also the reason this appears to be a bug, or at least not intentional is when you start a new game or host the sandbox variables are accessible in these events. If you restart the server/reload the game these is no longer accessible until later, so the behavior is inconsistent depending on how the game world is started.
-
Hello, I noticed in IsoWorld.java we are loading the Sandbox options after firing off the Distribution events, a lot of mods that deal with loot (including my self) are loading things into the loot tables around these events, would it be possible to load the sandbox options before these events so we can have access to sandbox variables before Distribution tables are messed with? LuaEventManager.triggerEvent("OnPreDistributionMerge"); LuaEventManager.triggerEvent("OnDistributionMerge"); LuaEventManager.triggerEvent("OnPostDistributionMerge"); ItemPickerJava.Parse(); VehiclesDB2.instance.init(); LuaEventManager.triggerEvent("OnInitWorld"); if (!GameClient.bClient) { SandboxOptions.instance.load(); } The big issue with this is if a mod implements their own sandbox options we cant really do anything with loot until OnInitGlobalModData or OnLoadMapZones fires off, if we want to change loot we have to go back and remove stuff which takes a boat load of time. Sure if i want to hard code things no problem, but if I want a end user to be able to change any settings, again im sort of just out of luck unless im willing to go back though the tables with lua and slow down loading for a user. The alternative requires end users have to create a server mod to their settings via lua files which still have to be distributed, this is why we have a billion Arsenal26ServerSettings mods clogging up the workshop.
-
Hello, Can we get a sandbox option so that the server owners can increase the distance that generators make noise for zombies to hear? not the actual sound but the invisible world sound ping that occurs when you are in debug mode viewing the zombie population.
-
Spending Points on Starting Equipment?
Xyberviri replied to Bullet_Magnate's topic in PZ Suggestions
A better suggestion would be for each of the starting professions to have better starting items. For example of the mods that deals with addiction adds a can of beer and cigarette to the starting character when picking the alcoholic or smoker trait. -
Not sure if its a mistake or if i missed a patch note, but In previous builds the "vehicle remove" client command was accessible to players with out any admin rights on a server. I tried turning off all the anti cheats and none of those allow this to work as a player with out admin rights. I set the player as admin and then called this again and poof the vehicle was gone. sendClientCommand(getPlayer(), "vehicle", "remove", { vehicle = getPlayer():getNearVehicle():getId() }) For chuckles i copied the contents of this into my own client command and im able to remove vehicles as non admins on multiplayer servers again. So this appears to be blocked via the engine itself, can we get a anti cheat setting to override this so admin is not needed by the player? Edit: This appears to have been fixed around 41.77 perhaps ever earlier, this post can be locked at anytime.
-
41.71: SandboxVars seems broken on reload of single player game
Xyberviri replied to Xyberviri's topic in Bug Reports
Ah no, that doesnt appear to be working either, i also tried OnReceiveGlobalModData, OnGameTimeLoaded & OnLoginStateSuccess local function TestVars(location,event) print("SandBox Variable "..location.." "..event.." Test boolean value: ".. tostring(SandboxVars.SandTest.isTrue)) print("SandBox Variable "..location.." "..event.." Test boolean value: ".. tostring(getSandboxOptions():getOptionByName("SandTest.isTrue"):getValue())) end Events.OnGameStart.Add(TestVars("server","OnGameStart")) Events.OnLoad.Add(TestVars("server","OnLoad")) Events.OnServerStarted.Add(TestVars("server","OnServerStarted")) Events.OnPostMapLoad.Add(TestVars("server","OnPostMapLoad")) Events.OnInitGlobalModData.Add(TestVars("server","OnInitGlobalModData")) Events.OnReceiveGlobalModData.Add(TestVars("server","OnReceiveGlobalModData")) Events.OnGameTimeLoaded.Add(TestVars("server","OnGameTimeLoaded")) Events.OnLoginStateSuccess.Add(TestVars("server","OnLoginStateSuccess")) I also have a copy of this in server and shared.... sandbox options seem broke... i guess if there is a way to read the ini files directly i can try sneaking back up one up and over via lua and see if that works. but at this point its easier to use mod options. This is all in single player and local hosts ive tested, ive even uploaded it to a test server and i get the same results. sandbox options are broken until some event i havent found yet. they work once i join the game and try to test it with debug console but i cant figure out how to use them with mods on launch of a server yet. -
(GLITCH) I can't get down from the Grand Ohio Mall in Louisville.
Xyberviri replied to Roadbobek's topic in Bug Reports
the issue is with this tile Fortwater front has the exact same rails on the upper level over the garage in the main house and it blocks that southern tile. -
So i wrote this to trouble shoot a issue i was seeing with trying to mess with loot from my mod, i wanted to change some mod data on the items that spawn on zombies but not ones that were crafted or spawned in by a admin. The issue is im only able to see the items worn on a zed when this event fires. local function zombieDead(zombie) local inv = zombie:getInventory():getItems(); for i = 0, inv:size() - 1 do local item = inv:get(i) print("ZEDLOOT: "..item:getFullType()) end end Events.OnZombieDead.Add(zombieDead); If i kill a zombie only the items on that zombie are being returned when i get the inventory. The Hand Fork on this zombie was in its back here is another one where the matches and wallet had to be added after the event fires: this one wasnt able to see the lighter. Im trying to figure out if this is intended behavior or if there is something else up since the only use cases in the game of this event aren't dealing with the inventory of the corpse. And other mods all seem to just be checking for the outfit to see if they want to add inventory not mess with existing. But the issue is im going to have to write my own loot tables if i want to do that.
-
41.71: SandboxVars seems broken on reload of single player game
Xyberviri replied to Xyberviri's topic in Bug Reports
i completely missed that event thanks -
sadly I'm finding more and more you will need to do some convoluted work around because code just doesn't work the way you think it should.
-
Why do you need the recipe name? You can add whatever extra info you need on the end result item you are creating: item CarLights { DisplayCategory = CarWanna, Weight = 0.1, Type = Normal, Icon = AutoTitle, DisplayName = PinkSlip: Chevalier Nyala, VehicleID = Base.CarLights, WorldStaticModel = CW.AutoTitle, Tooltip = Tooltip_ClaimOutSide, Condition = 100, GasTank = 100, HasKey = true, } And then use one function on the recipe to create the item, heck in this case im using the input item to get my extra data: recipe Claim Vehicle { CarLights/CarLightsPolice/CarLuxury/CarNormal, //truncated for post Result: Base.CarKey, Time: 50.0, OnCanPerform:Recipe.OnCanPerform.CW_ClaimVehicle, OnCreate:Recipe.OnCreate.CW_ClaimVehicle, RemoveResultItem:True, } then in OnCreate i can access the data in "VehicleID" using getModData() function Recipe.OnCreate.CW_ClaimVehicle(items, result, player) local pinkslip = items:get(0) if not player:isOutside() or player:getZ() > 0 then --This should be caught with Recipe.OnCanPerform.CW_ClaimVehicle, but if we get here somehow give player back the pinkslip. player:Say("This wont work unless im standing on the ground outside...") player:getInventory():AddItem(pinkslip) else local modData = pinkslip:getModData() local requestedVehicle = { type = modData.VehicleID } if (type(modData.Condition) == "number") then requestedVehicle.condition = modData.Condition end if (type(modData.GasTank) == "number") then requestedVehicle.gastank = modData.GasTank end if (type(modData.FuelTank) == "number") then requestedVehicle.fueltank = modData.FuelTank end if modData.HasKey then requestedVehicle.makekey = true end if modData.Upgraded then requestedVehicle.upgrade = true end requestedVehicle.dir = player:getDir(); requestedVehicle.clear = true sendClientCommand(player, "CW", "spawnVehicle", requestedVehicle ) end I did use the input items but i could have just used the result and pulled the data the same way with getModData()
-
Just make the recipe invalid if the mod isnt installed: module MyModID { imports { Base } recipe Buy AN/PRC-77 Radio Man Pack { Money=1, Result: Bag_ARVN_Rucksack, Time: 50.0, OnCanPerform:Recipe.OnCanPerform.CanBuyFromBritaArmor } } function Recipe.OnCanPerform.CanBuyFromBritaArmor(recipe, playerObj, item) return getActivatedMods():contains("Brita2") end
-
oh neat.... oh... it uses python... welp guess i wont be using that... mostly cause the last discord bot i tried to do anything with in python ended horribly