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

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

Ответ
 
free0n
Бумбарявка
offline
Опыт: 3,836
Активность:
Вот наконец -то я добрался до Jass.
Вопрос к Димону: Функции перечисленные ниже за что отвечают? Точнее что они делают, дословно?

Код:
#########################################################
function fs_Initialize takes nothing returns nothing
   local integer i = 0
   local integer p = 0
   local integer j
   local trigger t
   local timer tm
   local real x
   local real y

   // ############### set up workspace ##############
   call setcfg("base_x", R2S(GetRectMinX(bj_mapInitialPlayableArea) + 100.00))
   call setcfg("base_y", R2S(GetRectMinY(bj_mapInitialPlayableArea) + 100.00))

   set bj_mapInitialPlayableArea = Rect(cfgr("base_x") + 2300, GetRectMinY(bj_mapInitialPlayableArea), GetRectMaxX(bj_mapInitialPlayableArea), GetRectMaxY(bj_mapInitialPlayableArea))


   // ############### set up path blocker line ##############
   set x = cfgr("base_x") + 2200
   set y = GetRectMinY(GetWorldBounds())

   loop
      exitwhen y > GetRectMaxY(GetWorldBounds())
      call CreateDestructable('BX00', x, y, 0, 1.28, 0)
      set y = y + 128
   endloop

   // ############### auto detect max players if necessary ##############
   if cfgi("max_players") <= 0 then
      loop
         exitwhen i >= 12
         if GetPlayerSlotState(Player(i)) == PLAYER_SLOT_STATE_PLAYING then
            call setcfg("max_players", I2S(i + 1))
         endif
         set i = i + 1
      endloop
   endif

   set tm = CreateTimer()
   call TimerStart(tm, 0.00, true, function fs_InitPlayer)
endfunction
Старый 28.08.2006, 22:09
Ответ

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

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

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

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



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