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!
MTS has all free content, all the time. Find out how YOU can help to keep it running. Tell me how...

TS2 > TS3 Functional Sewing table [BETA V2.0.0] - Please redownload!

by Lyralei Posted 21st Jun 2020 at 3:12 PM - Updated 20th Aug 2023 at 1:30 PM by Lyralei : Updated to v.2.0.0 and uploaded a hotfix + New Tunables.
 
412 Comments / Replies (Who?) - 334 Feedback Posts, 77 Thanks Posts
Hide Thanks Posts for this thread (Show only feedback)
Page 4 of 17
Virtual gardener
staff: administrator
Original Poster
#76 Old 6th Aug 2020 at 12:02 PM
@Cidsan (and others!)

Currently, from a technical perspective i'm not able to have the patterns be discovered while the interaction is looping. So for now, if you cancel the interaction, then you'll get it (So how it used to be)

If you're curious to the technical details as to why it's not possible, here we go:
First, you'll need some knowledge about looping. I talked about it right here: https://modthesims.info/showthread.php?t=642029

The patterns have a script when we want a pattern to be discovered. This script basically takes care of: Whether the sim already knows the pattern, Which pattern to discover, And whether this pattern is valid for their skill level. It also adds data to said pattern so that we can distinguish in-game which object it will eventually create.
Now, this function itself requires quite some reading from the game. So what happens, is that the looping function is being called every sim second basically. Meaning, the code needs to execute REALLY fast. So, if you have a function that needs to do so much, but can't keep up with the speed that the game wants it to go through it, it basically throws up it's hands and goes "Eh screw this"... that is, if code had hands.

So, see it this way: Imagine, I were to ask you to read a book of 600 pages. Now, think of how long it would take you to do that. Probably at least a day or 3 (or more). But, because of some circumstances (world exploding, killer bees invading the world, whatever :p)  You need to finish this book in 10 seconds. That's just impossible, especially if afterwards you need to tell someone in detail what the book was about. That's the crisis this code is having 

Anyways, it should be fixed! It's a bit of a cheaty fix, but for now, that's all I can do 
Lab Assistant
#77 Old 6th Aug 2020 at 2:42 PM Last edited by Cidsan : 6th Aug 2020 at 2:55 PM.
Quote: Originally posted by Lyralei
@Cidsan (and others!)

Currently, from a technical perspective i'm not able to have the patterns be discovered while the interaction is looping. So for now, if you cancel the interaction, then you'll get it (So how it used to be)

If you're curious to the technical details as to why it's not possible, here we go:
First, you'll need some knowledge about looping. I talked about it right here: https://modthesims.info/showthread.php?t=642029

The patterns have a script when we want a pattern to be discovered. This script basically takes care of: Whether the sim already knows the pattern, Which pattern to discover, And whether this pattern is valid for their skill level. It also adds data to said pattern so that we can distinguish in-game which object it will eventually create.
Now, this function itself requires quite some reading from the game. So what happens, is that the looping function is being called every sim second basically. Meaning, the code needs to execute REALLY fast. So, if you have a function that needs to do so much, but can't keep up with the speed that the game wants it to go through it, it basically throws up it's hands and goes "Eh screw this"... that is, if code had hands.

So, see it this way: Imagine, I were to ask you to read a book of 600 pages. Now, think of how long it would take you to do that. Probably at least a day or 3 (or more). But, because of some circumstances (world exploding, killer bees invading the world, whatever :p)  You need to finish this book in 10 seconds. That's just impossible, especially if afterwards you need to tell someone in detail what the book was about. That's the crisis this code is having 

Anyways, it should be fixed! It's a bit of a cheaty fix, but for now, that's all I can do 


I can't talk or discuss what I don't know.
And I couldn't open the ink you sent. I understand that the Sims 3 is very complicated, its mechanics are too complex, but I have a lot of confidence and hope in your work, which incidentally enchanted us, please don't give up.
Just an idea, what if the standards were limited? Wouldn't it help the code and the reading of these? I am anxious and obsessed with the 1.0.3 update, from what I could in my ignorance observe this is what you explain about the speed of reading. Plenty to read, and little time to execute.
Anyway, my sewing room is still waiting for your machine, :P

