Made a new class and added it to 5 scenarios as a mod, now all classes are blacklisted and the class I made 'does not exist'?

So I have been trying to fix this for 3 hours altering the Mod info, Scenario and Pro(fessions) JSONS I made for the mod.

It’s in it’s own folder, I tried with and without a separate folder for the Profession File (Which I have changed the name maybe 7 times?)

Scenarios File Text
[
{
“copy-from”: “evacuee”,
“type”: “scenario”,
“extend”: {
“professions”: [
“preparedsurvivor”
]
},
“id”: “evacuee”
},
{
“copy-from”: “squatter”,
“type”: “scenario”,
“extend”: {
“professions”: [
“preparedsurvivor”
]
},
“id”: “squatter”
},
{
“copy-from”: “missed”,
“type”: “scenario”,
“extend”: {
“professions”: [
“preparedsurvivor”
]
},
“id”: “missed”
},
{
“copy-from”: “largebuilding”,
“type”: “scenario”,
“extend”: {
“professions”: [
“preparedsurvivor”
]
},
“id”: “largebuilding”
},
{
“copy-from”: “isolationist”,
“type”: “scenario”,
“extend”: {
“professions”: [
“preparedsurvivor”
]
},
“id”: “isolationist”
}
]

The Profession that was added
[
{
“type”: “profession”,
“id”: “preparedsurvivor”,
“name”: “Low-Budget Prepper”,
“description”: “You have been prepping for a variety of situations for a long time, but you were always on a budget. You had to leave most of your stuff behind in the panic, but will a few choice purchases save your hide?”,
“points”: 2,
“proficiencies”: [
“prof_gunsmithing_basic”,
“prof_gunsmithing_improv”,
“prof_bowyery”,
“prof_fibers”,
“prof_fibers_rope”,
“prof_leatherworking_basic”,
“prof_metalworking”,
“prof_lockpicking”,
“prof_bow_basic”,
“prof_parkour”
],
“skills”: [
{ “level”: 4, “name”: “survival” },
{ “level”: 3, “name”: “speech” },
{ “level”: 2, “name”: “gun” },
{ “level”: 2, “name”: “traps” },
{ “level”: 2, “name”: “fabrication” },
{ “level”: 2, “name”: “cooking” },
{ “level”: 2, “name”: “dodge” },
{ “level”: 2, “name”: “throw” },
{ “level”: 2, “name”: “mechanics” },
{ “level”: 2, “name”: “chemistry” },
{ “level”: 2, “name”: “electronics” },
{ “level”: 2, “name”: “firstaid” },
{ “level”: 2, “name”: “swimming” }
],
“items”: {
“both”: {
“items”: [ “pants_army”, “dress_shirt”, “mbag”, “granola”, “wristrocket”, “glasses_safety”, “ZSG”, “hammer” “undershirt”, “hat_ball”, “gloves_leather”, “duster”, “socks”, “quiver”, “tool_belt”, “bootsheath”, “sheath”, “suitcase_m”, “backpack”, “sneakers_steel”, “multitool”, “binoculars”, “wearable_light”, “folding_bicycle”, “emergency_lockpick”, “ny_hook”, “wristwatch” ],
{ “item”: “roadmap” },
{ “item”: “bolt_cf”, “charges”: 8 },
{ “item”: “compcrossbow”, “ammo-item”: “bolt_cf”, “charges”: 1, “contents-item”: “shoulder_strap”, “rifle_scope”, “adjustable_stock”, “pistol_grip” },
{ “item”: “can_spam”, “container-item”: “can_medium” , “count”: 6 },
{ “item”: “baton”, “custom-flags”: [ “auto_wield” ] },
{ “item”: “water_clean”, “container-item”: “2lcanteen”, “count”: 8 }
“entries”: [ { “group”: “charged_smart_phone” }, { “group”: “full_survival_kit” }, { “item”: “tailors_kit”, “ammo-item”: “thread”, “charges”: 100 }, { “group”: “full_1st_aid” }, { “group”: “charged_matches” } ]
},
“male”: [ “boxer_shorts” ],
“female”: [ “bra”, “panties” ]
}
}
]

And the Mod Info File

[
{
“type”: “MOD_INFO”,
“ident”: “My_Character”,
“name”: “My Character Mod”,
“authors”: [ “Me” ],
“description”: “Adds new class.”,
“category”: “misc_additions”,
“dependencies”: [ “dda” ]
}
]

Mod info and scenarios are in the main mod folder while the prof has been in there before and is now in its own folder named ‘Prof’, the file being named MyCharacter to try to avoid it ‘blacklisting’ all the other professions.

I really can’t figure out what I’m missing and it’s driving me crazy here.

PLEASE NOTE: The post did NOT keep spaces for the code so everything is flattened. I copied the formatting of the associated files and used other working mods as reference whenever I could. I even used Notepad++ and it all looks fine here.

part of your problem might using “copy-from” instead of filling it in from scratch or using the copied from files as a template
if you haven’t checked the doc folder on how to make things now would be a good time to take a refresher

I will take another look at it, thank you for the input.

I’m still getting the error:

DEBUG : profession preparedsurvivor for scenario evacuee does not exist

FUNCTION : void scenario::check_definition() const
FILE : src/scenario.cpp
LINE : 185
VERSION : 203ff0b

Checking the default Scenario JSON line 185 is for a different scenario all together. And the Mod Scenario folder only has about 60 lines to check.

I don’t suppose you know where SRC or .CPP files are? Apparently the issue is there

DEBUG : Why would you blacklist every profession?

FUNCTION : std::vector<string_id > scenario::permitted_professions() const
FILE : src/scenario.cpp
LINE : 382
VERSION : 203ff0b

This is the second error that pops up, still referencing the src/scenario.cpp file
It shows up on each scenario that I tried to modify, and the scenarios allow you to only select the generic ‘survivor’ class.

I still can’t figure out what I did incorrectly, I checked the Documentation and everything checks out.
Spacing, placement, commas and other symbols, and I even checked every Bracket to make sure they all closed properly.

I’m going to add the profession to the normal profession file next and see if I can spot any errors that way.

Now I’m getting errors for spaces that should NOT be errors.

The space between entries: and [ is showing as an error.
The same thing is happening for male and female entries under items.

When I remove the space it then says the bracket (Which is required for formatting) is now the issue.

Space or not, the window freezes or produces infinite repetitive errors on the ‘male’ entry.

Does anyone know what I’ve done wrong? I have made classes in the past and it was nowhere near this problematic.

you might need to copy a version of the evacuee scenario and then insert preparedsurvivor as one of the available classes

if you’re having problems with [ then you should try use notepad++, it might help show you which brackets you haven’t “closed” yet

sometimes when you hit a wall it might be best to go back to your last stable version and then rebuild from scratch, since coding is incredibly picky and doesn’t account for human errors like typos, it only does exactly what you tell it to (as opposed to what you want it to do). it could be that there is a miswritten sentence somewhere that is in a kind of “blindspot” being so obvious you might overlook it, or the game “logic” isn’t in proper order.