[PlusEMU] Trouble Adding Diamond Timer [PlusEMU]

treebeard

Member
Jan 16, 2018
317
173
Hello everyone, thanks for taking the time to read this thread!

I've started working on an edit of PlusEMU and have successfully made a few of my own commands! (I'm new and excited lol)
However I've been trying to work on some features to add currency timers, diamond exchange, and some other reward based edits and have run into an issue with finding PlusStaticGameSettings.cs in my EMU.

I was following Sled's advice that he gave here:

My version of PlusEMU does not contain PlusStaticGameSettings.cs, I know this is probably just named something else in more recent revisions as all the threads I can find about these types of edits are from over a year ago. I just need some help knowing what this file is called these days or where I would make edits that would typically have been made here.

Sorry for the noob question, I am trying to actually learn though on my own instead of having someone else do it.

P.S. I always check this and other forums for over an hour before I post a new thread. Thanks for your time.
 

treebeard

Member
Jan 16, 2018
317
173
3.4.3.0 R2, sorry that part got cut out of my post here for some reason.
I know it was renamed, I don't know what it was renamed to. The threads I've seen where people ask (like the one you linked) have no answers to the question.
 
Last edited:

Joe

Well-Known Member
Jun 10, 2012
4,172
1,955
3.4.3.0 R2, sorry that part got cut out of my post here for some reason.
I know it was renamed, I don't know what it was renamed to. The threads I've seen where people ask (like the one you linked) have no answers to the question.
Yeah in R2 it was renamed. Been a while since I’ve had a look, it’s there though.

A lot of the code is different/cleaner so not sure how old addons will work.
 

treebeard

Member
Jan 16, 2018
317
173
Yeah in R2 it was renamed. Been a while since I’ve had a look, it’s there though.

A lot of the code is different/cleaner so not sure how old addons will work.
Ahh well thanks for trying! Yeah I know most threads are one year+ in age. I've been having a hard time figuring this out on my own especially as I'm literally still getting used to C#
 

treebeard

Member
Jan 16, 2018
317
173
Would help more but on my phone at the moment!
If you have time while you're home I would appreciate the help; you could post here, pm me, or Disc treebeard#1071

Thanks!
 
I found some code relating to credit timers in the method CheckCreditsTimer() in HabboHotel/Users/Habbo.cs and I tried editing this method to get the Diamond timer in my hotel but I just can't seem to get this added correctly. I have similar issues for adding diamond exchange and adding new exchangeable credit items into my hotel.
 

Queso

echo 'Web Developer';
Nov 29, 2016
232
72
This is for people using R2 of Plus Emulator.
Create PlusStaticGameSettings.cs in your main emulator folder and paste this into it

Go to Habbo.cs and find the void CheckCreditsTimer(), then change it to this

Next, find SubscriptionData.cs and replace it with this

Lastly, replace SubscriptionManager.cs with this
 

Brad

Well-Known Member
Jun 5, 2012
2,320
993
This is for people using R2 of Plus Emulator.
Create PlusStaticGameSettings.cs in your main emulator folder and paste this into it

Go to Habbo.cs and find the void CheckCreditsTimer(), then change it to this

Next, find SubscriptionData.cs and replace it with this

Lastly, replace SubscriptionManager.cs with this
Pretty sure you've just uploaded what I posted into pastebin. Nice try though.

Anyhow, to have diamond as it's owner timer here;

Goto Habbo.cs Search for CheckCreditsTimer()
Add above/below
Code:
public void CheckDiamondsTimer()
        {
            try
            {
                this._diamondsTickUpdate--;
                if (this._diamondsTickUpdate <= 0)
                {
                    int DiamondUpdate = PlusStaticGameSettings.UserDiamondsUpdateAmount;

                    if (PlusEnvironment.GetGame().GetSubscriptionManager().TryGetSubscriptionData(this._VIPRank, out SubscriptionData SubData))
                    {
                        DiamondUpdate += SubData.Diamonds;
                    }

                    this._diamonds += DiamondUpdate;
                    this._client.SendMessage(new HabboActivityPointNotificationComposer(this._diamonds, DiamondUpdate, 5));
                    this.DiamondsUpdateTick = PlusStaticGameSettings.UserDiamondsUpdateAmount;
                }
            }

            catch (Exception e)
            {
                Logging.LogException(e.ToString());
            }
        }
then search for this._player.CheckCreditsTimer(); in ProcessComponent.cs
and add
Code:
this._player.CheckDiamondsTimer();
below it.
 

Joe

Well-Known Member
Jun 10, 2012
4,172
1,955
This is for people using R2 of Plus Emulator.
Create PlusStaticGameSettings.cs in your main emulator folder and paste this into it

Go to Habbo.cs and find the void CheckCreditsTimer(), then change it to this

Next, find SubscriptionData.cs and replace it with this

Lastly, replace SubscriptionManager.cs with this
IF this is what Brad released then it doesn’t work for R2.
 

Users who are viewing this thread

Top