riperiperi / FreeSO

Re-implementation of The Sims Online.
http://freeso.org
Mozilla Public License 2.0
803 stars 95 forks source link

Fixes for DJ/Dancer Job Outfits and Fixes for All Outfits for all jobs. #266

Closed thertzelle closed 1 year ago

thertzelle commented 1 year ago

What

Below I have put together a table, that represents the current values, and the goal values. Job Grade is the current int of job. Expected result column built based on TSOMania game guide, the current computed C# value without round, and the tested C# value with round (the fix), and finally just a confirmation column, on observing the current values using Volcanic.

JOB GRADE EXPECTED RESULT C# Current - (jobLevel - 1) / 4; C# With New Code Current (Via Volcanic)
0 0 0 0 0
1 0 0 0 0
2 0 0 0 0
3 1 0 (wrong) 1 0
4 1 0 (wrong) 1 0
5 1 1 1 1
6 1 1 1 1
7 2 1 (wrong) 2 1
8 2 1 (wrong) 2 1
9 2 2 2 2
10 2 2 2 2
thertzelle commented 1 year ago

This seemed like it was merged in update L, but then taken back out of update M? @riperiperi

riperiperi commented 1 year ago

This was never merged.

thertzelle commented 1 year ago

I'll take a look at the conversion change in a little bit. Strange that everyone reported that shortly after I submitted this PR, the outfits were 'fixed', but after the M update they reverted back to the previous invalid state. I'll update the PR. Thanks for taking a look.

riperiperi commented 1 year ago

Yeah, it looks like it was an issue with the update builder. It took the azure build from this PR instead of the main branch... should be sorted now. I don't think this happened with any other PR (that wasn't an inconsequential dependabot one).

thertzelle commented 1 year ago

var level = Math.Max(0, Math.Min(2, ((int)avatar.GetPersonData(VMPersonDataVariable.OnlineJobGrade) + 1) / 4)); I updated the code and here is the results:


Job Grade: 0 Level: 0

Job Grade: 1 Level: 0

Job Grade: 2 Level: 0

Job Grade: 3 Level: 1

Job Grade: 4 Level: 1

Job Grade: 5 Level: 1

Job Grade: 6 Level: 1

Job Grade: 7 Level: 2

Job Grade: 8 Level: 2

Job Grade: 9 Level: 2

Job Grade: 10 Level: 2