Custom Degree Modding

Talk nerdy to us here.
User avatar
MissPatTS3
Reactions:
Posts: 235
Joined: October 25th, 2017, 6:00 pm
Location: Paris, France
Contact:

Custom Degree Modding

Post by MissPatTS3 » September 15th, 2020, 8:56 am

I was looking up the game's code (assembly files / DLLs) and especially the "AcademicDegree" class / file by EA themselves. I noticed that their "localization" line included the word "academics" on line 46, like so:

Code: Select all

return Localization.LocalizeString(isFemale, "Gameplay/Academics/AcademicCareer:" + name, parameters);
So I was like... "that's so weird, Twallan's degree is called "Education", but inside of his degree's package file, all the localization STBL files are called "Strings Academics Something"..."

Then I was like "you know what, I'm desperate, that might work or not, at this point, eff it, I'm trying anything".
And I changed all my SBTL filenames from "Strings FrenchLanguage English" (for instance) to "Strings Academics English"
And sure enough... IT EFFIN WORKED.

That was it - that was the big deal :-o

You sneaky you, Twallan.

Now I have to troubleshoot extra stuff, one of them inspired by crashley_1784: does following Missy's tutorial for custom career books creation (the stuff sims have to read), works for custom degree textbooks? Would be fascinating to know.

User avatar
MissPatTS3
Reactions:
Posts: 235
Joined: October 25th, 2017, 6:00 pm
Location: Paris, France
Contact:

Custom Degree Modding

Post by MissPatTS3 » September 28th, 2020, 7:14 pm

So I am back with 2 main questions for you Chain_Reaction:

=16pxQ1: Aptitude Tests Integration

As of today, Twallan's Education degree is not accounted for, in the aptitude test modal, as you can see in the screenshot below. Now, I found the code that manages EA's own aptitude modal UI and was wondering if you think it would be possible to "upgrade" custom degrees so that their aptitude test results would either:
  1. show up alongside EA's degree scores, like in the game screenshot below?
  2. or output their aptitute test scores in their own "custom degree" aptitude test modal (showing how the sim did against that *one* custom degree or against all custom degrees installed in the game)?
Image


Image

