Merhabalar arkadaşlar sevimli271 paylaştığı fake chat sistemi konudan kaldırılmış paylaşmak istedim geri.
Kod:
input_main.cpp aç ve arat extern void SendShout(const char * szText, BYTE bEmpire); değiştir #ifdef ENABLE_FAKE_CHAT extern void SendShout(const char * szText, BYTE bEmpire); #endif arat static int __deposit_limit() altına ekle #ifdef ENABLE_FAKE_CHAT #define FILE_MAX_LEN 256 #include <iostream> #include <fstream> std::vector<std::string> vec_chNames; std::string textArray[9] = { "AS", "as","aleykum selam", "ALEYKUM SELAM", "a.s", "A.S", "was", "A.s", "Aleykum Selam" }; #define TIMER_TICK_DIVIDING 6 //1 sec / x #define MIN_CHAT_COUNT_FOR_A_TICK 4 #define MAX_CHAT_COUNT_FOR_A_TICK 10 EVENTINFO(chat_shout_event_info) { const char * szText; int chatCount; int maxCount; }; EVENTFUNC(chat_shout_update_event) { chat_shout_event_info* info = dynamic_cast<chat_shout_event_info*>(event->info); if (info == NULL) { sys_err("mountsystem_update_event> <Factor> Null pointer"); return 0; } if (info->chatCount >= info->maxCount) { vec_chNames.clear(); return 0; } int startIndex = info->chatCount; const int shoutCount = number(MIN_CHAT_COUNT_FOR_A_TICK, MAX_CHAT_COUNT_FOR_A_TICK); info->chatCount += shoutCount; //int tekrar = 4; //for(int bear = 0; bear <= tekrar; bear++){ for (int i = 0; i < shoutCount; i++) { const int useIndex = startIndex + i; if (useIndex >= vec_chNames.size()) { vec_chNames.clear(); return 0; } char chatbuf_global[CHAT_MAX_LEN + 1]; std::string chName = vec_chNames[useIndex]; std::string chatText = textArray[number(0, _countof(textArray)-1)]; const BYTE charEmpire = number(1,3); const char* iconEmp[3] = {"[1] ","[2] ","[3] "}; const char* colorEmp[3] = {"|cFFFF0000","|cffffff00","|cFF0080FF"}; int len_global = snprintf(chatbuf_global, sizeof(chatbuf_global), "%s%s : %s|HVectors:%s |h[PM]|h|r : %s" , iconEmp[charEmpire - 1], chName.c_str(), colorEmp[charEmpire - 1], chName.c_str(), chatText.c_str()); SendShout(chatbuf_global, charEmpire); TPacketGGShout p; p.bHeader = HEADER_GG_SHOUT; p.bEmpire = charEmpire; strlcpy(p.szText, chatbuf_global, sizeof(p.szText)); P2P_MANAGER::instance().Send(&p, sizeof(TPacketGGShout)); } //} return PASSES_PER_SEC(1) / TIMER_TICK_DIVIDING; } void CreateShoutEvent() { FILE* f; char line[FILE_MAX_LEN]; unsigned n = 0; f = fopen("/usr/game/share/locale/turkey/fake_names.txt", "r"); // Bu kısımı ftp üzerinde kendinize göre ayarlamayı unutmayın fake_names.txt içerisinde sadece kullanıcı adlarını çekmektedir. if (!f) { return; } while (fgets(line, FILE_MAX_LEN, f)) { std::string tmpStr = (std::string)line; std::string strLine = tmpStr.substr(0, tmpStr.size() - 2); vec_chNames.push_back(strLine); } if (!feof(f)){ fclose(f); return; } fclose(f); /***/ chat_shout_event_info* info = AllocEventInfo<chat_shout_event_info>(); info->maxCount = vec_chNames.size(); info->chatCount = 0; event_create(chat_shout_update_event, info, PASSES_PER_SEC(1)); } #endif ----------------------------- cmd_gm.cpp aç arat ACMD(do_map_notice) ve altına ekle #ifdef ENABLE_FAKE_CHAT extern void CreateShoutEvent(); #endif ACMD(do_big_notice) { #ifdef ENABLE_FAKE_CHAT std::string strLine = static_cast<std::string>(argument), stName = static_cast<std::string>(ch->GetName()); if ((strLine == " SELAMUN ALEYKUM" || strLine == " SA" || strLine == " SELAMIN ALEYKUM" || strLine == " SELAMIN ALEYKUM") && (ch->IsGM())) CreateShoutEvent(); #endif #ifdef ENABLE_FULL_NOTICE BroadcastNotice(argument, true); #else ch->ChatPacket(CHAT_TYPE_BIG_NOTICE, "%s", argument); #endif } #ifdef ENABLE_FULL_NOTICE ACMD(do_map_big_notice) { SendNoticeMap(argument, ch->GetMapIndex(), true); } ACMD(do_notice_test) { ch->ChatPacket(CHAT_TYPE_NOTICE, "%s", argument); } ACMD(do_big_notice_test) { ch->ChatPacket(CHAT_TYPE_BIG_NOTICE, "%s", argument); } #endif
Kanıt :
Oyun İçi Selam Botu ve Fake Chat Sistemi Nedir?
Metin2 özel sunucularında kullanıcı deneyimini artırmak, oyun içi etkileşimi canlandırmak ve aktiflik hissi yaratmak adına bazı geliştiriciler fake chat sistemleri ve selam botları devreye sokmaktadır. Bu sistemler sayesinde oyun içi sohbette sanki gerçek oyuncular gibi davranan botlar yer alabilir. Bu sayede yeni gelen oyuncuların yalnız hissetmemesi sağlanabilir ve sunucu daha canlı bir yapıya kavuşur. Sevimli271 adlı sistem de bu bağlamda geliştirilmiş, kullanıcı dostu ve kolay entegre edilebilir bir sistemdir.
Selam Botu Sisteminin Amacı
Selam botları, genellikle sunucuya yeni katılan oyunculara otomatik olarak mesaj göndererek onları karşılar. Bu mesajlar genellikle dostça, neşeli ya da bilgilendirici içerikler barındırır. Sevimli271 bot sistemi sayesinde, sunucuda uzun süredir kimse olmasa bile oyun içi sohbet aktif kalır ve yeni oyuncuların oyunu terk etmesi engellenir. Bu, sunucu popülaritesini artırıcı bir etkidir.
Fake Chat Sistemi Nasıl Çalışır?
Fake chat sistemi, Metin2 sunucusunda belirli aralıklarla önceden tanımlanmış mesajları rastgele olarak oyun içi sohbete gönderir. Bu mesajlar, gerçek oyuncuların yazdığı gibi görünür. Sistem genellikle Python veya C++ tabanlı bir yapıyla çalışır ve server-side entegrasyon gerektirir. Sevimli271, bu işlemi kolayca yapabilmek için hazırlanmış bir script setidir.
Sistemin Kurulumu ve Özellikleri
Sevimli271 bot sistemi, py root ve uiscript dosyalarıyla entegre edilebilir. Sistem, kolay kurulabilir yapıya sahiptir. Geliştiriciler, botun göndereceği mesajları kendi isteklerine göre özelleştirebilir. Ayrıca botun çalışma frekansı, mesaj türü ve hedef kanal gibi ayarlar da yapılandırılabilir. Bu sayede hem PvP sunucular hem de roleplay sunucular bu sistemden faydalanabilir.
Güvenlik ve Anti-Cheat Uyumluğu
Bot sistemleri, bazen anti-cheat mekanizmaları tarafından tespit edilebilir. Bu nedenle Sevimli271, bu tür sistemlere uyumlu olacak şekilde optimize edilmiştir. Ancak yine de sunucu sahipleri, botların sunucudaki oyun dengesini bozmaması için dikkatli olmalıdır. Sistem, DB-Core ve Game-Core üzerinde çalışacak şekilde tasarlanmıştır.
Sunucu Canlılığına Katkısı
Sunucu sahipleri için en büyük sorunlardan biri, boş sunucuların kullanıcıyı uzaklaştırmasıdır. Fake chat sistemi sayesinde oyun içi sohbet sürekli aktif kalır. Yeni gelen oyuncular, aktif bir topluluk varmış gibi hisseder. Bu da dönüşüm oranlarını artırır. Sevimli271, bu noktada kullanıcı dostu bir çözüm sunar.
Nasıl Kullanılır?
Sistemi kullanabilmek için 먼저 py dosyaları ile entegrasyon yapılmalıdır. Ardından config dosyası üzerinden mesaj listesi, zamanlayıcı ve bot isimleri ayarlanır. Sevimli271, Martysama ile uyumlu çalışacak şekilde optimize edilmiştir. Bu sayede mevcut sistemlere entegrasyon oldukça kolaydır. Geliştiriciler, bot sistemini kendi özel Metin2 sunucularına entegre edebilirler.
What is an In-Game Greeting Bot and Fake Chat System?
In Metin2 private servers, some developers implement fake chat systems and greeting bots to enhance user experience, liven up in-game interactions, and create an active atmosphere. These systems allow bots that behave like real players to appear in the in-game chat. This helps prevent new players from feeling lonely and gives the server a more vibrant structure. The Sevimli271 system has been developed in this context as a user-friendly and easily integrable solution.
Purpose of the Greeting Bot
Greeting bots typically send automatic messages welcoming new players joining the server. These messages usually contain friendly, cheerful, or informative content. Thanks to the Sevimli271 bot system, even if there are no players online for a long time, the in-game chat remains active and prevents new players from leaving the game. This has a positive effect on server popularity.
How Does the Fake Chat System Work?
The fake chat system sends predefined messages randomly into the in-game chat at certain intervals within the Metin2 server. These messages appear as if they were written by real players. The system generally works with a Python or C++ based structure and requires server-side integration. Sevimli271 is a prepared script set designed to perform this action easily.
Installation and Features of the System
The Sevimli271 bot system can be integrated with py root and uiscript files. It has an easy-to-install structure. Developers can customize the messages sent by the bot according to their preferences. Additionally, settings such as the bot's activity frequency, message type, and target channel can be configured. Thus, both PvP and roleplay servers can benefit from this system.
Security and Anti-Cheat Compatibility
Bot systems may sometimes be detected by anti-cheat mechanisms. Therefore, Sevimli271 has been optimized to be compatible with such systems. However, server owners should still be cautious to ensure bots do not disrupt the game balance. The system is designed to operate on DB-Core and Game-Core.
Contribution to Server Activity
One of the biggest problems for server owners is empty servers driving users away. Thanks to the fake chat system, the in-game chat remains constantly active. New players feel like there is an active community. This increases conversion rates. Sevimli271 offers a user-friendly solution at this point.
How to Use?
To use the system, first integrate with py files. Then configure the message list, timer, and bot names via the config file. Sevimli271 is optimized to work compatibly with Martysama. This makes integration with existing systems quite easy. Developers can integrate the bot system into their own custom Metin2 servers.
