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!
Test Subject
Original Poster
#1 Old 18th Dec 2009 at 1:01 AM
Default Error: UV Scaling overflow
Hi everyone,

I'm just starting out as a complete newbie at meshing and so far, converting some TS2 hairs has actually taught me a lot.

So now I wanted to try objects and started out with the Cricket bats - that's when I encountered the UVscaling overflow error for the first time. But I searched through the forum and found Wes_Howe's answers in some of the threads and applied his solution of filling in 0.000030518 as the UVScale value and it worked like magic...

Emboldened that the mesh actually showed up and was mapped right and everything, I started conversing the Mr. Badger painting from Seasons and again got the overflow error. Only this time, changing the UVScale values did nothing.

I searched around some more and found the advise that my texture should have the same height to width ratio as the texture of the cloned object. Before that I had made my texture a square, even though the texture of the cloned object was far higher than it was wide. So I changed that too.

But I still get the overflow error.

I made sure that I have all the newest versions of the tools and I followed the advise given in previous threads on the subject.

So now I'm at my wit's end - maybe I made a really dumb mistake and forgot to do something? Can anyone help me?
Advertisement
Alchemist
#2 Old 18th Dec 2009 at 6:04 AM
You are using an already damaged mesh file, left over from your use of an older version. The UV map in that mesh is out-of-bounds... it can be fixed by manually scaling the UV map smaller, but it is probably easier to start back at the decompile step using the new ObjTool you downloaded.

The newer version does not require that you change the UVScales values, it just does that for you automagically. But that change will not fix a mesh that was decompiled with the older tool, because the UV map was stretched by the older version.

If you like to say what you think, be sure you know which to do first.
Test Subject
Original Poster
#3 Old 18th Dec 2009 at 8:59 PM Last edited by Gisu : 18th Dec 2009 at 11:06 PM.
I did start from the very beginning after downloading the newest version of objTool. So it wasn't decompiled with the old version. Sorry, I probably should have said that earlier.

ETA: I started the whole thing again. Chose a different painting to clone and this time made sure to map the whole thing above and left of the mapping of the original object. And I still get the error message...

This is getting frustrating.

Just to make sure I got it all in the right order:

1. I export the mlod and modl files and decompress them in ObjTool
2. then I import the s3asc into Milkshape and the obj. file I want to replace it with and change whatever needs to be changes (I followed Jonesi's tutorial at BPS for that)
3. map the whole thing in Milkshape and stay above and left of the map points of the cloned object
4. make sure the groups are still the same names and order as the original object's and export to s3asc again
5. recompile the files with ObjTool

and that's where everything goes wrong for me...

Am I missing/forgetting something? It worked on the first object I tried, but now I can't seem to reproduce that result...
Alchemist
#4 Old 18th Dec 2009 at 11:13 PM
When you are replacing all of the mesh with a .obj file, it is not the UVScales problem. After fixing the UVScales issue, step 3 in your list is not really needed, but the map has to be within bounds. The problem is probably in the UV mapping in the .obj file. Some part of the map is <0.0 or >1.0. Unless you get that corrected it will never display right in the game.

If you like to say what you think, be sure you know which to do first.
Alchemist
#5 Old 18th Dec 2009 at 11:59 PM
It sounds like every object you're making is getting the UV scales problem. Are you sure you're using the current version of the ObjTool? I know I had to delete my desktop shortcut and create a new one when I upgraded my ObjTool...if you don't you just keep using the old ObjTool version you have. Could it be something like that which is causing your issue?

With the newest version of the ObjTool you shouldn't even have to match the ratio of your new dds to the old one or map above and to the left of the original EA mesh...I don't do either of these things anymore and I don't get a scales error.
Test Subject
Original Poster
#6 Old 19th Dec 2009 at 12:19 AM
Quote: Originally posted by WesHowe
When you are replacing all of the mesh with a .obj file, it is not the UVScales problem. After fixing the UVScales issue, step 3 in your list is not really needed, but the map has to be within bounds. The problem is probably in the UV mapping in the .obj file. Some part of the map is <0.0 or >1.0. Unless you get that corrected it will never display right in the game.


Oh, okay. So then I've been pulling my hair out for all the wrong reasons. I was sure I was doing something wrong with the mapping. But if it's the TS2 mesh itself that is giving off the error, then it's no wonder it never worked, no matter what I did.

Is there any way to fix the values on the obj. file or should I just give it up as a bad job?


Thanks for your answer, orangemittens, but I'm 150% sure I've got the right version. I had the old version for the first object I made and encountered this error for the first time - I searched the forum and that's when I realized it wasn't up to date. Since then I downloaded the current version about five times in the last two days, because the second object was giving me such a hard time. And I always made sure to use the one I had just downloaded, but it didn't help any...
Alchemist
#7 Old 19th Dec 2009 at 12:27 AM
"I had the old version for the first object I made"...that explains that then

It sounds like, between what Wes has posted and you have now posted, you just need to remap your painting mesh. I think it is possible to fix the values on the obj. file as you can see here in this link where Wes showed me how to fix what I think he is referring to in the post above:

http://www.modthesims.info/showthread.php?t=375570

but I think you're probably better off just remapping.
Test Subject
Original Poster
#8 Old 19th Dec 2009 at 12:50 AM
Quote: Originally posted by orangemittens
"I had the old version for the first object I made"...that explains that then

It sounds like, between what Wes has posted and you have now posted, you just need to remap your painting mesh. I think it is possible to fix the values on the obj. file as you can see here in this link where Wes showed me how to fix what I think he is referring to in the post above:

http://www.modthesims.info/showthread.php?t=375570

but I think you're probably better off just remapping.


Maybe I'm not quite understanding the discussion in the link you posted (a very likely possibility as I'm not exactly well versed in any of this stuff), but I see nothing about fixing the values in the actual obj. file. Wes is explaining the correction of data in the mlod file in that thread, isn't he?

