Colin Posted August 3, 2022 Share Posted August 3, 2022 (edited) Hi there, First off, long time player, I haven't posted in a very long time and i've never bothered with modding really.... (which I plan to start, I come from a modding Arma 3 etc), so greetings to everyone! My question and first plan is.... is it possible to bypass the character creation, obtain the survivor object and programmatically assign traits etc? Kind Regards, Edited August 3, 2022 by Colin fix few missing things Link to comment Share on other sites More sharing options...
Zeros Posted August 10, 2022 Share Posted August 10, 2022 As for bypass character creation I don't know how to do that but I think you can set player traits programmatically. -- OnCreatePlayer might needs to be hooked to attempt this -- https://pzwiki.net/wiki/Modding:Lua_Events/OnCreatePlayer -- First, I haven't try it yet -- Second, make sure you attempt this on server side for anti-cheat measure. -- Third, based on the dev's update logs.. Player seems to be able to use their local save so it might be modified. Save their original data in server for simple anti-cheat check -- You might also need to synchronize the data to the targeted player or all players -- Need to grab a player instance to do this -- Get traits local traits = player:getCharacterTraits() -- Set true to activate the trait, false to remove it from the player traits:set("Marksman", true) -- Done --[[ Available Trait List "Obese" "Athletic" "Overweight" "Unfit" "Emaciated" "Graceful" "Clumsy" "Strong" "Weak" "Very Underweight" "Underweight" "FastHealer" "SlowHealer" "ShortSighted" "EagleEyed" "Agoraphobic" "Claustophobic" "AdrenalineJunkie" "Out of Shape" "HighThirst" "LowThirst" "HeartyAppitite" "LightEater" "Cowardly" "Brave" "Brooding" "Insomniac" "NeedsLessSleep" "NeedsMoreSleep" "Asthmatic" "PlaysFootball" "Jogger" "NightVision" "FastLearner" "SlowLearner" "Pacifist" "Feeble" "Stout" "ShortTemper" "Patient" "Injured" "Inconspicuous" "Conspicuous" "Desensitized" "NightOwl" "Hemophobic" "Burglar" "KeenHearing" "Deaf" "HardOfHearing" "ThinSkinned" "ThickSkinned" "Marksman" "Outdoorsman" "Lucky" "Unlucky" "Nutritionist" "Nutritionist2" "Organized" "Disorganized" "Axeman" "IronGut" "WeakStomach" "HeavyDrinker" "LightDrinker" "Resilient" "ProneToIllness" "SpeedDemon" "SundayDriver" "Smoker" "Hypercondriac" "Illiterate" --]] Colin 1 Link to comment Share on other sites More sharing options...
Colin Posted August 11, 2022 Author Share Posted August 11, 2022 I had a feeling there would be no way to bypass it, I guess bypassing character creation needs to be a feature request Thank you Link to comment Share on other sites More sharing options...
Zeros Posted August 11, 2022 Share Posted August 11, 2022 (edited) You can bypass it actually. I already had a look at it. Find 'ISPlayerStatsUI.lua' inside 'game/media/lua/client/ISUI'. It also has information on how to programmatically assign traits and how to send those data on player creation. Try extend the 'ISPlayerStatsUI:setVisible' function. You can probably prevent character creation UI from being displayed by doing that. Look for the right function if it didn't. Edited August 11, 2022 by Zeros missed the word 'from' haha Colin 1 Link to comment Share on other sites More sharing options...
Colin Posted August 11, 2022 Author Share Posted August 11, 2022 1 hour ago, Zeros said: You can bypass it actually. I already had a look at it. Find 'ISPlayerStatsUI.lua' inside 'game/media/lua/client/ISUI'. It also has information on how to programmatically assign traits and how to send those data on player creation. Try extend the 'ISPlayerStatsUI:setVisible' function. You can probably prevent character creation UI from being displayed by doing that. Look for the right function if it didn't. Oh, great will check it out, thanks Link to comment Share on other sites More sharing options...
Zeros Posted August 11, 2022 Share Posted August 11, 2022 No problem. And I missed one more folder. 'game_folder/media/lua/client/ISUI/PlayerStats' Good luck. Colin 1 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now