merhaba arkdaslar başlıktaki sistemi ekledim sadece gm karakterler lonca savaşı gönderebiliyor GM_PLAYER seçili olduğu halde martty sama 5.7 kullanıyorum yardımcı olabilecek varmı 200 tl karşılıgnda
cmd.cpp:
{ "savas_ilani", lonca_savas_ilani, 0, POS_DEAD, GM_PLAYER},
cmd_general:
ACMD(lonca_savas_ilani)
{
std::vector<std::string> vecArgs;
split_argument(argument,vecArgs);
if (vecArgs.size() < 11)
{
ch->ChatPacket(CHAT_TYPE_INFO, LC_TEXT("NEW_MOUNT_UNKNOWN_ARGUMENT"));
return;
}
int skor = 0;
BYTE minseviye = 0;
BYTE maxplayer = 0;
BYTE binekkullanimi = 0;
BYTE savasci, ninja, sura, shaman, zirh, sac, silah = 0;
str_to_number(skor, vecArgs[1].c_str());
str_to_number(minseviye, vecArgs[2].c_str());
str_to_number(maxplayer, vecArgs[3].c_str());
str_to_number(binekkullanimi, vecArgs[4].c_str());
str_to_number(savasci, vecArgs[5].c_str());
str_to_number(ninja, vecArgs[6].c_str());
str_to_number(sura, vecArgs[7].c_str());
str_to_number(shaman, vecArgs[8].c_str());
str_to_number(zirh, vecArgs[9].c_str());
str_to_number(sac, vecArgs[10].c_str());
str_to_number(silah, vecArgs[11].c_str());
if (skor < 1 || minseviye < 1 || maxplayer < 1)
return;
if (skor > 500)
skor = 500;
if (!ch->GetGuild())
return;
CGuild* g = ch->GetGuild();
TGuildMember* gm = g->GetMember(ch->GetPlayerID());
if (g->UnderAnyWar())
{
return;
}
if (gm->grade = GUILD_LEADER_GRADE)
{
quest::CQuestManager::instance().RequestSetEventFlagBR("binekkullanimi", g->GetName(), binekkullanimi);
quest::CQuestManager::instance().RequestSetEventFlagBR("skor", g->GetName(), skor);
quest::CQuestManager::instance().RequestSetEventFlagBR("maxplayer", g->GetName(), maxplayer);
quest::CQuestManager::instance().RequestSetEventFlagBR("minseviye", g->GetName(), minseviye);
quest::CQuestManager::instance().RequestSetEventFlagBR("savasci", g->GetName(), savasci);
quest::CQuestManager::instance().RequestSetEventFlagBR("ninja", g->GetName(), ninja);
quest::CQuestManager::instance().RequestSetEventFlagBR("sura", g->GetName(), sura);
quest::CQuestManager::instance().RequestSetEventFlagBR("shaman", g->GetName(), shaman);
quest::CQuestManager::instance().RequestSetEventFlagBR("zirh", g->GetName(), zirh);
quest::CQuestManager::instance().RequestSetEventFlagBR("sac", g->GetName(), sac);
quest::CQuestManager::instance().RequestSetEventFlagBR("silah", g->GetName(), silah);
}
}