Enable Rank

Newbie Spellweaver
Joined
Feb 14, 2014
Messages
13
Reaction score
0
Hi Ragezone's Community !
I've been share this Enable :
Conditioons - Enable Rank - RaGEZONE Forums

shield retros image.
But my player's rank 1 have access to this enable and i want my staff only have access start rank 4. Does anyone have the code to Phoenix 3.11?
No GTE please, Only Phoenix 3.11. :love:
I tried to look, to touch the code, but i have errors grrr :(:
Can you help me solve this Problem ?
It's my code :

Code:
case 11:
Code:
                            if (class16_0.method_2().method_3("cmd_enable"))
                            {
                                int int_ = int.Parse(array[1]);
                                class16_0.method_2().method_24().method_2(int_, true);
                                Phoenix.smethod_15().method_2().method_31(class16_0, array[0].ToLower(), string_0);
                                result = true;
                                return result;
                            }
                            result = false;
[CENTER]                            return result;[/CENTER]


Thank's you very much in advance. xxx
PS : Sorry for my bad English, i'm French and i'm blonde (it doesn't help for that) ahah :laugh:
​
 
Last edited:
Hi I am Anubhav,
And I'll help you here replace (id1) and (id2) with the id of the enables you want to restrict for eg if you want to replaced I'd 112 then replace (id) with 112
Code:
                            if (class16_0.method_2().method_3("cmd_enable"))
                            {
                                int int_ = int.Parse(array[1]);
     
If(int_ == (id1) || (id2))
{
If(Session.GetHabbo().Rank < 4)
{
Session.SendNotif("Only staff can use this enable Id");
return true;


}
}
                           class16_0.method_2().method_24().method_2(int_, true);
                                Phoenix.smethod_15().method_2().method_31(class16_0, array[0].ToLower(), string_0);
                                result = true;
                                return result;
                            }
                            result = false;
[CENTER]                            return result;[/CENTER]


Then compile and enjoy of I helped please rep+ and like.
Feel free to pm me or email me for help.​
 
Upvote 0
I'm Sorry, Wrong Code .. Have Errors :(
Doesn't match



Hi I am Anubhav,
And I'll help you here replace (id1) and (id2) with the id of the enables you want to restrict for eg if you want to replaced I'd 112 then replace (id) with 112
Code:
                            if (class16_0.method_2().method_3("cmd_enable"))
                            {
                                int int_ = int.Parse(array[1]);
     
If(int_ == (id1) || (id2))
{
If(Session.GetHabbo().Rank < 4)
{
Session.SendNotif("Only staff can use this enable Id");
return true;


}
}
                           class16_0.method_2().method_24().method_2(int_, true);
                                Phoenix.smethod_15().method_2().method_31(class16_0, array[0].ToLower(), string_0);
                                result = true;
                                return result;
                            }
                            result = false;
[CENTER]                            return result;[/CENTER]


Then compile and enjoy of I helped please rep+ and like.
Feel free to pm me or email me for help.​



I'm Sorry .. Doesn't Match .. Error's in Compilation :(



One : Error is replace two ;​


When i replace two ;
I have more and more error​


I Think the code is For GTE, no Phoenix Base. GTE not the same files :(​
 
Upvote 0
I'm Sorry, Wrong Code .. Have Errors :(
Doesn't match






I'm Sorry .. Doesn't Match .. Error's in Compilation :(



One : Error is replace two ;​


When i replace two ;
I have more and more error​


I Think the code is For GTE, no Phoenix Base. GTE not the same files :(​
I was on tap talk so it fucked it up sorry remember that C# is case sensitive make capital "I" if
 
Upvote 0
As RyanVS said, the code he posted should work if you're removing ; and correcting If to if.

Code:
if(int_ == 102 || 178 && Session.GetHabbo().Rank < 4)
{
     Session.SendNotif("Whoops, you're not allowed to use that EffectID!");
     return true;
}
 
Upvote 0
As RyanVS said, the code he posted should work if you're removing ; and correcting If to if.

Code:
if(int_ == 102 || 178 && Session.GetHabbo().Rank < 4)
{
     Session.SendNotif("Whoops, you're not allowed to use that EffectID!");
     return true;
}

Hi ! Session doesn't exist in the actual context.
But .. The code is good, just "session" wrong
 
Upvote 0
Hi ! Session doesn't exist in the actual context.
But .. The code is good, just "session" wrong

So you need to match up the code with your obscured code.


Otherwise if you're lazy, replacing the if(int_ == 102 with
Code:
if (int_ == 102 || 178 && class16_0.method_2().method_3("cmd_alert"))
and get rid of the SendNotif.
 
Upvote 0
@Conditioons The way you found the enable command (( From a dictionary in the RolesManager.cs as far as i remember haven't used phx in a long time)) find another command which requires a administrative rank for eg the give coins copy the exact text in "" and replace it with "cmd_alert" on the code @Shorty posted.



If your still having errors then copy and paste your ChatCommandHandler.cs at Pastebin.com

Remember on that page you will see (Something).Add("cmd_cmdname", a number); copy the "cmd_cmdname"
And if you can't find this class back trace it (( Crlt+F to find ))
 
Upvote 0
@Conditioons The way you found the enable command (( From a dictionary in the RolesManager.cs as far as i remember haven't used phx in a long time)) find another command which requires a administrative rank for eg the give coins copy the exact text in "" and replace it with "cmd_alert" on the code @Shorty posted.



If your still having errors then copy and paste your ChatCommandHandler.cs at Pastebin.com

Remember on that page you will see (Something).Add("cmd_cmdname", a number); copy the "cmd_cmdname"
And if you can't find this class back trace it (( Crlt+F to find ))

Hi ! I found the soluce. I modify my code. and i have only 1 error *yeah*
The problem session.gethabbo (doesn't exist) for apply .Rank <4 )



What the solution ? :(
 
Upvote 0
Hi ! I found the soluce. I modify my code. and i have only 1 error *yeah*
The problem session.gethabbo (doesn't exist) for apply .Rank <4 )



What the solution ? :(
Post your chat command handler on pastebin the classes on your edition are different
 
Upvote 0
The file in which you are pasting the code on is usually known as the chat command handler is named differently for you. Just crlt+A and paste it on paste bin

Ok, i think is Class58.cs




The file in which you are pasting the code on is usually known as the chat command handler is named differently for you. Just crlt+A and paste it on paste bin
Is the Good file ?
 
Upvote 0
Here you go
Replace

Code:
case 11:
                             if (class16_0.method_2().method_3("cmd_enable"))
                            {
                                int int_ = int.Parse(array[1]);
     
                            if(int_ == (102))
                                 if(int_== (178))
                                {
                            if(Session.GetHabbo().Rank < 4)
                                {
                               class16_0.method_8("Cet énable n'est pas fait pour toi, désolé !");
                                return true;


                                }
                                }
                           class16_0.method_2().method_24().method_2(int_, true);
                                Phoenix.smethod_15().method_2().method_31(class16_0, array[0].ToLower(), string_0);
                                result = true;
                                return result;
                            }
                            result = false;
                            return result;

With that.
 
Upvote 0
hi ! Match. But i'm créator enable 178 match. But 102 have the alert ("Cet énable n'est pas fait pour toi, désolé !"); :((



No, it's good. I have change order if(int_ == (178)) if(int_== (102))
It's good. My staff have :enable 102. And :enable 178 is for my bots. Thanks U verrrrry muuuuch !
 
Upvote 0
Back