PS: I think I was slow to answer hahaha. I will test your update. Thankful.
Lab Assistant
THANKS POST
#78 Old 6th Aug 2020 at 3:57 PM
Lyralei tested it, and right after that warning I showed you, it froze again. One thing I noticed is that when trying to move the screen, everything goes black, this is strange because when I remove the mod and clear the cache this event does not happen. And I repeat, it only freezes after that warning appears that she discovered a new project, I just found it strange to have discovered a project without starting sewing again.
Looking for you.
Lab Assistant
#79 Old 6th Aug 2020 at 8:32 PM
Hi, I made a Dutch translation for the objects that still needed it
Love the sewing table, my single part time working mom with hectic toddler loves it XD
Attached files:
File Type: rar  LYRALEI_SewingTable_DutchAdded.rar (4.54 MB, 6 downloads)
Space Pony
#80 Old 7th Aug 2020 at 12:34 AM
Quote: Originally posted by Lyralei
The patterns have a script when we want a pattern to be discovered. This script basically takes care of: Whether the sim already knows the pattern, Which pattern to discover, And whether this pattern is valid for their skill level. It also adds data to said pattern so that we can distinguish in-game which object it will eventually create.
Now, this function itself requires quite some reading from the game. So what happens, is that the looping function is being called every sim second basically. Meaning, the code needs to execute REALLY fast. So, if you have a function that needs to do so much, but can't keep up with the speed that the game wants it to go through it, it basically throws up it's hands and goes "Eh screw this"... that is, if code had hands.

So, see it this way: Imagine, I were to ask you to read a book of 600 pages. Now, think of how long it would take you to do that. Probably at least a day or 3 (or more). But, because of some circumstances (world exploding, killer bees invading the world, whatever :p)  You need to finish this book in 10 seconds. That's just impossible, especially if afterwards you need to tell someone in detail what the book was about. That's the crisis this code is having 


This is perhaps a bit too technical for this forum, but have you tried using Simulator.AddObject()? That's usually a quick way to help alleviate performance issues. The basic idea is that you pass in a OneShotFunctionTask object containing a "delegate" (i.e. the function/code you want to run) that will be run once when the game engine feels like it on a separate thread. Since in most cases the engine starts simulating these added objects almost instantaneously, this allows for sort-of-asynchronous programming, where the only overhead in your main loop would be instantiating the object and adding it to the Simulator queue (i.e. not a lot). Here's a simple example:

Code:
// public static void AddPattern() { ... }

while (looping)
{
    // Note the lack of parentheses, only the name of the method is provided
    Simulator.AddObject(new OneShotFunctionTask(new Function(AddPattern)));
}


If you need to pass in a parameters to your delegate code, use OneShotFunctionWithParams. Multiple arguments can be using an array, class, or struct:

Code:
// public static void AddPattern(Object arg) { ... }

var x = "Test";
Simulator.AddObject(new OneShotFunctionTaskWithParams(new FunctionWithParam(AddPattern), x));

"The Internet is the first thing that humanity has built that humanity doesn't understand, the largest experiment in anarchy that we have ever had." - Eric Schmidt

If you enjoy the mods I put out, consider supporting me on patreon: www.patreon.com/Gamefreak130
Virtual gardener
staff: administrator
Original Poster
#81 Old 7th Aug 2020 at 12:41 PM
Quote: Originally posted by gamefreak130
This is perhaps a bit too technical for this forum, but have you tried using Simulator.AddObject()? That's usually a quick way to help alleviate performance issues. The basic idea is that you pass in a OneShotFunctionTask object containing a "delegate" (i.e. the function/code you want to run) that will be run once when the game engine feels like it on a separate thread. Since in most cases the engine starts simulating these added objects almost instantaneously, this allows for sort-of-asynchronous programming, where the only overhead in your main loop would be instantiating the object and adding it to the Simulator queue (i.e. not a lot). Here's a simple example:

Code:
// public static void AddPattern() { ... }