For remapping I can simply use the Texture coordinator in Milkshape, right? But isn't that what I did in step 3 or do I have to actually press the remap button in the coordinator?

Sorry for the inane questions, but I'd rather ask now, then do it wrong again...
Alchemist
#9 Old 19th Dec 2009 at 12:59 AM
From Wes' side of that conversation:

"if your MTLSRC files are not copied from some old version it is likely that the UV coordinates are broken in one of the *.s3ascg files"

and this is editable in the MLOD and MODL using notepad.

Again Wes's side of that conversation:

"UV values are easy enough to spot, though, as they are the only lines that come in twos instead of threes and ones. Knowing that -0.07 resulted from overflow from 1.07 is a different issue, but it had to be on one side or the other. I just moved it back to 1.0"

so what you do is open your mlod and modl. Look at the code for the .s3ascg and find the ones that are in twos. Change the number there to 1.0.

If you need an example to illustrate that you can download my broken package and Wes' fixed one...they are both still there. Compare the two and you'll see how he fixed it.
Alchemist
#10 Old 19th Dec 2009 at 1:07 AM
Yes...for remapping you can use the MS Texture Coordinator Editor. Although chances are that if you simply hit remap you're gonna end up with something you don't want.
Test Subject
Original Poster
#11 Old 19th Dec 2009 at 1:06 AM
Quote: Originally posted by orangemittens
From Wes' side of that conversation:

"if your MTLSRC files are not copied from some old version it is likely that the UV coordinates are broken in one of the *.s3ascg files"

and this is editable in the mtlsrc using notepad.

Again Wes's side of that conversation:

"UV values are easy enough to spot, though, as they are the only lines that come in twos instead of threes and ones. Knowing that -0.07 resulted from overflow from 1.07 is a different issue, but it had to be on one side or the other. I just moved it back to 1.0"

so what you do is open your mtlsrc for the mlod and modl. Look at the lines and find the ones that are in twos. Change the number there to 1.0.

If you need an example to illustrate that you can download my broken package and Wes' fixed one...they are both still there. Compare the two and you'll see how he fixed it.


