Jump to content
Search In
  • More options...
Find results that contain...
Find results in...
  • Need help?

    Create a topic in the appropriate section
    Don't write everything in the chat!
  • Take a look at the marketplace

    There you can buy
    everything related to game servers
  • Don't want a ban?

    Please read our rules
    Don't disturb the order!
  • Sell or buy?

    Use services of the guarantor
    We will make your deal safe

Search the Community

Showing results for tags 'запись'.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Main category
    • S-Platoon
    • Private section
    • Marketplace
    • Chatter
  • DayZ Standalone
    • Instructions
    • Help
    • Other
    • English section
  • General section
    • ARMA 3
    • DayZ mod
    • ARMA 2
    • CS: Global offensive
    • ARK: Survival Evolved
    • Minecraft
    • Rust
  • Product support topics

Categories

  • DayZ
    • Ready servers
    • Scripts, mods, files etc.
    • Vehicles
    • Weapons, tools, items
    • Map add-ons
    • Models
    • Software
    • Other
  • Arma 3
    • Ready servers
    • Scripts, mods, files etc.
    • Vehicles
    • Models
    • Software
    • Other

Product Groups

  • Privileges on the forum
  • Advertising on the site

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


VK Social


Steam


ICQ


Skype


City


Web-site


Interests

Found 1 result

  1. Нам понадобится: 1. Сервер DayZ Standalone (см. тему вот эту) 2. Notepad++: бесплатно на оф. сайте 3. Немного времени и настойчивости (обычно бывает в комплекте и так) И так, начинаем: 1. Открываем блокнотом mpmissions\dayzOffline.chernarusplus\init.c P.S. Имя папки dayzOffline.chernarusplus у вас может отличаться, будьте внимательны 2. В начале файла добавляем: static int time_repeat_info_players = 10; //in seconds static string file_name_info_players = "$profile:PlayersLogFile.txt"; static void WriteFile(string file_name, string text) { private FileHandle fhandle; if ( !FileExist(file_name) ) { fhandle = OpenFile(file_name, FileMode.WRITE); } else { fhandle = OpenFile(file_name, FileMode.APPEND); } if ( fhandle == 0 ) { Print("[#Запись_в_файл]: Не удалось открыть файл для записи: " + file_name); Print("[#Запись_в_файл]: [Запись]: " + text); return; } FPrintln(fhandle, text); CloseFile(fhandle); } static void WritePlayersInfo() { array<Man> players = new array<Man>; Man player; Man player_test; GetGame().GetPlayers( players ); if (players.Count() > 0) { if ( FileExist(file_name_info_players) ) { DeleteFile(file_name_info_players); } for ( int i = 0; i < players.Count(); ++i ) { player_test = players.Get(i); if( player_test ) { PlayerIdentity p_identity = player_test.GetIdentity(); private string coord_pl = player_test.GetPosition().ToString(); private string Name_P = p_identity.GetName(); private string UID_P = p_identity.GetPlainId(); WriteFile(file_name_info_players, "User name: " + Name_P + " UID: " + UID_P + " Coords: " + coord_pl); } } } else { if ( FileExist(file_name_info_players) ) { DeleteFile(file_name_info_players); } } } Где 'PlayersLogFile.txt' меняем на нужное вам имя файла, а в 'time_repeat_info_players' настраиваем время повтора проверки списка игроков для перезаписи файла 3. Находим в файле блок 'void main()' и в его конце перед закрывающей '}', поумолчанию это строка weather.SetWindFunctionParams(0.1, 0.3, 50); добавляем ниже строку: GetGame().GetCallQueue(CALL_CATEGORY_GAMEPLAY).CallLater(WritePlayersInfo, (time_repeat_info_players * 1000), true); 4. Готово, если не допустили ошибок, при наличии хотя бы 1 игрока на сервере ваш файл с данными по игрокам будет присутствовать и заполняться информацией, а в случае их отсутствия удаляться.
×
×
  • Create New...

Important Information

By using this site, you automaticly agree to our Guidelines and Privacy Policy.
We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.

Поддержка