Hi there! You are currently browsing as a guest. Why not create an account? Then you get less ads, can thank creators, post feedback, keep a list of your favourites, and more!
Scholar
Original Poster
#1 Old 16th Apr 2021 at 8:34 AM
Default Battery.Utility Menus help regarding Sims
I wanted to know how I can add a bunch of sims profiles to the menu like Nraas does. And then select one or multiple sims from that menu.

I'm working on it. But if someone can provide a quick tip it'll solve hours of trial and error. @Battery

If you like my mods. Consider supporting me on Patreon
Check out my website for updates on my mods and other work PuddingFace.wixsite.com
Check out my Youtube channel for tutorials(modding tutorials) and other content Youtube

Follow me on Twitter Instagram Pinterest Tumblr
Advertisement
Space Pony
#2 Old 16th Apr 2021 at 2:52 PM Last edited by Battery : 16th Apr 2021 at 5:49 PM.
Hey @PuddingFace,

if you are using version 1.02b8 or newer (just uploaded) you can use a preset for a Simpicking Menu ( you can find these under "Battery.UI.Menus.MenuContainer.Presets")

Example:

Code:
public static void OnSimsPicked(IList<Sim> sims)
{
	//Do stuff with picked sims
}
.
.
..
Sim[] Simlist =	Sims3.Gameplay.Queries.GetObjects<Sim>(Sim.ActiveActor.LotCurrent);                                                  //Get all sims on the same lot of the currently selected sim
MenuGetter menu = MenuContainer.Presets.GetColorCodedSimPicker(Simlist , OnSimsPicked, "Select Sims Menu", 3);     // Create a On time Menu (List , Action<List<Sim>>, Menu Name,Selectable Sims)
MenuController.Show(menu);                                                                                                                                           //Show the menu




This would be the simplest way, if you need more customization options let me know and i will try to guide you

E: Be careful when using OnSimsPicked some functions wont work on that one thread, you have to experiment to figure out which methods you can use, if you want to use a method that does not work let me know and i see what i can do about it
Example:
SwitchToOutfitWithoutSpin works /no thread sync required
SwitchToOutfitWithSpin does NOT work /sync required
Scholar
Original Poster
#3 Old 17th Apr 2021 at 5:46 AM
Thank you I shall try this. Btw do I have to update my Vampire mod for 1.02b8 if I want to use 1.02b8 for a different mod? (I'll probably do it anyway but just trying to confirm)

If you like my mods. Consider supporting me on Patreon
Check out my website for updates on my mods and other work PuddingFace.wixsite.com
Check out my Youtube channel for tutorials(modding tutorials) and other content Youtube

Follow me on Twitter Instagram Pinterest Tumblr
Space Pony
#4 Old 17th Apr 2021 at 9:57 AM
Quote: Originally posted by PuddingFace
Thank you I shall try this. Btw do I have to update my Vampire mod for 1.02b8 if I want to use 1.02b8 for a different mod? (I'll probably do it anyway but just trying to confirm)


You dont have to update your mod if you are not using features of the newer version in that mod. So if your Enhanced Vampires was built on 1.02b5 it will still be run fine by 1.02b8.

I would just tell your users which version they should get for which mod ( like version >=1.02b5 for the Vampire mod and >=1.02b8 for your other mod).
Of course you can just always compile your mods against the newest version and just require that. if you do just remember your players to update the utility aswell if you use methods not present in older versions (and delete the older version).

Good luck with your new "mysterie mod", cant wait to see whats that :D
Scholar
Original Poster
#5 Old 21st Apr 2021 at 11:32 AM
@Battery I have updated my Vampire mod to use 1.02b8

I had another question about the sim menu. Can I make it so that there's one big menu like an Nraas menu, where there will be two buttons. Clicking the button will bring up a sim selection menu. And clicking the second button will bring up another sim selection menu. And once a Sim has been selected from both of these menus we'll be able to click accept.

If you like my mods. Consider supporting me on Patreon
Check out my website for updates on my mods and other work PuddingFace.wixsite.com
Check out my Youtube channel for tutorials(modding tutorials) and other content Youtube

Follow me on Twitter Instagram Pinterest Tumblr
Space Pony
#6 Old 21st Apr 2021 at 4:54 PM
Hi @PuddingFace while it is possible to achieve this you would have to jump through some ugly hoops to accomplish that.

I can offer you working on an update to make it easier. ( cant say right now if it might break anything)
Space Pony
#7 Old 21st Apr 2021 at 8:05 PM Last edited by Battery : 21st Apr 2021 at 8:25 PM.
ok ive written a quick update for the utility and would like to get your feedback before uploading

So here is the code example

Method for the First Sim Selection


Method for the Second Sim Selection


Code
Scholar
Original Poster
#8 Old 22nd Apr 2021 at 6:52 AM
Would love to test it out. For now I was making the menus pop up one after another. But I shall test this out as well.

Btw I can use S3SE with 1.02b8 right? I've been meaning to try that mod as well.

If you like my mods. Consider supporting me on Patreon
Check out my website for updates on my mods and other work PuddingFace.wixsite.com
Check out my Youtube channel for tutorials(modding tutorials) and other content Youtube

Follow me on Twitter Instagram Pinterest Tumblr
Scholar
Original Poster
#9 Old 22nd Apr 2021 at 3:24 PM
Ok so right now the way I'm using this is that the first menu pops up and then after selecting a sim the second menu pops up. And that's working fine at the moment. So It's your wish if you want to add this feature or not.

I think you should wait a bit before quickly updating. Maybe you can expand on what you're doing by making the selected sim's face appear just like how an integer value or bool value can appear when we change it.
The Hospital Overhaul mod has done this with it's UI.
But this is not urgent or anything. The current system is working just fine.

If you like my mods. Consider supporting me on Patreon
Check out my website for updates on my mods and other work PuddingFace.wixsite.com
Check out my Youtube channel for tutorials(modding tutorials) and other content Youtube

Follow me on Twitter Instagram Pinterest Tumblr
Back to top