User Profile PLUS EMU Avatar not load

Status
Not open for further replies.

Marko97

M97 Project based Plus EMU
Aug 7, 2013
99
45
Hello!
Why the avatar in user profile not load and the badges if the user is offline are hidden?
And how to fix?

Best Regards :)
userprofile_bug.png
 

Michell

god x
Nov 15, 2011
151
22
Check your external override variables and normal variables, check also all links in client.php - Nothing works? Try different SWF pack.
 

Marko97

M97 Project based Plus EMU
Aug 7, 2013
99
45
The avatar load when I close and reopen the window. It's a problem with Plus EMU and not in DCR.
The badges are visible but if the user is offline, are hidden.
 

Michell

god x
Nov 15, 2011
151
22
On all the retro's they use a PlusEMU, they have everywhere the same problem as you. If a user is offline the badges will hide. You need to code this.
 

Marko97

M97 Project based Plus EMU
Aug 7, 2013
99
45
R2 by Sledmore. But these users haven't any badges ...

Ok now check in the "JayCustom" account when the account are offline, the badge work.
 
Last edited by a moderator:

Jerry

not rly active lol
Jul 8, 2013
1,956
522
Can verify I had the same issue. I found out that the badges do not show when viewing an offline user's profile because this line in UserDataFactory.cs:
Code:
List<Badge> Badges = new List<Badge>();
Does not have the foreach loop:
Code:
foreach (DataRow Row in dBadges.Rows)
            {
                Badges.Add(new Badge(Convert.ToString(Row["badge_id"]), Convert.ToInt32(Row["badge_slot"])));
            }
in the GetUserData(int UserId) static function.

To make it so that badges show on offline users, find this:
Code:
DataTable dGroups = null;

Paste this under it:
Code:
DataTable dBadges = null;

Find this:
Code:
dbClient.SetQuery("SELECT `id`,`target`,`type` FROM user_relationships WHERE user_id=@id");
                dbClient.AddParameter("id", UserId);
                dRelations = dbClient.GetTable();

Paste this under it:
Code:
 dbClient.SetQuery("SELECT `badge_id`,`badge_slot` FROM user_badges WHERE `user_id`=@id");
                dbClient.AddParameter("id", UserId);
                dBadges = dbClient.GetTable();

And finally, find this:
Code:
List<Badge> Badges = new List<Badge>();

Paste this under it:
Code:
foreach (DataRow Row in dBadges.Rows)
            {
                Badges.Add(new Badge(Convert.ToString(Row["badge_id"]), Convert.ToInt32(Row["badge_slot"])));
            }

Compile changes and it should work.
 
Status
Not open for further replies.

Users who are viewing this thread

Top