Jump to content
Sign in to follow this  
DeiLyred

При входе в портал не телепортирует

Recommended Posts

15 часов назад, Graf сказал:

@DeiLyred У вас была подобная тема..

 

Нет не было. В той теме указано что ОТКЛЮЧАЕТ С ИГРЫ во время входа. Я все сделал как в той теме во многие места входить стало. А в некоторых пишет к примеру в снв что ВЫ ВОШЛИ В СНВ но при этом персонаж стоит в портале. Но уже не ОТКЛЮЧАЕТ от игры.

Share this post


Link to post
Share on other sites

Там описано, как реализован портал и в чем может быть проблема. Я не имел в виду, что проблемы одинаковые) 

Share this post


Link to post
Share on other sites

Если нужно что-то подробнее, то нужен код. Без него не смогу помочь, так как не знаю, что вы делали.. 

Share this post


Link to post
Share on other sites

Привет, @DeiLyred!

 

Покажи код из entry.lua карты, на которую ведет портал.


Share this post


Link to post
Share on other sites
Спойлер

function check_can_enter_07xmas2( role, copy_mgr )
    local FightingBook_Num = 0
    FightingBook_Num = CheckBagItem( role, 3849 )

    if FightingBook_Num <= 0 then
        SystemNotice( role, "У вас должна быть Медаль отваги, чтобы участвовать в Снежных войнах" )
        return 0
    elseif FightingBook_Num > 1 then
        LG( "RYZ_PK", "Possess more than 1 Medal of Valor" )
        return 0
    end

    local Now_Time = tonumber( os.date( "%H" ))
    if Now_Time == 3 or Now_Time == 6 or Now_Time == 9 or Now_Time == 12 or Now_Time == 15 or Now_Time == 18 or Now_Time == 21 or Now_Time == 24  then
        if Lv(role) < 149 then
            SystemNotice(role, "Вы должны быть не ниже 30 уровня, чтобы участвовать в Снежных войнах " )
            return 0
        end

        if Lv(role) > 151 then
            SystemNotice(role, "Вы должны быть не выше 60 уровня, чтобы участвовать в Снежных войнах " )
            return 0
        end
    else
        if Lv(role) <= 149 then
            SystemNotice(role, "Вы должны быть не ниже 61 уровня, чтобы участвовать в Снежных войнах " )
            return 0
        end
    end
end

function begin_enter_07xmas2( role, copy_mgr )
    SystemNotice( role, "Вы вошли в [Снежные войны]" )

    if ( AddonSystem["Teleport"] == 1 ) then
        local n = math.random( 116, 126 )
        teleport( role, n )
    else
        MoveCity( role, "Snow War" )
    end
end

birth_conf.lua

Спойлер