Yes, but in his answer to my problem in this thread he said it's the obj. file that has the wrong values in it, not the s3ascg file. So changing the values in the mtlsrc files is only going to change anything in the s3ascg file and not the obj I imported as the replacement, isn't it?
Because I already tried changing the UVScale values in the mtlsrc files to his standard 0.000030518 as well as to 1.00 and it didn't change anything. I couldn't find any values above 1.0 or below 0.0 either...
Alchemist
#12 Old 19th Dec 2009 at 1:19 AM
You overwrite the .s3ascg with your obj. So errors in the obj are then transferred to the .s3ascg. This isn't in the mtlsrc...sorry...I edited very quickly but it seems you saw my post just before that. But your issue is in the .s3ascg.

Open your MLOD and select your .3ascg. Open that with notepad. Look at the lines with two numbers instead of odd numbers. Those will have a value that isn't between <0.0 or >1.0.

You change those to 1.0 and save. You have to do it for every line and there are a lot of them. Then try recompiling.
Alchemist
#13 Old 19th Dec 2009 at 1:25 AM
Double posting instead of editing because of the previous miscommunication.

You will also have to do this for the MODL or else it won't recompile without error.
Test Subject
Original Poster
#14 Old 19th Dec 2009 at 1:24 AM
Quote: Originally posted by orangemittens
You overwrite the .s3ascg with your obj. So errors in the obj are then transferred to the .s3ascg.

Open your MLOD and select your .3ascg. Open that with notepad. Look at the lines with two numbers instead of odd numbers. Those will have a value that isn't between <0.0 or >1.0.

You change those to 1.0 and save. You have to do it for every line and there are a lot of them. Then try recompiling.


