Does anyone have saved copy of IMVU's Unity API?

Questions, Tips and Concerns about Creating on IMVU in general.
DimitriX89
Sage Pixel
Posts: 57
Joined: Fri Mar 10, 2017 4:01 am

Re: Does anyone have saved copy of IMVU's Unity API?

Post by DimitriX89 » Wed Oct 09, 2019 6:18 am

And just for future reference: we got it working in Unity 2019 3.0a8 (by faking the path it demanded), while in 2019.2.8f1 demos never get to login stage, only displaying yellow warnings after a while: https://gyazo.com/f7f9000fee1f7d00c9d6933d651d3925 Impression like Unity terminates some process because it takes too long

User avatar
nerseus
Sage Pixel
Posts: 40
Joined: Fri Mar 10, 2017 1:40 pm
Location: Arizona
IMVU Homepage: http://avatars.imvu.com/nerseus
Contact:

Re: Does anyone have saved copy of IMVU's Unity API?

Post by nerseus » Wed Oct 09, 2019 7:10 am

Interesting... I'm using 2019.2.5f1 and don't see anything like that in the console. I'll upgrade today and push up a change that fixes a few things. I'm hoping to fix the FeedPost as well, but I won't let that keep me from pushing a fix.
I'm always around to answer meshing questions! PM me or find me on Skype: djatarchon

(I also take mesh requests from time to time)

DimitriX89
Sage Pixel
Posts: 57
Joined: Fri Mar 10, 2017 4:01 am

Re: Does anyone have saved copy of IMVU's Unity API?

Post by DimitriX89 » Wed Oct 09, 2019 4:48 pm

I managed to run it, but now there are new runtime errors and the resulting avatar isnt visible (though it creates avatar hierarchy in the scene): https://gyazo.com/13dabdd9387d34e67432d98522e2ca77 The code I used for loader: https://pastebin.com/55EgUzYn Unity 2019 3.0.b6

User avatar
nerseus
Sage Pixel
Posts: 40
Joined: Fri Mar 10, 2017 1:40 pm
Location: Arizona
IMVU Homepage: http://avatars.imvu.com/nerseus
Contact:

Re: Does anyone have saved copy of IMVU's Unity API?

Post by nerseus » Thu Oct 10, 2019 10:27 am

Doing some testing with Unity 2019.2.8f1 - but so far, testing is working fine. I'm not seeing the errors you are. I've tried 2 sample projects:

1. Running the Outfit demo in a clean install
- Create a new 3D project; I didn't include any extra modules as I'm testing in Windows 10 and nothing else was/is needed.
- Once the empty project loaded, I imported the unity package (all files)
- Opened the Outfit demo and ran
I see the login window; entered my credentials; the rest of the demo seemed to run just fine.

2. Running with an empty scene and minimal script:
- Created an empty scene with just Main Camera and a Directional Light
- Added one empty GameObject
- Created a new script, using your sample code. Essentially just:
void Start()
{
Imvu.Connect("username", "password").Then(
userModel => Load(userModel)
);
}

Running the scene loads my avatar and shows it in the T-pose. No errors or issues.
I'm always around to answer meshing questions! PM me or find me on Skype: djatarchon

(I also take mesh requests from time to time)

DimitriX89
Sage Pixel
Posts: 57
Joined: Fri Mar 10, 2017 4:01 am

Re: Does anyone have saved copy of IMVU's Unity API?

Post by DimitriX89 » Fri Oct 11, 2019 2:17 am

I'd think it is something related to my local computer, but I've tried it on 2 machines for same result. Same Unity version as the person who reported it working, same packages installed. Finally, I've connected to his computer via Parsec and ran my project from there; it worked just fine. No idea what it can be. Some restrictions by Russian internet providers? But I can run IMVU itself just fine, and as I understand, IMVUnity uses same servers as Next. Textures get downloaded, only models and skeletons are somehow the problem. Error messages say that error happens in ner.imvu.BoneScaler function; any idea what can cause it to receive invalid Quaternion input?