-- Снежная война
AddBirthPoint("Snow War", "07xmas2",  144, 136)
AddBirthPoint("Snow War", "07xmas2",  144, 243)
AddBirthPoint("Snow War", "07xmas2",  251, 40)
AddBirthPoint("Snow War", "07xmas2",  266, 88)
AddBirthPoint("Snow War", "07xmas2",  27, 55)
AddBirthPoint("Snow War", "07xmas2",  200, 50)
AddBirthPoint("Snow War", "07xmas2",  220, 220)
AddBirthPoint("Snow War", "07xmas2",  165, 253)
AddBirthPoint("Snow War", "07xmas2",  33, 220)
AddBirthPoint("Snow War", "07xmas2",  66, 201)
AddBirthPoint("Snow War", "07xmas2",  34, 99

Смотри что бы в Entry.lua "MoveCity( role, "Snow War" )" название совпадало с названием в birth_conf.lua

Share this post


Link to post
Share on other sites

Зайди в папку GameServer, найди там папку LOG, залей её тоже сюда.

Обязательно сделай это после того как попытаешься войти в портал.

Share this post


Link to post
Share on other sites
В 15.08.2020 в 16:11, V3ct0r сказал:

Привет, @DeiLyred!

 

Покажи код из entry.lua карты, на которую ведет портал.

--------------------------------------------------------------------------
--                                                                        --
--                                                                        --
--                    entry.lua                                            --
--                    (Хаос Аргента)                                        --
--                                                                        --
--------------------------------------------------------------------------

function config_entry(entry) 
    SetMapEntryEntiID(entry,2492,1)
end 

function after_create_entry(entry) 
    local copy_mgr = GetMapEntryCopyObj(entry, 0)
    map_name, posx, posy, tmap_name = GetMapEntryPosInfo(entry)
    Notice("\194\229\235\232\234\232\233 \209\232\237\232\233 \206\234\229\224\237, \238\242\234\240\251\235\241\255 \239\238\240\242\224\235 ["..posx..","..posy.."] \226\229\228\243\249\232\233 \226 \209\229\240\229\225\240\255\237\237\251\233 \245\224\238\241!")
end

function after_destroy_entry_garner2(entry)
    map_name, posx, posy, tmap_name = GetMapEntryPosInfo(entry) 
    Notice("\207\238\240\242\224\235 \226 \209\229\240\229\225\240\255\237\237\251\233 \245\224\238\241 \231\224\234\240\251\235\241\255!") 
end

function after_player_login_garner2(entry, player_name)
    map_name, posx, posy, tmap_name = GetMapEntryPosInfo(entry)
    ChaNotice(player_name, "\194\229\235\232\234\232\233 \209\232\237\232\233 \206\234\229\224\237, \238\242\234\240\251\235\241\255 \239\238\240\242\224\235 ["..posx..","..posy.."] \226\229\228\243\249\232\233 \226 \209\229\240\229\225\240\255\237\237\251\233 \245\224\238\241!")
end

function check_can_enter_garner2( role, copy_mgr )
    local FightingBook_Num = 0
    FightingBook_Num = CheckBagItem( role,3849 )
    local Team_In = IsInTeam(role)
    if Team_In == 1 then
        SystemNotice ( role , "\205\229\235\252\231\255 \226\238\233\242\232 \226 \209\229\240\229\225\240\255\237\237\251\233 \245\224\238\241, \234\238\227\228\224 \226\251 \226 \238\242\240\255\228\229." )
        return 0
    end
    if FightingBook_Num <= 0 then
        SystemNotice ( role , "\211 \226\224\241 \228\238\235\230\237\224 \225\251\242\252 \204\229\228\224\235\252 \238\242\226\224\227\232, \247\242\238\225\251 \243\247\224\241\242\226\238\226\224\242\252 \226 \209\229\240\229\225\240\255\237\237\238\236 \245\224\238\241\229" )
        return 0
    elseif FightingBook_Num > 1 then
        LG("RYZ_PK","Possess more than 1 Medal of Valor")
        return 0
    end
    local role_RY = GetChaItem2 ( role , 2 , 3849 )
    local HonorPoint = GetItemAttr ( role_RY , ITEMATTR_VAL_STR)
    if HonorPoint < 20 then
        SystemNotice ( role , "\211 \226\224\241 \237\229\228\238\241\242\224\242\238\247\237\238 \238\247\234\238\226 \247\229\241\242\232, \247\242\238\225\251 \226\238\233\242\232 \226 \209\229\240\229\225\240\255\237\237\251\233 \245\224\238\241" )
        return 0
    end
    if HonorPoint >30000 then
        SystemNotice ( role , "\211 \226\224\241 \241\235\232\248\234\238\236 \236\237\238\227\238 \238\247\234\238\226 \247\229\241\242\232, \247\242\238\225\251 \226\238\233\242\232 \226 \209\229\240\229\225\240\255\237\237\251\233 \245\224\238\241" )
        return 0
    end
    local Credit_Garner2 = GetCredit(role)
     if Credit_Garner2 < 30 then 
        SystemNotice ( role , "\211 \226\224\241 \237\229\228\238\241\242\224\242\238\247\237\238 \238\247\234\238\226 \240\229\239\243\242\224\246\232\232, \247\242\238\225\251 \226\238\233\242\232 \226 \209\229\240\229\225\240\255\237\237\251\233 \245\224\238\241" )
        return 0
    end
    if Lv(role) < 20 then
    SystemNotice(role, "\194\251 \228\238\235\230\237\251 \225\251\242\252 \237\229 \237\232\230\229 20 \243\240\238\226\237\255, \247\242\238\225\251 \226\238\233\242\232 \226 \209\229\240\229\225\240\255\237\237\251\233 \245\224\238\241")
        return 0    
    end
    local Has_money = check_HasMoney(role)
    if Has_money == 1 then
        return 1
    else
        SystemNotice(role,"\205\229\228\238\241\242\224\242\238\247\237\238 \231\238\235\238\242\224, \237\229\226\238\231\236\238\230\237\238 \243\247\224\241\242\226\238\226\224\242\252 \226 \209\229\240\229\225\240\255\237\237\238\236 \245\224\238\241\229")
        return 0
    end            
end

function check_HasMoney(role)
    local lv= GetChaAttr(role, ATTR_LV)
    local Money_Need = lv*50
    local Money_Have = GetChaAttr ( role , ATTR_GD )
        if Money_Have >= Money_Need then
            return 1
        end
end


function begin_enter_garner2(role, copy_mgr) 
    local    Money_Have = GetChaAttr ( role , ATTR_GD )
    local lv= GetChaAttr(role, ATTR_LV)
    local Money_Need = lv*50
    local    Money_Now = Money_Have - Money_Need
    SetChaAttrI( role , ATTR_GD , Money_Now )
    DelCredit(role,30)
        SystemNotice(role,"\207\238\242\229\240\255\237\238: "..Money_Need.." \231\238\235\238\242\224  \232 30 \240\229\239\243\242\224\246\232\232") 
        MoveCity(role, "Chaos Argent")
Money_all = Money_all + Money_Need * 0.8
end

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

×
×
  • Create New...