Wveth Posted April 16, 2015 Share Posted April 16, 2015 I see the option there to give my character free traits... but I can't figure out the names of the traits I want (the profession-specific ones) in terms of their coding names, and I don't know the format for spacing them or how that works. Anyone wanna enlighten me? Link to comment Share on other sites More sharing options...
Svarog Posted April 16, 2015 Share Posted April 16, 2015 %gamedir%\media\lua\shared\NPCs\MainCreationMethods.luaLine 390: securityguard:addFreeTrait("NightOwl");Line 421: veteran:addFreeTrait("Desensitized");Line 432: lumberjack:addFreeTrait("Axeman");Something that my notepad++ puked out. Those all are three Profession traits and their names as the game seems to see them. Edit: That file is awesome, you can even go and reactivate traits like Light\Heavy Drinker You could go and mod the Unemployed profession to give you all profession traits there if you wanted to. And give yourself XP boost to everything when you're at it. Dudeman325 and Wveth 2 Link to comment Share on other sites More sharing options...
Wveth Posted April 16, 2015 Author Share Posted April 16, 2015 Thank you! But I tried adding them and... it doesn't seem to be working? What would the format be to type them in there? I've tried some different permutations but I can't figure it out. Link to comment Share on other sites More sharing options...
Svarog Posted April 16, 2015 Share Posted April 16, 2015 Thank you! But I tried adding them and... it doesn't seem to be working? What would the format be to type them in there? I've tried some different permutations but I can't figure it out.Here's a half assed code that could work as a mod require('NPCs/MainCreationMethods');local function initProfessions() local cheaterman = ProfessionFactory.addProfession("cheaterman", getText("UI_prof_cheaterman"), "profession_cheaterman", 1000); cheaterman:addFreeTrait("Desensitized"); cheaterman:addFreeTrait("NightOwl"); cheaterman:addFreeTrait("Axeman");endEvents.OnGameBoot.Add(initProfessions);It adds a profession to the game that gives 1000 free trait points and all profession traits.You can make a mod just make sure this code is located in media\lua\client\cheaterman.lua part of the mod. UI text is broken but again, half-assed but it works Wveth 1 Link to comment Share on other sites More sharing options...
Wveth Posted April 16, 2015 Author Share Posted April 16, 2015 You're being so helpful, I hate asking more questions But how exactly would I make this into a mod? I have no idea. ^//^ Link to comment Share on other sites More sharing options...
Svarog Posted April 16, 2015 Share Posted April 16, 2015 You're being so helpful, I hate asking more questions But how exactly would I make this into a mod? I have no idea. ^//^Place Cheaterman folder from within the zip to your C:\Users\%username%\Zomboid\mods folder and activate it within the game.Also, thank you, now I know how to create custom professions Edit: The mod is as half-assed as the code but it works.Cheaterman.zip Wveth 1 Link to comment Share on other sites More sharing options...
Wveth Posted April 16, 2015 Author Share Posted April 16, 2015 I'd like that ten more times if I could. But now I want to know how to add skill levels to that new profession, like starting with Aiming 3 and the related XP boost for it. How do you do that? Link to comment Share on other sites More sharing options...
Svarog Posted April 16, 2015 Share Posted April 16, 2015 I'd like that ten more times if I could. But now I want to know how to add skill levels to that new profession, like starting with Aiming 3 and the related XP boost for it. How do you do that?Version 2 Officially Released - It's still half assed and it still works!125% Boost to All skills. Served. I'm learning so much Cheaterman V2.zip Wveth 1 Link to comment Share on other sites More sharing options...
Wveth Posted April 16, 2015 Author Share Posted April 16, 2015 Ha, you rock! I gotta check it out. I figured out how to change the name and mod description and stuff. Link to comment Share on other sites More sharing options...
Svarog Posted April 16, 2015 Share Posted April 16, 2015 Ha, you rock! I gotta check it out. I figured out how to change the name and mod description and stuff.Ok, I finalized it with Profession Icon and UI text, published on pz-mods for everyone who want's to cheat. Enjoy.http://pz-mods.net/professions/Cheaterman/ Wveth 1 Link to comment Share on other sites More sharing options...
Wveth Posted April 17, 2015 Author Share Posted April 17, 2015 (edited) I enjoyed this immensely. Can I get an "Inspired by Wveth" credit? ^_~ If you're interested about your mod though, you missed many skills. Sprinting, Lightfooted, Nimble, Sneaking, Blade Guard, Blade Maintenance, Blunt Accuracy, Blunt Guard, Blunt Maintenance, Carpentry, and Trapping. EDIT: Or wait, you didn't miss them, according to the .lua file. Maybe those aren't the right names for them? EDIT EDIT: No they're the right names. I tried to change the name of the profession, so maybe I borked it up somewhere. EDIT EDIT EDIT: I figured out what I did wrong and now I altered your mod so it's a "Special Forces Veteran" profession with relevant skills only, and got it working. So this has been a learning experience. Thanks again! Edited April 17, 2015 by Wveth Svarog 1 Link to comment Share on other sites More sharing options...
Svarog Posted April 17, 2015 Share Posted April 17, 2015 I enjoyed this immensely. Can I get an "Inspired by Wveth" credit? ^_~ If you're interested about your mod though, you missed many skills. Sprinting, Lightfooted, Nimble, Sneaking, Blade Guard, Blade Maintenance, Blunt Accuracy, Blunt Guard, Blunt Maintenance, Carpentry, and Trapping. EDIT: Or wait, you didn't miss them, according to the .lua file. Maybe those aren't the right names for them? EDIT EDIT: No they're the right names. I tried to change the name of the profession, so maybe I borked it up somewhere. EDIT EDIT EDIT: I figured out what I did wrong and now I altered your mod so it's a "Special Forces Veteran" profession with relevant skills only, and got it working. So this has been a learning experience. Thanks again!No problem, I learned a lot myself And I'll add credit later today when I'm home and not forced to be on mobile Edit: Added credit on pz-mods page. Wveth 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