Raised This Month: $51 Target: $400
 12% 

JailBreak Team Manager Problem !


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
oTm4n3
Member
Join Date: Jul 2021
Old 08-25-2021 , 18:37   JailBreak Team Manager Problem !
Reply With Quote #1

Hello.
JailBreak Team Manager Problem !
I have a problem choosing the team CT (Guard Team), the server had 4 players, 3 were T (Prisoner) , I was CT But when somone join with me He will be Able to kill me (friendley-fire) and he will look like Prisoner (Prisoner Skin + cant damage Prisoner Team) , he should be unable to enter the Guard team because 1 is the maximum of 4 players, I hope I explained my problem in an understandable way.

Team Menu ----> Data/lang/Core.txt

PHP Code:
JBE_MENU_TEAM_TITLE = \yDLC-Break \r| \wPick your team^n\wBalance: \r%d Prisoners 1 Guard
JBE_MENU_TEAM_PRISONERS 
Prisoner
JBE_MENU_TEAM_GUARDS 
Guard \y[Required microphone] ---------> here is my problem
JBE_MENU_TEAM_RANDOM 
Random team \w[\r50/50\w]
JBE_MENU_TEAM_SPECTATOR Spectator

JBE_MENU_SKIN_TITLE 
= \yDLC-Break \r| \wChoose color
JBE_MENU_SKIN_ORANGE 
Orange
JBE_MENU_SKIN_GRAY 
Gray
JBE_MENU_SKIN_YELLOW 
Yellow
JBE_MENU_SKIN_BLUE 
Blue
JBE_MENU_SKIN_BLACK 
Black \r[Admin
ِTeam in Jailbreak Core:

PHP Code:
Show_ChooseTeamMenu(idiType)
{
    if(
jbe_menu_blocked(id)) return PLUGIN_HANDLED;
    
jbe_informer_offset_up(id);
    new 
szMenu[512], iKeysiLen formatex(szMenucharsmax(szMenu), "\y%L^n"id"JBE_MENU_TEAM_TITLE"g_iAllCvars[TEAM_BALANCE]);
    if(
g_iUserTeam[id] != 1)
    {
        
iLen += formatex(szMenu[iLen], charsmax(szMenu) - iLen"\y[1] \w%L \r[%d]^n"id"JBE_MENU_TEAM_PRISONERS"g_iPlayersNum[1]);
        
iKeys |= (1<<0);
    }
    else 
iLen += formatex(szMenu[iLen], charsmax(szMenu) - iLen"\y[1] \d%L \r[%d]^n"id"JBE_MENU_TEAM_PRISONERS"g_iPlayersNum[1]);
    if(
IsNotSetBit(g_iBitUserBlockedGuardid) && g_iUserTeam[id] != && ((abs(g_iPlayersNum[1] - 1) / g_iAllCvars[TEAM_BALANCE]) + 1) > g_iPlayersNum[2])
    {
        
iLen += formatex(szMenu[iLen], charsmax(szMenu) - iLen"\y[2] \w%L \r[%d]^n^n"id"JBE_MENU_TEAM_GUARDS"g_iPlayersNum[2]);
        
iLen += formatex(szMenu[iLen], charsmax(szMenu) - iLen"\y[5] \w%L^n"id"JBE_MENU_TEAM_RANDOM");
        
iKeys |= (1<<1|1<<4);
    }
    else
    {
        
iLen += formatex(szMenu[iLen], charsmax(szMenu) - iLen"\y[2] \d%L \r[%d]^n^n"id"JBE_MENU_TEAM_GUARDS"g_iPlayersNum[2]);
        
iLen += formatex(szMenu[iLen], charsmax(szMenu) - iLen"\y[5] \d%L^n"id"JBE_MENU_TEAM_RANDOM");
    }
    if(
g_iUserTeam[id] != 3)
    {
        
iLen += formatex(szMenu[iLen], charsmax(szMenu) - iLen"\y[6] \w%L^n^n^n^n^n"id"JBE_MENU_TEAM_SPECTATOR");
        
iKeys |= (1<<5);
    }
    else 
iLen += formatex(szMenu[iLen], charsmax(szMenu) - iLen"\y[6] \d%L^n^n^n^n^n"id"JBE_MENU_TEAM_SPECTATOR");
    if(
iType)
    {
        
formatex(szMenu[iLen], charsmax(szMenu) - iLen"^n\y[0] \w%L"id"JBE_MENU_EXIT");
        
iKeys |= (1<<9);
    }
    return 
show_menu(idiKeysszMenu, -1"Show_ChooseTeamMenu");
}

public 
Handle_ChooseTeamMenu(idiKey)
{
    switch(
iKey)
    {
        case 
0:
        {
            if(
g_iUserTeam[id] == 1) return Show_ChooseTeamMenu(id1);
            if(!
jbe_set_user_team(id1)) return PLUGIN_HANDLED
        }
        case 
1:
        {
            if(
g_iUserTeam[id] == 2) return Show_ChooseTeamMenu(id1);
            if(
IsNotSetBit(g_iBitUserBlockedGuardid) && ((abs(g_iPlayersNum[1] - 1) / g_iAllCvars[TEAM_BALANCE]) + 1) > g_iPlayersNum[2])
            {
                if(!
jbe_set_user_team(id2)) return PLUGIN_HANDLED
                jbe_informer_offset_down
(id);
            }
            else
            {
                if(
g_iUserTeam[id] == 1) return Show_ChooseTeamMenu(id1);
                else return 
Show_ChooseTeamMenu(id0);
            }
        }
        case 
4:
        {
            if(((
abs(g_iPlayersNum[1] - 1) / g_iAllCvars[TEAM_BALANCE]) + 1) > g_iPlayersNum[2])
            {
                switch(
random_num(12))
                {
                    case 
1: if(!jbe_set_user_team(id1)) return PLUGIN_HANDLED;
                    case 
2:
                    {
                        if(!
jbe_set_user_team(id2)) return PLUGIN_HANDLED;
                        
jbe_informer_offset_down(id);
                    }
                }
            }
            else
            {
                if(
g_iUserTeam[id] == || g_iUserTeam[id] == 2) return Show_ChooseTeamMenu(id1);
                else return 
Show_ChooseTeamMenu(id0);
            }
        }
        case 
5:
        {
            if(
g_iUserTeam[id] == 3) return Show_ChooseTeamMenu(id0);
            if(!
jbe_set_user_team(id3)) return PLUGIN_HANDLED;
        }
    }
    return 
PLUGIN_HANDLED;
}

Show_SkinMenu(id)
{
    
jbe_informer_offset_up(id);
    
jbe_menu_block(id);
    new 
szMenu[512], iKeys = (1<<0|1<<1|1<<2|1<<3), iLen formatex(szMenucharsmax(szMenu), "\y%L^n^n"id"JBE_MENU_SKIN_TITLE");
    
iLen += formatex(szMenu[iLen], charsmax(szMenu) - iLen"\y[1] \w%L^n"id"JBE_MENU_SKIN_ORANGE");
    
iLen += formatex(szMenu[iLen], charsmax(szMenu) - iLen"\y[2] \w%L^n"id"JBE_MENU_SKIN_GRAY");
    
iLen += formatex(szMenu[iLen], charsmax(szMenu) - iLen"\y[3] \w%L^n"id"JBE_MENU_SKIN_YELLOW");
    
iLen += formatex(szMenu[iLen], charsmax(szMenu) - iLen"\y[4] \w%L^n"id"JBE_MENU_SKIN_BLUE");
    if(
IsSetBit(g_iBitUserAdminid))
    {
        
formatex(szMenu[iLen], charsmax(szMenu) - iLen"\y[5] \w%L"id"JBE_MENU_SKIN_BLACK");
        
iKeys |= (1<<4);
    }
    else 
formatex(szMenu[iLen], charsmax(szMenu) - iLen"\y[5] \d%L"id"JBE_MENU_SKIN_BLACK");
    return 
show_menu(idiKeysszMenu, -1"Show_SkinMenu");
}

public 
Handle_SkinMenu(idiKey)
{
    
g_iUserSkin[id] = iKey;
    
engclient_cmd(id"joinclass""1");
    
jbe_menu_unblock(id);

Thank You For Read it

Last edited by oTm4n3; 08-25-2021 at 18:38.
oTm4n3 is offline
oTm4n3
Member
Join Date: Jul 2021
Old 08-26-2021 , 09:11   Re: JailBreak Team Manager Problem !
Reply With Quote #2

Any solution ?
oTm4n3 is offline
Natsheh
Veteran Member
Join Date: Sep 2012
Old 08-26-2021 , 17:10   Re: JailBreak Team Manager Problem !
Reply With Quote #3

Here you can use this jb mod instead with a better team management.
__________________
@Jailbreak Main Mod v2.7.0 100%
@User Tag Prefix 100% done !
@Mystery Box 100% done !
@VIP System 100% done !

Natsheh is offline
Send a message via MSN to Natsheh Send a message via Skype™ to Natsheh
oTm4n3
Member
Join Date: Jul 2021
Old 08-27-2021 , 08:50   Re: JailBreak Team Manager Problem !
Reply With Quote #4

can you just make a Team manager script , And i remove the older one
oTm4n3 is offline
oTm4n3
Member
Join Date: Jul 2021
Old 08-27-2021 , 09:40   Re: JailBreak Team Manager Problem !
Reply With Quote #5

can i just get solution for fix it please
oTm4n3 is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 02:52.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode