XGM Forum
Сайт - Статьи - Проекты - Ресурсы - Блоги

Форуме в режиме ТОЛЬКО ЧТЕНИЕ. Вы можете задать вопросы в Q/A на сайте, либо создать свой проект или ресурс.
Вернуться   XGM Forum > Warcraft> Академия: форум для вопросов> Jass
Ник
Пароль
Войти через VK в один клик
Сайт использует только имя.

Ответ
 
Rinox2007
Kicked by Clamp
offline
Опыт: 16
Активность:
Dota + bot
Наткнулся в доте на такой код:

Код:
loop
        exitwhen i>5
        set p=Sentinels[i]
        set id=I2S(GetPlayerId(p))
        call StoreInteger(MN,id,"1",(I[GetPlayerId((p))]))
        call StoreInteger(MN,id,"2",(O[GetPlayerId((p))]))
        call StoreInteger(MN,id,"3",(A[GetPlayerId((p))]))
        call StoreInteger(MN,id,"4",(B[GetPlayerId((p))]))
        call StoreInteger(MN,id,"5",(D[GetPlayerId((p))]))
        call StoreInteger(MN,id,"6",(GetPlayerState((p),PLAYER_STATE_RESOURCE_GOLD)))
        call StoreInteger(MN,id,"7",(LoadInteger(HY,(400+GetPlayerId((p))),(79))))
        call StoreInteger(MN,id,"8_0",(GetItemTypeId(UnitItemInSlot(udg_Hero[GetPlayerId((p))],(0)))))
        call StoreInteger(MN,id,"8_1",(GetItemTypeId(UnitItemInSlot(udg_Hero[GetPlayerId((p))],(1)))))
        call StoreInteger(MN,id,"8_2",(GetItemTypeId(UnitItemInSlot(udg_Hero[GetPlayerId((p))],(2)))))
        call StoreInteger(MN,id,"8_3",(GetItemTypeId(UnitItemInSlot(udg_Hero[GetPlayerId((p))],(3)))))
        call StoreInteger(MN,id,"8_4",(GetItemTypeId(UnitItemInSlot(udg_Hero[GetPlayerId((p))],(4)))))
        call StoreInteger(MN,id,"8_5",(GetItemTypeId(UnitItemInSlot(udg_Hero[GetPlayerId((p))],(5)))))
        call StoreInteger(MN,id,"9",(GetUnitTypeId(udg_Hero[GetPlayerId((p))])))
        call StoreInteger(MN,id,"id",i)
        set p=Scourges[i]
        set id=I2S(GetPlayerId(p))
        call StoreInteger(MN,id,"1",(I[GetPlayerId((p))]))
        call StoreInteger(MN,id,"2",(O[GetPlayerId((p))]))
        call StoreInteger(MN,id,"3",(A[GetPlayerId((p))]))
        call StoreInteger(MN,id,"4",(B[GetPlayerId((p))]))
        call StoreInteger(MN,id,"5",(D[GetPlayerId((p))]))
        call StoreInteger(MN,id,"6",(GetPlayerState((p),PLAYER_STATE_RESOURCE_GOLD)))
        call StoreInteger(MN,id,"7",(LoadInteger(HY,(400+GetPlayerId((p))),(79))))
        call StoreInteger(MN,id,"8_0",(GetItemTypeId(UnitItemInSlot(udg_Hero[GetPlayerId((p))],(0)))))
        call StoreInteger(MN,id,"8_1",(GetItemTypeId(UnitItemInSlot(udg_Hero[GetPlayerId((p))],(1)))))
        call StoreInteger(MN,id,"8_2",(GetItemTypeId(UnitItemInSlot(udg_Hero[GetPlayerId((p))],(2)))))
        call StoreInteger(MN,id,"8_3",(GetItemTypeId(UnitItemInSlot(udg_Hero[GetPlayerId((p))],(3)))))
        call StoreInteger(MN,id,"8_4",(GetItemTypeId(UnitItemInSlot(udg_Hero[GetPlayerId((p))],(4)))))
        call StoreInteger(MN,id,"8_5",(GetItemTypeId(UnitItemInSlot(udg_Hero[GetPlayerId((p))],(5)))))
        call StoreInteger(MN,id,"9",(GetUnitTypeId(udg_Hero[GetPlayerId((p))])))
        call StoreInteger(MN,id,"id",i+5)
        if GetLocalPlayer()==XO then
            call SyncStoredInteger(MN,I2S(GetPlayerId(Sentinels[i])),"1")
            call SyncStoredInteger(MN,I2S(GetPlayerId(Sentinels[i])),"2")
            call SyncStoredInteger(MN,I2S(GetPlayerId(Sentinels[i])),"3")
            call SyncStoredInteger(MN,I2S(GetPlayerId(Sentinels[i])),"4")
            call SyncStoredInteger(MN,I2S(GetPlayerId(Sentinels[i])),"5")
            call SyncStoredInteger(MN,I2S(GetPlayerId(Sentinels[i])),"6")
            call SyncStoredInteger(MN,I2S(GetPlayerId(Sentinels[i])),"7")
            call SyncStoredInteger(MN,I2S(GetPlayerId(Sentinels[i])),"8_0")
            call SyncStoredInteger(MN,I2S(GetPlayerId(Sentinels[i])),"8_1")
            call SyncStoredInteger(MN,I2S(GetPlayerId(Sentinels[i])),"8_2")
            call SyncStoredInteger(MN,I2S(GetPlayerId(Sentinels[i])),"8_3")
            call SyncStoredInteger(MN,I2S(GetPlayerId(Sentinels[i])),"8_4")
            call SyncStoredInteger(MN,I2S(GetPlayerId(Sentinels[i])),"8_5")
            call SyncStoredInteger(MN,I2S(GetPlayerId(Sentinels[i])),"9")
            call SyncStoredInteger(MN,I2S(GetPlayerId(Sentinels[i])),"id")
            call SyncStoredInteger(MN,I2S(GetPlayerId(Scourges[i])),"1")
            call SyncStoredInteger(MN,I2S(GetPlayerId(Scourges[i])),"2")
            call SyncStoredInteger(MN,I2S(GetPlayerId(Scourges[i])),"3")
            call SyncStoredInteger(MN,I2S(GetPlayerId(Scourges[i])),"4")
            call SyncStoredInteger(MN,I2S(GetPlayerId(Scourges[i])),"5")
            call SyncStoredInteger(MN,I2S(GetPlayerId(Scourges[i])),"6")
            call SyncStoredInteger(MN,I2S(GetPlayerId(Scourges[i])),"7")
            call SyncStoredInteger(MN,I2S(GetPlayerId(Scourges[i])),"8_0")
            call SyncStoredInteger(MN,I2S(GetPlayerId(Scourges[i])),"8_1")
            call SyncStoredInteger(MN,I2S(GetPlayerId(Scourges[i])),"8_2")
            call SyncStoredInteger(MN,I2S(GetPlayerId(Scourges[i])),"8_3")
            call SyncStoredInteger(MN,I2S(GetPlayerId(Scourges[i])),"8_4")
            call SyncStoredInteger(MN,I2S(GetPlayerId(Scourges[i])),"8_5")
            call SyncStoredInteger(MN,I2S(GetPlayerId(Scourges[i])),"9")
            call SyncStoredInteger(MN,I2S(GetPlayerId(Scourges[i])),"id")
        endif
        set i=i+1
    endloop
    if Z97==false then
        call StoreInteger(MN,"Global","Winner",ZD7)
        call StoreInteger(MN,"Global","m",Minutes)
        call StoreInteger(MN,"Global","s",Seconds)
        if GetLocalPlayer()==XO then
            call SyncStoredInteger(MN,"Global","Winner")
            call SyncStoredInteger(MN,"Global","m")
            call SyncStoredInteger(MN,"Global","s")
        endif
    endif



