[GTE] Custom Commands

JayC

Always Learning
Aug 8, 2013
5,504
1,401
Hey Devbest,

Usually I don't run into problems but I was wondering with Gold Tree Emulator where does it set so that if you say
:coins x 500
x turns into the person you last clicked / have clicked.

I would like to make it so that if they say
:stack y 4
it turns y into the last ITEM that they clicked.

The reason for this is because I just coded a command that changes the stack height of furniture in the stack, and automatically updates it. Then I realized that normal users can not see the item ID and I would rather not even let users know what the item id is of the furniture they are moving because we are at like ID 1484952 and typing that out anyway is just a pain.

Thanks,
JayCustom
 

Sledmore

Chaturbate Livestreamer
Staff member
FindRetros Moderator
Jul 24, 2010
5,198
3,914
It used to be variables, it's not emulator related. It might be the SWF now, or could still be in the variables.
 

JayC

Always Learning
Aug 8, 2013
5,504
1,401
It used to be variables, it's not emulator related. It might be the SWF now, or could still be in the variables.
The X -> username is in the variables? I'll look in the morning see what I can find with a clear head. Thanks Sledmore.
 
I could not find anything related to x= in external_flash_texts, external_variables, or external_flash_override_texts...

This might help:
Solution 1 (Preferred Solution):
I would like to know how to make it so when a user says
:stack y 4
Y turns into the item ID of selected furni

As it does if you say
:coins x 4
X turns into the Username of selected user

I can not find where this is done at all. I have back tracked the whole ChatCommandHandler.cs methods

Solution 2 (If solution 1 is not possible):
Make it so all users can see the ID in the furni description.
I have found where that is posted in the habbo.swf
Code:
Code:
<text x="0" y="260" width="170" height="40" params="16" style="0" name="furni_details_text" caption="Furni%20details">
                  <variables>
                    <var key="text_color" value="0xffffff" type="hex"/>
                    <var key="mouse_wheel_enabled" value="false" type="Boolean"/>
                    <var key="word_wrap" value="true" type="Boolean"/>
                  </variables>
                </text>
However I can not find where it controls what rank/permission can see it.
It is not in external_variables/external_flash_texts/emulator -> Searched for "furni_details_text" and "Furni details" and "Furni%20details"
 

Sledmore

Chaturbate Livestreamer
Staff member
FindRetros Moderator
Jul 24, 2010
5,198
3,914
As I said, it used to be in the variables. It's not something I've needed to edit for years, it is now in the SWF.

Class "ChatInputWidgetHandler.class.asasm", method is "processWidgetMessage".
PHP:
if ((((k.charAt(0) == ":")) && ((k == "x")))){
    k = this._container.roomEngine._-1wi();
    if (k > -1){
        k = this._container.roomSession.userDataManager.getUserDataByIndex(k);
        if (k != null){
            k = k.name;
            k = k.text.replace(" x", (" " + k.name));
        };
    };
};

It'd be easy to add another statement for if the user is looking for "y", but not sure how you'd find the item, unless you can find the method in the SWF.
 

Users who are viewing this thread

Top