User avatar
nerseus
Sage Pixel
Posts: 40
Joined: Fri Mar 10, 2017 1:40 pm
Location: Arizona
IMVU Homepage: http://avatars.imvu.com/nerseus
Contact:

Re: Does anyone have saved copy of IMVU's Unity API?

Post by nerseus » Fri Oct 11, 2019 6:48 am

Interesting...
I wonder if it has to do with how decimal values are formatted. Either IMVU sending back data in a localized format and the unity code not interpreting that, or vice versa - Unity/DotNet assuming values are localized.

Since the server name is fixed in code, I'm pretty sure the data sent back will be the same for everyone regardless of region. Although... it's possible imvu pulls some region info out of the headers.

I'll poke around and see if I can see where localization is, or isn't, happening...
I'm always around to answer meshing questions! PM me or find me on Skype: djatarchon

(I also take mesh requests from time to time)

User avatar
nerseus
Sage Pixel
Posts: 40
Joined: Fri Mar 10, 2017 1:40 pm
Location: Arizona
IMVU Homepage: http://avatars.imvu.com/nerseus
Contact:

Re: Does anyone have saved copy of IMVU's Unity API?

Post by nerseus » Fri Oct 11, 2019 8:16 am

Poking around the parsing code - IMVU implements their own JSON parsing, including number parsing.
That code specifically looks for decimal values in English/Imperial format with a "." as a decimal separator. That is "1.5" is one and a half. I believe in Russian and other systems that would be stored as "1,5"?

But... that would only be an issue if IMVU's api returned data in different formats depending on who was requesting the data, which seems unlikely.

Try going to the following URL:
https://asset-server-akm.imvu.com/asset ... uY2Zs/1335

You should see some JSON data like:

Code: Select all