(have to send Q2 as another message as embedding images in the post increases artificially the occurences of URLs and the post won't allow more than 4 URLs)
Last edited by MissPatTS3 on September 28th, 2020, 7:18 pm, edited 2 times in total.

User avatar
MissPatTS3
Reactions:
Posts: 235
Joined: October 25th, 2017, 6:00 pm
Location: Paris, France
Contact:

Custom Degree Modding

Post by MissPatTS3 » September 28th, 2020, 7:16 pm

Q2: Academic Career Object + Responsibility Text Twallan's Education degree shows zero text for the "skills / objects" career responsibility - see below.
  • I could not locate where that localization string resides in EA's code.
  • I could not find out how exactly EA links in its code, the usage of a specific skill object to academic career XP gain / performance increase.
Would you have any insight on this? Image

Image Still beta testing...

User avatar
Chain_Reaction
Site Admin
Reactions:
Posts: 7618
Joined: December 30th, 2011, 6:00 pm
Answers: 82
Contact:

Custom Degree Modding

Post by Chain_Reaction » September 30th, 2020, 11:57 pm

Which object is tied to which degree is hard coded in the object's interaction. To have custom objects, you'd have to add or modify interactions.

The responsibilities tooltip is coming from AcademicResponsibilitiesTooltip under Sims3.Gameplay.Academics.AcademicCareer which uses the <ResponsibilityTooltipKey></ResponsibilityTooltipKey> tuning in the AcademicDegrees XML. You should be able to add your own using the same format as the other key's. I suppose twallan didn't bother because of the need for script modding to add custom objects.

The aptitude test looks like it could be integrated however I suspect the reason twallan didn't is because the UI may break if additional degrees are added. Fiddling with the UI is unfortunately more time consuming than I have time for at the moment but I'll look into it when I have a free moment. It may be that I would be forced to create a separate interaction for it or perhaps just show the information in a notification.

User avatar
MissPatTS3
Reactions:
Posts: 235
Joined: October 25th, 2017, 6:00 pm
Location: Paris, France
Contact:

Custom Degree Modding

Post by MissPatTS3 » October 3rd, 2020, 12:07 am

Thanks for getting back to me! I appreciate you are busy offline so I'll work with your timeline.
  • I did not realize it was so easy to implement the "ResponsibilityTooltipKey" key / string. Learned something new today!
  • I will look into custom objects for the fun / sake of it but do not have too much ambition for it. (What could be a good custom skill object for a French Language degree from a gameplay perspective...? Food for thoughts.)
I had reached out to gamefreak130 over at MTS, as he had coded a fully modded version of the Aptitude test 2 years ago. He was so kind as to share the following insights with me (quoted with permissions):
I looked at what Chain had to say on the matter, and he is correct: the number of degrees that are used in the aptitude test and are eligible for credit awards is effectively hard-coded in both the interaction and the AcademicDegreeManager in the form of a fixed-length array.
  • I believe it is definitely possible to work around these arrays using PersistableStatic dictionaries, but it would take some effort, as both the enrollment and the aptitude test dialogs would have to be changed.
  • I think the UI could handle the extra degrees without significant layout changes, though, since the degree list is implemented as a table, which should support vertical scrolling.
  • For what it's worth, I would probably implement the custom degrees as "subscores" separate from the overall SUAT score to avoid potential issues with scholarships awarded based on the final score.
  • If Chain's planning on making those changes, then I'll leave him to it [as I would] have to change the enrollment dialog and risk conflict with NRaas Careers to make those changes in my own SUAT replacement[.] At least if Careers strikes first and overrides the SUAT, I can easily provide a fix for that particular conflict [with his mod]."
Eek, I was so obsessed with loading custom degrees in the Aptitude Test UI that I had completely overlooked the 2400 points SUAT score limit! With that in mind, I'll be happy with whatever solution you come up with + think is best here.

I am off for more beta testing... Have a great week-end!

User avatar
MissPatTS3
Reactions:
Posts: 235
Joined: October 25th, 2017, 6:00 pm
Location: Paris, France
Contact:

Custom Degree Modding

Post by MissPatTS3 » August 25th, 2022, 8:59 am

Hello all :) I've picked up this custom degree project and sprucing up the code + tutorial + adding features before the release.

Thank you Chain_Reaction, for explaining how to implement the skills/skill object tooltip, it's now showing up successfully in the game!

Next up, I would like to add custom textbooks to the degree. I have tried adding a Books XML file to the custom degree package, but the books never showed up in game. I have looked up the 'BookBooter' file of NRaasCareers.dll and, if the file I looked at is up to date, it seems that currently NRaas Careers Book Loader only loads the following custom books: BookGeneral, BookRecipe, MedicalJournal, SheetMusic, BookToddler, BookAlchemyRecipe, WrittenBooks, BookFish, and OmniJournal.

If I want to load custom Academic TextBooks with the degree, I would have to use Arsil's Book Loader that's integrated in CCLoader mod. From what I see in the code of CCLoader, it includes BookSkill, BookComics (Comics & VintageComics), and AcademicTextBook, on top of everything NRaas Careers Book Loader already covers.

It'd be amazing if Nraas Careers could load these extra book types as well! Then, custom degrees would be fully dependent on the single Nraas Careers mod, reducing mod installation steps for players. Food for thoughts.

Off to associate the degree with the picked skill object: it'll be the Podium! As suggested by the lovely FloTheory :idea:

User avatar
MissPatTS3
Reactions:
Posts: 235
Joined: October 25th, 2017, 6:00 pm
Location: Paris, France
Contact:

Custom Degree Modding

Post by MissPatTS3 » August 26th, 2022, 12:54 pm

Quick update on custom academic textbooks: I created a Books XML file compatible with CCLoader, and the textbooks showed up fine in game, when I used EA's Communications degree name for the <Degree></Degree> tags. As soon as I entered my custom degree name, CCLoader stopped loading the custom textbooks altogether. So, unfortunately CCLoader cannot currently load custom academic textbooks created for NRaas Careers custom degrees.