while (looping)
{
    // Note the lack of parentheses, only the name of the method is provided
    Simulator.AddObject(new OneShotFunctionTask(new Function(AddPattern)));
}


If you need to pass in a parameters to your delegate code, use OneShotFunctionWithParams. Multiple arguments can be using an array, class, or struct:

Code:
// public static void AddPattern(Object arg) { ... }

var x = "Test";
Simulator.AddObject(new OneShotFunctionTaskWithParams(new FunctionWithParam(AddPattern), x));
Hey @gamefreak130 ! 

Interesting! I did see the OneShotFunctions a few time times, but I honestly thought they were more related to functions inside the Jazz scripts. But then, I hadn't really researched what it did, to begin with, just noticed it worked with some delegate :p Cool to hear that TS3 (Or even C# for that matter, honestly hadn't researched this) has some form of asynchronous programming. Pretty used to it for Javascript since a job I used to work at insisted I'd use it for... well almost every function. But wasn't aware that C# had something like it.

I'll check it out since it might fix the issue, as I did indeed notice how back then, the memory would jump from 1.2GB to 1.9GB due to it having to constantly call it. And we all know how much TS3 can eat memory

Thanks for you help! Maybe I should actually make a technical thread for these things. It would probably help to have some more support on issues like these.
Virtual gardener
staff: administrator
Original Poster
#82 Old 7th Aug 2020 at 12:49 PM
Quote: Originally posted by Cidsan
Lyralei tested it, and right after that warning I showed you, it froze again. One thing I noticed is that when trying to move the screen, everything goes black, this is strange because when I remove the mod and clear the cache this event does not happen. And I repeat, it only freezes after that warning appears that she discovered a new project, I just found it strange to have discovered a project without starting sewing again.
Looking for you.
Hrm that doesn't sound good, indeed. Did you redownload v1.0.3? That one I updated yesterday  

I just triple-tested the version I brought out yesterday as well but didn't see it freezing on full speed when my sim discovered a new pattern. So when installing a new version of the mod, make sure to do everything in this orde:

- Delete at least the ScriptCache.package. If you're not on Mac, it might be wise to also delete the WorldCaches > WORLDNAME_Objects,package file. 
- Download (in this case v1.0.3) and put it in your mods folder.
- IF the sewing table is already placed on the lot, it might work to delete the old sewing table and replace it with a newly fresh one. 

1.0.3 regarding discovering patterns actually got turned back to how 1.0.2 used to work, hopefully, that makes it feel a bit safer! Because I do get it's a bit of an uncertain thing to work with. I'll also add a banner in the description for anyone else who happened to have this issue, so they know what to do

In the meanwhile, I'll check out the thing Gamefreak suggested!
Virtual gardener
staff: administrator
Original Poster
#83 Old 7th Aug 2020 at 12:50 PM
Quote: Originally posted by Lessien Vardamir
Hi, I made a Dutch translation for the objects that still needed it
Love the sewing table, my single part time working mom with hectic toddler loves it XD
Hiya! Thanks for the dutch translation! I honestly forgot that those still needed doing :p I'll add it as soon as I can!
Test Subject
#84 Old 10th Aug 2020 at 12:17 AM
Good Evening, I am trying to use the sewing Machine with no success. I think it is a great idea. The problem is when I try to get my sim to practice sewing my game completely locks up. He will start just a little but then my whole game locks up. I don't see anything about this, although I may have missed it. I have done all the updates to it so far. Is there any help? Thanks
Virtual gardener
staff: administrator
Original Poster
#85 Old 10th Aug 2020 at 5:53 PM
Hiya @bahama58 !

I think I screwed up the reupload and it still having the old one. Could you check if redownloading v.1.0.3 does the trick for you? It did for me

Thanks!
Test Subject
THANKS POST
#86 Old 11th Aug 2020 at 2:03 PM
Amazing!! i can't wait to try it out
thank you so much <33
Test Subject
#87 Old 12th Aug 2020 at 1:51 AM
Quote: Originally posted by Lyralei
Hiya @bahama58 !

I think I screwed up the reupload and it still having the old one. Could you check if redownloading v.1.0.3 does the trick for you? It did for me