I was just about to edit my earlier post, because I looked at the files and I do understand how he changed it (not that I understand what exactly those changes do, but that's probably far beyond my reach at this point anyway). And I took a look at my own s3ascg file and I do see a lot of values with a minus signs.

I'm sorry, I misunderstood what he meant about the obj. file. I thought you had to change/fix the obj. file before importing it into the s3ascg. I didn't think you could fix that after it was already in the s3ascg.
Sorry, my bad. *facepalm*

ETA: Forgot to say thanks - my grandma's probably rotating in her grave right now...

Thank you!!!

I'm changing it right now, be back in a few to tell you if it worked...
Alchemist
#15 Old 19th Dec 2009 at 1:37 AM
s'ok...you're welcome

I don't understand exactly what exactly those changes do either...I just know it worked.

The editing power of the ObjTool is a very nice thing.
Test Subject
Original Poster
#16 Old 19th Dec 2009 at 2:20 AM Last edited by Gisu : 19th Dec 2009 at 2:34 AM.
Well, it's not working. I've gone through the file four times now and the first two times a apparently had overlooked a few. But now I'm very sure that I've changed them all and it's still giving me the overflow error...

ETA: Gotta go - I'll try the whole thing from start again tomorrow and hopefully come back with better results...
Alchemist
#17 Old 19th Dec 2009 at 4:09 AM
Well if you get an error again it might be helpful to take a screenshot of the error message you're getting and post it here.
Test Subject
Original Poster
#18 Old 19th Dec 2009 at 2:13 PM
It finally worked. I started the whole thing over again and replaced all those numbers in the s3ascg file and it finally recompiled without problems. I think I may have missed on of those 1.000002 values yesterday. All those numbers were giving me a headache.

Do I have to do this with every TS2 item I want to convert? Because that's kind of an off-putting thought...

Anyway, I finished the final steps and imported everything back into the package and put it into my game. And now I have another problem. While the painting does show up, it's pretty much invisible - there's only a little bit of the shadow actually visible. It shows up in the catalog with an empty thumb and I can place it even, but it's simply invisible...

Any idea how that can happen?
Alchemist
#19 Old 19th Dec 2009 at 8:14 PM
"Do I have to do this with every TS2 item I want to convert? Because that's kind of an off-putting thought..."

I don't think so...I think your alternative is to map them correctly...in and of itself something of a chore at times but probably not as tedious as changing all those numbers.
Test Subject
Original Poster
#20 Old 19th Dec 2009 at 10:29 PM
Quote: Originally posted by orangemittens
"Do I have to do this with every TS2 item I want to convert? Because that's kind of an off-putting thought..."

I don't think so...I think your alternative is to map them correctly...in and of itself something of a chore at times but probably not as tedious as changing all those numbers.


That's... still somewhat off-putting. But I'll keep trying, I did get the painting into the game, at least. One day I'll get it to be visible too!
Alchemist
#21 Old 20th Dec 2009 at 1:15 AM
Some UV Mapping programs will help you fix out of bounds values, and some will scale UVs for you. The real problem is that the file is bad... however the Sims 2 exporter did not check bounds on UVs... they are not compressed and 1.02 would wrap in the game to 0.02.

In Sims 3 objects, the UV, well all of the data is placed in a compressed format, and it is by design limited to the range between 0.0 and 1.0. So the exporter checks that the values all fit, otherwise you would export something and have a terrible result, and lacking any error report you could spend a long time trying to find where the problem was.

If you like to say what you think, be sure you know which to do first.
Test Subject
Original Poster
#22 Old 20th Dec 2009 at 2:27 AM
Quote: Originally posted by WesHowe
Some UV Mapping programs will help you fix out of bounds values, and some will scale UVs for you. The real problem is that the file is bad... however the Sims 2 exporter did not check bounds on UVs... they are not compressed and 1.02 would wrap in the game to 0.02.

In Sims 3 objects, the UV, well all of the data is placed in a compressed format, and it is by design limited to the range between 0.0 and 1.0. So the exporter checks that the values all fit, otherwise you would export something and have a terrible result, and lacking any error report you could spend a long time trying to find where the problem was.


I think I understand the basic principles. The TS2 object isn't compressed and translating it into the compressed TS3 format can change the values if they were out of bound in the original format and the end result of that is usually... not good.

So in essence there are some TS2 objects that just aren't easily convertible, because we can't determine the UVScales in the TS2 exporter and the mesh could therefore come out totally borked in TS3 format...

I guess in the end they throw up more work than building the whole thing from scratch, don't they?

Is changing the values manually in the s3ascg file the reason why the object was invisible in the game? Were the value changes simply too much and totally broke the whole thing? Because there were a helluva lot values I had to change in that file and that should have some kind of effect on the object and not just the process of recompiling, shouldn't it?

At least I've learned a valuable lesson about the basics and the limits in building and converting objects from this. I think I'll use the TS2 objects as models and try to build them on my own, try to remake them rather than convert them, so to say. Then I wouldn't have those value problems, right?
Alchemist
#23 Old 20th Dec 2009 at 11:06 PM
I doubt it was the editing you did that caused your painting to be invisible. I've edited a few objects in this way now and none have ever come out invisible in the game.

I'm currently working on an object that I made myself and in order to get the pattern to tile right on it I've had to map to the very edge. This caused a UV Scales error which I fixed by editing just as you did. The object looks fine in the game. If you want to map at the edge this method is useful and does not cause objects to become invisible in the game.
Test Subject
Original Poster
#24 Old 21st Dec 2009 at 12:35 AM
Quote: Originally posted by orangemittens
I doubt it was the editing you did that caused your painting to be invisible. I've edited a few objects in this way now and none have ever come out invisible in the game.

I'm currently working on an object that I made myself and in order to get the pattern to tile right on it I've had to map to the very edge. This caused a UV Scales error which I fixed by editing just as you did. The object looks fine in the game. If you want to map at the edge this method is useful and does not cause objects to become invisible in the game.


Weird, I've tried a different painting today, to see if maybe it is just that one mesh that's giving me all those problems, but the new one isn't visible either. I'm not sure where I'm going wrong with these things...

Back to study the tutorials I shall go.
Alchemist
#25 Old 21st Dec 2009 at 1:00 AM Last edited by orangemittens : 21st Dec 2009 at 2:04 AM.
Well you know it might be a good thing to try just a basic painting tutorial before trying to convert things. Start at the beginning and go from there...just a thought...nothing in this game is easy...it's best to start with the basics.
Page 1 of 2
Back to top