Still working on associating the podium object with the custom degree, let's see how that goes!

User avatar
MissPatTS3
Reactions:
Posts: 235
Joined: October 25th, 2017, 6:00 pm
Location: Paris, France
Contact:

Custom Degree Modding

Post by MissPatTS3 » August 30th, 2022, 11:06 pm

Made little progress but hitting some intriguing obstacles so posting in case anyone has a clue how to tackle them!

1 - First of all, good news! The French Language custom degree shows up in the Report Card UI that sims receive at the end of a term, here (translated as well) in my French Game:
Image
2 - Lectures and Class Activities not functionning properly

Alpha tester FloTheory pointed out that with EA's uni degrees, Lectures systematically happen in the Student Union Building, here is an example of EA's Communications Degree class schedule for instance:
ImageBased on this feedback, I clarified in the custom degree names, which classes were meant to be classes (in rabbitholes), lectures (in Student Union Building) and Class Activities (in venues: Library, Student Hangout, Stadium & Annex Combo, Comics Shop but can also be held in rabbitholes like School of Arts for Fine Arts Major and School of Science for Science & Medicine Major). It turns out that, Twallan's Education Degree itself does not send students to the Student Union Building for its Lectures. My degree's Lecture, following the Education major's steps, does not send students there either.Image

I'm testing these findings in the EA uni world. For the first week, I have cheated the time in the game and pushed the clock forward to the days when the Class Activity and the Lecture were due to happen. Both days, the game kept showing that my sim was "skipping class" and when I'd try and click on the button to "go to class" in the sim's career panel, a notification would appear.Image

When looking up the Academic-related Situations in EA's code, I noticed that there were a lot of mentions of Professors. So with Nraas MC, I have manually assigned a University Professor for all 6 majors and I'm no longer cheating time in my test save, to allow for the game to process all the changes made. Hoping that the second week of test will deliver functional lectures and class activities.

To be continued.
Last edited by MissPatTS3 on August 30th, 2022, 11:41 pm, edited 1 time in total.

User avatar
MissPatTS3
Reactions:
Posts: 235
Joined: October 25th, 2017, 6:00 pm
Location: Paris, France
Contact:

Custom Degree Modding

Post by MissPatTS3 » August 30th, 2022, 11:26 pm

Second and last message from me today! It's about the Welcome Letter and Professor Talk features of a custom degree.

My test university household sims attended the Meet & Greet event at the Student Union Building. When interacting with the Services Student Booth, the sims had the options, on top of grabbing freebies, to "Read About Curriculum" and "Talk To Professor".

1 - For "Talk To Professor", I remember from an EA uni save I played a while ago, that it would fire up notifications with a few words from the assigned Major's University Professor. I am hoping that now that my test save has assigned professors, I will be able to get these notifications again. Currently, all my test sims do, is to walk to the nearest sim who is technically a University Professor (in any Major, not necessarily their very own legitimate Professor) and use the interaction "Warm Introduction" or something similar.

The first mystery is: what would be the localization key, that would allow to write up a custom notification message, for French Language Degree students using the "Talk to Professor" interaction on the booth? Still looking.

2 - For "Read About Curriculum" interaction, a Welcome Letter UI shows up, with details unique to each major, here the Business School Welcome Letter:

Image

Currently, custom degree students (Education degree and French Language Degree) using this interaction get a blank letter UI. I have not yet been able to identify the localization key to enter custom text for this game's UI. Would anyone have any insight on this

Image

Off to pursue testing and investigations.

User avatar
MissPatTS3
Reactions:
Posts: 235
Joined: October 25th, 2017, 6:00 pm
Location: Paris, France
Contact:

Custom Degree Modding

Post by MissPatTS3 » September 2nd, 2022, 5:03 am