Thanks!


Hello, yes I did redownload v.1.0.3 and solved the problem. Works great. Hope we will be seeing some knitting also. Love to knit shawls and socks.
Lab Assistant
THANKS POST
#88 Old 13th Aug 2020 at 3:45 AM
This is so awesome! Now I have something to add to my victorian stories.All we need now is a spinning wheel!
Lab Assistant
#89 Old 15th Aug 2020 at 10:29 PM
This was working just fine for me but now it seems everytime my sim tries to get up from sewing the game completely freezes.And I have v1.03
installed.

It will happen if I cancel her action to have her get up to go do something, the game will just freeze.I can move the mouse but that's it.I end up having to ctrl alt delete out of the game.
I have Nraas mods installed and tried clearing my cache.
Virtual gardener
staff: administrator
Original Poster
#90 Old 16th Aug 2020 at 3:49 PM
Quote: Originally posted by springfairy556
This was working just fine for me but now it seems everytime my sim tries to get up from sewing the game completely freezes.And I have v1.03
installed.

It will happen if I cancel her action to have her get up to go do something, the game will just freeze.I can move the mouse but that's it.I end up having to ctrl alt delete out of the game.
I have Nraas mods installed and tried clearing my cache.
Hi @springfairy556 !

It might be that you still happen to have the older version of v1.0.3, so make sure to redownload that version and replace it in your mods folder. People have actually reported back that the v1.0.3 version uploaded right now does fix the freezing issue. 

hope this helps!
Test Subject
#91 Old 17th Aug 2020 at 12:08 AM
Hi! So I downloaded this, got into my game, got it out, and it was invisible unless i got close to it! Did I do something wrong?
Lab Assistant
#92 Old 17th Aug 2020 at 3:04 AM
I only installed the mod once.V103 was the first time installing it, as I had just discovered this mod a couple days ago.
Virtual gardener
staff: administrator
Original Poster
#93 Old 17th Aug 2020 at 11:53 AM
Quote: Originally posted by Pumpkinhero2
Hi! So I downloaded this, got into my game, got it out, and it was invisible unless i got close to it! Did I do something wrong?
It *might* be your texture settings. For some bizarre reason, the game doesn't load the textures of the table at a low-texture detail settings :/ (see: technical issues in the description). still looking into it, but just can't seem to find as to why that happens.
Test Subject
#94 Old 17th Aug 2020 at 9:45 PM
Quote: Originally posted by Lyralei
It *might* be your texture settings. For some bizarre reason, the game doesn't load the textures of the table at a low-texture detail settings :/ (see: technical issues in the description). still looking into it, but just can't seem to find as to why that happens.

oh ok. My game has been running pretty well so i was thinking about doing this already! ill see if it works
Virtual gardener
staff: administrator
Original Poster
#95 Old 20th Aug 2020 at 12:44 PM
@springfairy556 and anyone else, I've uploaded v1.0.4 which should fix the issue you're having regarding the practise interaction freezing.

Make sure to delete the previous package (v1.0.3) and put this one in your mods folder. Also make sure to delete your cache packages.
Lab Assistant
THANKS POST
#96 Old 22nd Aug 2020 at 3:13 PM
Thank you for the updates.
Undead Molten Llama
THANKS POST
#97 Old 23rd Aug 2020 at 11:54 PM
This is just fantastic! The sewing machine is one of my favorite things in TS2, so it's wonderful to have it for TS3. Thank you for all of your hard work and for sharing the fruits of your labor! :D
Lab Assistant
THANKS POST
#98 Old 24th Aug 2020 at 2:21 AM
That fixed it for me.=) Thanks!
Test Subject
#99 Old 26th Aug 2020 at 1:39 AM
Quote: Originally posted by Pumpkinhero2
oh ok. My game has been running pretty well so i was thinking about doing this already! ill see if it works


ik its been forever but it works now! Tysm for your help! :D
#100 Old 26th Aug 2020 at 6:26 AM
I tried to buy this for my sim but it was invisible. You say to report what my sim was doing before this but there WAS no sim at this point, just a house with an invisible sewing machine.
Page 4 of 17