Приветствуем вас на форуме проекта WoW Circle. Если вы читаете это, значит не зарегистрировались у нас. Для того, чтобы получить доступ к расширенным возможностям нашего форума нажмите сюда и пройди регистрацию, которая не займет у вас много времени. После регистрации будут доступны новые, более расширенные, возможности.
Стрелочки - Страница 3

Упомянутые в теме пользователи:

Страница 3 из 3 ПерваяПервая 123
Показано с 25 по 29 из 29

Тема: Стрелочки

  1. #25
    Инопланетянин
    Регистрация
    20.03.2012
    Сообщений
    4,201
    Поблагодарил(а)
    362
    Получено благодарностей: 1,439 (сообщений: 839).
    Репутация: 2399
    Цитата Сообщение от Worldwidex Посмотреть сообщение
    Есть альтернатива?
    EndScense хукнуть и на DirectX сделать ее, координаты получать с памяти клиента.

    с градиентом

    fixed

    PHP код:
    local f CreateFrame("frame""arr"UIParent)

    f:SetSize(150150)
    f:SetPoint("CENTER"00)

    f:SetBackdrop({
        
    bgFile = [[Interface\Tooltips\UI-Tooltip-Background]], 
        
    edgeFile = [[Interface\Tooltips\UI-Tooltip-Border]], 
        
    edgeSize 10
        
    insets={left 3right 3top 3bottom 3}
    })

    f.arrow f:CreateTexture(nil"OVERLAY")
    f.arrow:SetPoint("CENTER"00)
    f.down false

    local 
    function GetDistance(x1x2y1y2)
        return ((
    x1 x2) ^ 2) + ((y1 y2) ^ 2)
    end

    local 
    function GetDir(uxuypxpy)

        if 
    not WorldMapFrame:IsShown() then
            SetMapToCurrentZone
    ()
        
    end
     
        
    if px == and py == 0 then
            
    return 0, print("3.14зда рулю, на этой карте нельзя сделать стрелочку")
        
    end
        
        local w
    WorldMapButton:GetSize()
        
        return -(
    math.rad(((GetPlayerFacing() - math.atan2((px ux) * w,(py uy) * h)) * 180 math.pi 180) % 360 180))
    end

    local 
    function CGrad(perc, ...)
        
    local num select("#", ...)
        
    local rgb
        
        
    if (perc == 1then
            r
    gselect(num 2, ...), select(num 1, ...), select(num, ...)
        else
            
    num num 3
            
            local segment
    relperc math.modf(perc * (num 1))

            
    rgselect((segment 3) + 4, ...), select((segment 3) + 5, ...), select((segment 3) + 6, ...)
            
            if 
    not r or not g or not b then
                r
    gselect((segment 3) + 1, ...), select((segment 3) + 2, ...), select((segment 3) + 3, ...)
            else
                
    rgselect((segment 3) + 1, ...) + (select((segment 3) + 1, ...)) * relperc,
                
    select((segment 3) + 2, ...) + (select((segment 3) + 2, ...)) * relperc,
                
    select((segment 3) + 3, ...) + (select((segment 3) + 3, ...)) * relperc
            end
        end
        
        
    return rgb
    end

    local count 
    0
    local timer 
    9999
    f
    :SetScript("OnUpdate", function(selfelapsed)

        if (
    timer 0.03then
            timer 
    timer elapsed
            
    return
        
    end
        
        local px
    py GetPlayerMapPosition("player")
        
    pxpy px 100py 100
        
        local cell
        
        local unit 
    string.format("party%d"1)
        if (
    UnitExists(unit)) then
            
            local ux
    uy GetPlayerMapPosition(unit)
                
            
    uxuy ux 100uy 100
                
            local udist 
    GetDistance(pxuxpyuy)
                
            if (
    udist 0.02then
                    
                
    if (self.downthen
                        
                    self
    .arrow:SetHeight(70)
                    
    self.arrow:SetWidth(53)
                    
    self.arrow:SetTexture("Interface\\AddOns\\TomTom\\Images\\Arrow-UP")
                    
    self.arrow:SetVertexColor(010)
                    
    self.down false
                end
                    
                count 
    count 1
                
    if count >= 55 then count 0 end

                cell 
    count
            
                local col 
    cell 9
                local row 
    floor(cell 9)

                
    self.arrow:SetTexCoord((col 53) / 512, ((col 1) * 53) / 512, (row 70) / 512, ((row 1) * 70) / 512)
            else
                
                if (
    not self.downthen
                        
                    self
    .arrow:SetHeight(56)
                    
    self.arrow:SetWidth(42)
                    
    self.arrow:SetTexture("Interface\\AddOns\\TomTom\\Images\\Arrow")
                    
    self.down true
                end
                    
                local angle 
    GetDir(uxuypxpy)
        
                
    self.arrow:SetVertexColor(CGrad(math.abs((math.pi math.abs(angle)) / math.pi), 100110010))
                
                
    cell floor(angle / (math.pi 2) * 108 0.5) % 108
                local col 
    cell 9
                local row 
    floor(cell 9)

                
    self.arrow:SetTexCoord((col 56) / 512, ((col 1) * 56) / 512, (row 42) / 512, ((row 1) * 42) / 512)
            
    end
        end
        
        timer 
    0
    end

    Последний раз редактировалось DreamlØlz; 11.06.2020 в 18:29.

  2. 2 пользователей сказали cпасибо DreamlØlz за это полезное сообщение:

    romanspector (28.06.2020),Екзорцист (11.06.2020)

  3. #26
    Эксперт
    Регистрация
    26.12.2019
    Сообщений
    581
    Поблагодарил(а)
    26
    Получено благодарностей: 59 (сообщений: 44).
    Репутация: 59
    Цитата Сообщение от DreamlØlz Посмотреть сообщение
    EndScense хукнуть и на DirectX сделать ее, координаты получать с памяти клиента.

    с градиентом
    PHP код:
    local f CreateFrame("frame""arr"UIParent)

    f:SetSize(150150)
    f:SetPoint("CENTER", -200, -120)

    f:SetBackdrop({
        --
    bgFile = [[Interface\Tooltips\UI-Tooltip-Background]], 
        --
    edgeFile = [[Interface\Tooltips\UI-Tooltip-Border]], 
        --
    edgeSize 10
        --
    insets={left 3right 3top 3bottom 3}
    })

    f.arrow f:CreateTexture(nil"OVERLAY")
    f.arrow:SetPoint("CENTER"00)
    f.down false

    local 
    function GetDistance(x1x2y1y2)
        return ((
    x1 x2) ^ 2) + ((y1 y2) ^ 2)
    end

    local 
    function GetDir(uxuypxpy)

        if 
    not WorldMapFrame:IsShown() then
            SetMapToCurrentZone
    ()
        
    end
     
        
    if px == and py == 0 then
            
    return 0, print("3.14зда рулю, на этой карте нельзя сделать стрелочку")
        
    end
        
        local w
    WorldMapButton:GetSize()
        
        return -(
    math.rad(((GetPlayerFacing() - math.atan2((px ux) * w,(py uy) * h)) * 180 math.pi 180) % 360 180))
    end

    local 
    function CGrad(perc, ...)
        
    local num select("#", ...)
        
    local rg111

        num 
    num 3

        local segment
    relperc math.modf(perc * (num 1))
        
    local r1g1b1r2g2b2
        r1
    g1b1 select((segment 3) + 1, ...), select((segment 3) + 2, ...), select((segment 3) + 3, ...)
        
    r2g2b2 select((segment 3) + 4, ...), select((segment 3) + 5, ...), select((segment 3) + 6, ...)

        if 
    not r2 or not g2 or not b2 then
            
    return r1g1b1
        
    else
            return 
    r1 + (r2 r1) * relpercg1 + (g2 g1) * relpercb1 + (b2 b1) * relperc
        end
        
        
    if (perc == 1)
            
    rgselect(num 2, ...), select(num 1, ...), select(num, ...)
        else
            
    num num 3
            
            local segment
    relperc math.modf(perc * (num 1))
            
            
        
    end
        
        
    return rgb
    end

    local count 
    0

    f
    :SetScript("OnUpdate", function(selfelapsed)
        
    local pxpy GetPlayerMapPosition("player")
        
    pxpy px 100py 100
        
        local cell
        
        local unit 
    string.format("party%d"1)
        if (
    UnitExists(unit)) then
            
            local ux
    uy GetPlayerMapPosition(unit)
                
            
    uxuy ux 100uy 100
                
            local udist 
    GetDistance(pxuxpyuy)
                
            if (
    udist 0.02then
                    
                
    if (self.downthen
                        
                    self
    .arrow:SetHeight(70)
                    
    self.arrow:SetWidth(53)
                    
    self.arrow:SetTexture("Interface\\AddOns\\TomTom\\Images\\Arrow-UP")
                    
    self.arrow:SetVertexColor(010)
                    
    self.down false
                end
                    
                count 
    count 1
                
    if count >= 55 then count 0 end

                cell 
    count
            
                local col 
    cell 9
                local row 
    floor(cell 9)

                
    self.arrow:SetTexCoord((col 53) / 512, ((col 1) * 53) / 512, (row 70) / 512, ((row 1) * 70) / 512)
            else
                
                if (
    not self.downthen
                        
                    self
    .arrow:SetHeight(56)
                    
    self.arrow:SetWidth(42)
                    
    self.arrow:SetTexture("Interface\\AddOns\\TomTom\\Images\\Arrow")
                    
    self.down true
                end
                    
                local angle 
    GetDir(uxuypxpy)
        
                
    self.arrow:SetVertexColor(CGrad(math.abs((math.pi math.abs(angle)) / math.pi), 100110010))
                
                
    cell floor(angle / (math.pi 2) * 108 0.5) % 108
                local col 
    cell 9
                local row 
    floor(cell 9)

                
    self.arrow:SetTexCoord((col 56) / 512, ((col 1) * 56) / 512, (row 42) / 512, ((row 1) * 42) / 512)
            
    end
        end
    end

    NotWorkThis^
    от слова совсем.
    Игрок может сменить сервер, но не намерение.
    "Починим сервер вместе!"

  4. #27
    Инопланетянин
    Регистрация
    20.03.2012
    Сообщений
    4,201
    Поблагодарил(а)
    362
    Получено благодарностей: 1,439 (сообщений: 839).
    Репутация: 2399
    Цитата Сообщение от Worldwidex Посмотреть сообщение
    NotWorkThis^
    от слова совсем.
    криво скопировалась поправил, добавил 30 обновлений в сек , вместо каждого кадра

  5. #28
    Эксперт
    Регистрация
    26.12.2019
    Сообщений
    581
    Поблагодарил(а)
    26
    Получено благодарностей: 59 (сообщений: 44).
    Репутация: 59
    Цитата Сообщение от DreamlØlz Посмотреть сообщение
    криво скопировалась поправил
    А щас то че не так:

    Скрытый текст


    PHP код:
    local f CreateFrame("frame""arr"UIParent)

    f:SetSize(150150)
    f:SetPoint("CENTER", -200, -120)

    f:SetBackdrop({
        --
    bgFile = [[Interface\Tooltips\UI-Tooltip-Background]], 
        --
    edgeFile = [[Interface\Tooltips\UI-Tooltip-Border]], 
        --
    edgeSize 10
        --
    insets={left 3right 3top 3bottom 3}
    })

    f.arrow f:CreateTexture(nil"OVERLAY")
    f.arrow:SetPoint("CENTER"00)
    f.down false

    local 
    function GetDistance(x1x2y1y2)
        return ((
    x1 x2) ^ 2) + ((y1 y2) ^ 2)
    end

    local 
    function GetDir(uxuypxpy)

        if 
    not WorldMapFrame:IsShown() then
            SetMapToCurrentZone
    ()
        
    end
     
        
    if px == and py == 0 then
            
    return 0, print("3.14зда рулю, на этой карте нельзя сделать стрелочку")
        
    end
        
        local w
    WorldMapButton:GetSize()
        
        return -(
    math.rad(((GetPlayerFacing() - math.atan2((px ux) * w,(py uy) * h)) * 180 math.pi 180) % 360 180))
    end

    local 
    function CGrad(perc, ...)
        
    local num select("#", ...)
        
    local rgb
        
        
    if (perc == 1then
            r
    gselect(num 2, ...), select(num 1, ...), select(num, ...)
        else
            
    num num 3
            
            local segment
    relperc math.modf(perc * (num 1))

            
    rgselect((segment 3) + 4, ...), select((segment 3) + 5, ...), select((segment 3) + 6, ...)
            
            if 
    not r or not g or not b then
                r
    gselect((segment 3) + 1, ...), select((segment 3) + 2, ...), select((segment 3) + 3, ...)
            else
                
    rgselect((segment 3) + 1, ...) + (select((segment 3) + 1, ...)) * relperc,
                
    select((segment 3) + 2, ...) + (select((segment 3) + 2, ...)) * relperc,
                
    select((segment 3) + 3, ...) + (select((segment 3) + 3, ...)) * relperc
            end
        end
        
        
    return rgb
    end

    local count 
    0
    local timer 
    9999
    f
    :SetScript("OnUpdate", function(selfelapsed)

        if (
    timer 0.03then
            timer 
    timer elapsed
            
    return
        
    end
        
        local px
    py GetPlayerMapPosition("player")
        
    pxpy px 100py 100
        
        local cell
        
        local unit 
    string.format("party%d"1)
        if (
    UnitExists(unit)) then
            
            local ux
    uy GetPlayerMapPosition(unit)
                
            
    uxuy ux 100uy 100
                
            local udist 
    GetDistance(pxuxpyuy)
                
            if (
    udist 0.02then
                    
                
    if (self.downthen
                        
                    self
    .arrow:SetHeight(70)
                    
    self.arrow:SetWidth(53)
                    
    self.arrow:SetTexture("Interface\\AddOns\\GdeNap\\Images\\Arrow-UP")
                    
    self.arrow:SetVertexColor(010)
                    
    self.down false
                end
                    
                count 
    count 1
                
    if count >= 55 then count 0 end

                cell 
    count
            
                local col 
    cell 9
                local row 
    floor(cell 9)

                
    self.arrow:SetTexCoord((col 53) / 512, ((col 1) * 53) / 512, (row 70) / 512, ((row 1) * 70) / 512)
            else
                
                if (
    not self.downthen
                        
                    self
    .arrow:SetHeight(56)
                    
    self.arrow:SetWidth(42)
                    
    self.arrow:SetTexture("Interface\\AddOns\\GdeNap\\Images\\Arrow")
                    
    self.down true
                end
                    
                local angle 
    GetDir(uxuypxpy)
        
                
    self.arrow:SetVertexColor(CGrad(math.abs((math.pi math.abs(angle)) / math.pi), 100110010))
                
                
    cell floor(angle / (math.pi 2) * 108 0.5) % 108
                local col 
    cell 9
                local row 
    floor(cell 9)

                
    self.arrow:SetTexCoord((col 56) / 512, ((col 1) * 56) / 512, (row 42) / 512, ((row 1) * 42) / 512)
            
    end
        end
        
        timer 
    0
    end

    [свернуть]

    Цитата Сообщение от DreamlØlz Посмотреть сообщение
    криво скопировалась
    Да эт я походу криво скопировал.

    А ну, в мире робит, на арене НЕТ.
    Последний раз редактировалось Worldwidex; 12.06.2020 в 00:01.
    Игрок может сменить сервер, но не намерение.
    "Починим сервер вместе!"

  6. #29
    Эксперт
    Регистрация
    16.01.2012
    Сообщений
    501
    Поблагодарил(а)
    185
    Получено благодарностей: 53 (сообщений: 37).
    Репутация: 303
    я же писал тчо на арене не будет работать от слова совсем, тему создавал, getplayermaposition не работает на арене, а то что показывает на миникарте зашито в wow.exe
    @DreamlØlz лучше подскажи как в dreamplates поставить иконки тремора из тайди плейтсов.
    Последний раз редактировалось SomeTimeLike; 12.06.2020 в 09:08.
    I rely on that won't be boring
    twitch.tv/7zhan

Страница 3 из 3 ПерваяПервая 123

Ваши права

  • Вы не можете создавать новые темы
  • Вы не можете отвечать в темах
  • Вы не можете прикреплять вложения
  • Вы не можете редактировать свои сообщения
  •