Tiny-ish progress updates:
  • It seems that I was confusing "Talk to Professor" interaction of the Student Services Booth object with "Talk to Academic Advisor" interaction on the Administration Center rabbithole, oops. So, I no longer need to worry about customizing these notifications.
  • Fellow modder Simbouquet helped identify the localization key for the Welcome Letter UI of the custom degrees: I was not suspecting UntranslatedKey could be used for such less-used UI elements too! Mind blown. Hopefully I can find some inspo to write a decent welcome letter for French Language students this week. Would love to see one for sims enrolled in Twallan's Education major! The titles of his major's courses crack me up every time I look at the class schedule :D
  • I have managed to link the Lecture class held every Thursday to the Student Union Building! Had a look at EA's code and will follow their conventions for uni classes locations moving forward. In doing so, I have spotted that Twallan uses the value "GoToLab" for the Lecture node, instead of "GoToLecture".
  • I have merged 2x tuning mods today into one Books XML file. I had my hopes up that maybeeee the reason why the custom Academic Textbooks did not show up the other day, was because I was trying to load them in a CAW-created world (Bigger Builder Island). So I added the value in my Books XML file to load books in User Created worlds, and went back to my BBI save. Anddd nope, the books still did not show up. Welp, was worth a shot.
  • I am thinking that some of the issues I have been having sending my test sims, in the EA uni world save, to attend classes on Thursday (and I mean all 5x of my test sims, 3x of them being enrolled in traditional EA degrees), is because silly me forgot about the TS3 Seasons Holiday system. So, up until today, my 7-day season timeline meant that Thursdays would be the day off for my sims. So, in hindsight, it was probably unnecessary of me to hit a million times that "go to class" button, not understanding why even EA degrees returned the "it's not time for class, check your schedule" error notification when I'd do that. What I found weird was that, all test sims were marked as "skipping class", and this even though they were on a holiday? Not sure if logic fails me, or fails the game. But even if it fails the game, the joke is on me since I keep returning to play it more. Welp again.
  • When I did not understand why the "go to Lecture" interactions would fail, I tried using the Debug Enabler interaction "Give Lecture Now" I think the interaction is called. My test sim in the household, who is a level 2 French Language Student (so, technically a University Professor), walked to the nearby podium to "Give Lesson", and some townie NPCs sat down to take notes but not my student French Language test sim. I really think the issue was that it happened on a Holiday, but if necessary I can use this debug interaction again, see if it can help.
  • Another thing I did, was analyze the schedules that EA gave to Lectures and Class Activities across all 6x Uni EP Majors. Turns out, no two Lectures and no two Class Activities happen at the same time, ever - even if EA created 6x distinct majors. I somehow suspected that maybe my decision of following EA's conventions for buildings and class times, specifically for Lectures and Class Activities, could lead to conflict in terms of podium object usage as there is only one podium in the Student Union Building by default, so I am guessing it could create some serious issue if my test University Professor failed to route to a podium when time for Lecture would come. I added 4x more podiums to the building and will be investigating if it's possible to host 2x different major Lectures in the Student Union Building at the same time of the week. Really hope that EA's class schedule system is flexible enough to host multiple custom degrees with similar hours, without requiring modifications be made to the degree files first. We shall see.
  • Oh and I also tried to install a second Student Union Building that I had saved in my Library, hoping my test sims would be able to attend Lectures in that second building and leave the original building alone. I named that building "Sorbonnes". But when I made my test sim quit his major, and join it again, the game had assigned his Lecture class to the default EA Student Union Building. Welp, I tried.
  • Anyhoo... Simbouquet shared an amazing gameplay tip that he's been using to make the Holiday fall on a week-end day. With a 7-day season, wait to be on Tuesday in the game, then turn on the cheats (testingcheatsenabled true) and shift-clck on the ground to change the season. When I did that, my sims Holiday was automatically set to Saturday! I've been looking for such a solution for years, it's brilliant! So I'm hoping that finally, my Thursday Lecture testing woes will now be gone, and my sims will enjoy turning down NPC pool party invitations on Saturdays.
Will follow up on this follow up.

Post Reply