Как я понял это отсылка боту статистики о килах смертей и тд.


Вопрос: можно ли как нибудь без изменения кода в карте, на локальном компьютере вызывать
Код:
call SyncStoredInteger(MN,"Global","Winner")
            call SyncStoredInteger(MN,"Global","m")
            call SyncStoredInteger(MN,"Global","s")
Старый 23.06.2013, 12:03
DioD

offline
Опыт: 45,134
Активность:
можно, достаточно инжектнуть арбитарный код в процесс варкрафта и делать что хочется, ассемблер и ряд других утилит в руки и гого делать.
Старый 23.06.2013, 14:42
iZetox

offline
Опыт: 7,067
Активность:
Тогда для легкости, достаточно вызвать только функцию preloader, указать строку, и вызвать файл.
Можно прямо в текстовом файле создать переменную типа gamecache и произвести нужные действия.. конец игры для бота будет раньше, чем будет десинк.
Старый 27.07.2013, 20:07
iZetox

offline
Опыт: 7,067
Активность:


iZetox добавил:
» Ссыль
http://ru.iccup.com/dota/details/3021010.html
Старый 13.08.2013, 12:51
16GB
GhostOne User
offline
Опыт: 60,317
Активность:
го го в топ айкапа. хахах
Старый 13.08.2013, 13:15
Ответ

Опции темы Поиск в этой теме
Поиск в этой теме:

Расширенный поиск

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

BB-коды Вкл.
[IMG] код Вкл.
HTML код Выкл.
Быстрый переход



Часовой пояс GMT +3, время: 05:26.