Skocz do zawartości

Witamy w Nieoficjalnym polskim support'cie AMX Mod X

Witamy w Nieoficjalnym polskim support'cie AMX Mod X, jak w większości społeczności internetowych musisz się zarejestrować aby móc odpowiadać lub zakładać nowe tematy, ale nie bój się to jest prosty proces w którym wymagamy minimalnych informacji.
  • Rozpoczynaj nowe tematy i odpowiedaj na inne
  • Zapisz się do tematów i for, aby otrzymywać automatyczne uaktualnienia
  • Dodawaj wydarzenia do kalendarza społecznościowego
  • Stwórz swój własny profil i zdobywaj nowych znajomych
  • Zdobywaj nowe doświadczenia

Dołączona grafika Dołączona grafika

Guest Message by DevFuse
 

Zdjęcie

Problem moderror launching the mod


  • Nie możesz napisać tematu
  • Zaloguj się, aby dodać odpowiedź
Brak odpowiedzi do tego tematu

#1 EDUCJA

    Nowy

  • Użytkownik

Reputacja: 0
Nowy

  • Postów:5
  • Imię:Joaquin
  • Lokalizacja:Germany
Offline

Napisano 11.03.2020 18:26

Hi, can you help me with this? When I choose a player that is licker from the menu, he randomly chooses it

else  if ((mode == MODE_NONE && (!get_pcvar_num(cvar_preventconsecutive) || g_lastmode != MODE_LICKER) && random_num(1, get_pcvar_num(cvar_lickerchance)) == get_pcvar_num(cvar_licker) && iPlayersnum >= get_pcvar_num(cvar_lickerminplayers)) 
    || mode == MODE_LICKER )
    {
        // Licker Mode
        g_lickerround = true
        g_lastmode = MODE_LICKER

        set_cvar_num("pbk_afk_time", 900);

        // Make sure there are alive players on both teams (BUGFIX)
        if(!fnGetAliveTs())
        {
            // Move random player to T team
            id = fnGetRandomAlive(random_num(1, iPlayersnum))
            remove_task(id+TASK_TEAM)
            fm_cs_set_user_team(id, FM_CS_TEAM_T)
            fm_user_team_update(id)
        }
        else if(!fnGetAliveCTs())
        {
            // Move random player to CT team
            id = fnGetRandomAlive(random_num(1, iPlayersnum))
            remove_task(id+TASK_TEAM)
            fm_cs_set_user_team(id, FM_CS_TEAM_CT)
            fm_user_team_update(id)
        }

        new i;

        for(i = 1; i <= g_maxplayers; ++i) 
        {
            if(!g_isalive[i]) 
            {
                continue;
            }
            
            set_task(1.0, "Effect1_Licker_Mode", i); 

            remove_task(TASK_ESCONDIDO)
            
            g_count_licker = 10
            set_task(3.0, "Effect2_Licker_Mode", TASK_ESCONDIDO, _, _, "a", g_count_licker)
        }
                
        set_task(30.0, "Start_Licker_Mode");

        // Mode fully started!
        g_modestarted = true
    }

This part of the code would be where I would send the mode

public Start_Licker_Mode(mode, id)
{
    set_lights("a")

    //new id;
    static forward_id, iPlayersnum
    iPlayersnum = fnGetAlive()

    // Choose player randomly?
    if (mode == MODE_NONE)
        id = fnGetRandomAlive(random_num(1, iPlayersnum))
            
    // Remember id for calling our forward later
    forward_id = id
        
    // Turn player into licker
    zombieme(id, 0, 3, 0, 0)
        
    // Remaining players should be humans (CTs)
    for (id = 1; id <= g_maxplayers; id++)
    {
        // Not alive
        if (g_isalive[id])
            continue;
            
        // First licker
        if (g_zombie[id])
            continue;

        // Switch to CT
        if (fm_cs_get_user_team(id) != FM_CS_TEAM_CT) // need to change team?
        {
            // Change team
            remove_task(id+TASK_TEAM)
            fm_cs_set_user_team(id, FM_CS_TEAM_CT)
            fm_user_team_update(id)
        }
    }
    
    // Show Licker HUD notice
    set_dhudmessage(255, 150, 20, HUD_EVENT_X, HUD_EVENT_Y, 1, 0.0, 5.0, 1.0, 1.0)
    show_dhudmessage(0, "%s es un Licker !!!", g_playername[forward_id])
        
    // Mode fully started!
    g_modestarted = true
        
    // Round start forward
    ExecuteForward(g_fwRoundStart, g_fwDummyResult, MODE_LICKER, forward_id);
}

 

 


  • +
  • -
  • 0




Użytkownicy przeglądający ten temat: 0

0 użytkowników, 0 gości, 0 anonimowych