{"bones":[{"flags":{},"inverseBindPoseTransform":{
"rotation":[0.0,0.0,0.0,-1.0],"translation":[-0.0,-0.0,-0.0]},
"name":"Female03MasterRoot","relativeTransform":{
"rotation":[-0.7071067690849304,0.0,0.0,0.7071067690849304]
...
I'm curious if those "rotation" values show up the same for you, like "-0.707..."?
I'm always around to answer meshing questions! PM me or find me on Skype: djatarchon

(I also take mesh requests from time to time)

DimitriX89
Sage Pixel
Posts: 57
Joined: Fri Mar 10, 2017 4:01 am

Re: Does anyone have saved copy of IMVU's Unity API?

Post by DimitriX89 » Fri Oct 11, 2019 10:56 am

JSON looks the same for me,digits in the fractions separated by the dots. BTW, by "IP restrictions" I meant different thing: internet resources actually banned by our control organisations. Like about a year ago, the owner of Telegram messenger refused to comply to some Russian government regulations and started to use Amazon proxies to avoid then. That lead to Roscomnadzor (the control organisation) banning Amazon-related URLs left and right. The incident was sorted long ago and everything was unbanned since then. A paranoid theory but I simply do not have any ideas. Even an *.exe build of the project displays the same error, so it is not Unity version or some package problem.

User avatar
nerseus
Sage Pixel
Posts: 40
Joined: Fri Mar 10, 2017 1:40 pm
Location: Arizona
IMVU Homepage: http://avatars.imvu.com/nerseus
Contact:

Re: Does anyone have saved copy of IMVU's Unity API?

Post by nerseus » Fri Oct 11, 2019 11:16 am

Hmm... so the EXE doesn't work on your machine? Can you send the EXE to your friend and verify it works there? That would help narrow it down somewhat...

This seems like a slim chance... but maybe try changing some Windows settings related to your Region and Number/Date formats?
The "best" way is through: Control Panel -> Region -> Region dialog

If you search windows for "Region Settings" Windows will point you to the Windows 10 Metro settings. For me, those settings didn't let me change number formats.

If you see an old fashioned windows window, then you're in the right area.

Here's what I have:
Image
Image
Image
Image
I'm always around to answer meshing questions! PM me or find me on Skype: djatarchon

(I also take mesh requests from time to time)

DimitriX89
Sage Pixel
Posts: 57
Joined: Fri Mar 10, 2017 4:01 am

Re: Does anyone have saved copy of IMVU's Unity API?

Post by DimitriX89 » Fri Oct 11, 2019 11:33 am

Regional settings worked! You're genius! https://gyazo.com/d3054fcb7a8c95e85dede118c4d43e61

User avatar
nerseus
Sage Pixel
Posts: 40
Joined: Fri Mar 10, 2017 1:40 pm
Location: Arizona
IMVU Homepage: http://avatars.imvu.com/nerseus
Contact:

Re: Does anyone have saved copy of IMVU's Unity API?

Post by nerseus » Fri Oct 11, 2019 12:02 pm

Whew! I'm glad it's working.

And I hope to have an updated DLL/package out today with some fixes.
I'm always around to answer meshing questions! PM me or find me on Skype: djatarchon

(I also take mesh requests from time to time)

User avatar
nerseus
Sage Pixel
Posts: 40
Joined: Fri Mar 10, 2017 1:40 pm
Location: Arizona
IMVU Homepage: http://avatars.imvu.com/nerseus
Contact:

Re: Does anyone have saved copy of IMVU's Unity API?

Post by nerseus » Tue Oct 15, 2019 10:01 am

Sorry for the delay. I had a request to change the old Conversion/Exporter tools and, after a small issue where Windows thought it was a Virus - I just decided to package up the source code for those that want it.

I'll jump back on the IMVU Unity DLL today and get that updated package ready.
I spent time this weekend trying to get the posting to Feed demo working, but haven't gotten it yet. No point in holding things up for just that.
I'm always around to answer meshing questions! PM me or find me on Skype: djatarchon

(I also take mesh requests from time to time)

User avatar
nerseus
Sage Pixel
Posts: 40
Joined: Fri Mar 10, 2017 1:40 pm
Location: Arizona
IMVU Homepage: http://avatars.imvu.com/nerseus
Contact:

Re: Does anyone have saved copy of IMVU's Unity API?

Post by nerseus » Wed Oct 16, 2019 7:33 am

Updated package:
- Removed debugging code
- FeedPost demo still not working

Current (and older) versions can be found here:
http://nersoftware.com/?page_id=1387


NOTE: I'm still working on fixing the FeedPost. It seems to be almost working - just an issue with preserving credentials when it comes time to post the saved image.
I'm always around to answer meshing questions! PM me or find me on Skype: djatarchon

(I also take mesh requests from time to time)

DimitriX89
Sage Pixel
Posts: 57
Joined: Fri Mar 10, 2017 4:01 am

Re: Does anyone have saved copy of IMVU's Unity API?

Post by DimitriX89 » Thu Oct 17, 2019 12:23 am

Thats cool! Do you plan to add file path customisation? Not everyone has D:/

User avatar
nerseus
Sage Pixel
Posts: 40
Joined: Fri Mar 10, 2017 1:40 pm
Location: Arizona
IMVU Homepage: http://avatars.imvu.com/nerseus
Contact:

Re: Does anyone have saved copy of IMVU's Unity API?

Post by nerseus » Thu Oct 17, 2019 4:03 am

No File path needed. The debugging code referencing D: was just for troubleshooting transparency and resizing. I've got both of those fixed and the original imvu demo for taking a photo and displaying a thumbnail now works. Just the posting to imvu is failing.

In looking at how imvu coded/exposed things... it sure seems like they had intentions of exposing more. Ah well. Their APIs don't appear that complicated. Easy enough for a web backend dev to figure it out and expose more if they needed it.
I'm always around to answer meshing questions! PM me or find me on Skype: djatarchon

(I also take mesh requests from time to time)

Post Reply