deivisonamorim 1 Postado Outubro 29, 2015 Share Postado Outubro 29, 2015 (editado) To com uma poblema q e o Seguinte o player nao ta pegando yellow quando ataka um PK e nao ta aparecendo pvp para o server todo guando mata um PK so aparece guando O player q pegou pk mata podem me ajuda ..? aki esta o codigo #ifdef __SKULLSYSTEM__ Skulls_t Player::getSkull() const { if(getAccessLevel() >= ACCESS_PROTECT) return SKULL_NONE; return skull; } Skulls_t Player::getSkullClient(const Player* player) const { if(!player){ return SKULL_NONE; } Skulls_t skull; skull = player->getSkull(); #ifdef __PARTYSYSTEM__ if(skull != SKULL_RED && player->party != NULL && player->party == this->party) return SKULL_GREEN; #endif if(skull == SKULL_NONE){ if(player->hasAttacked(this)){ skull = SKULL_YELLOW; } } return skull; } bool Player::hasAttacked(const Player* attacked) const { if(accessLevel >= ACCESS_PROTECT) return false; if(!attacked) return false; AttackedSet::const_iterator it; unsigned long attacked_id = attacked->getID(); it = attackedSet.find(attacked_id); if(it != attackedSet.end()){ return true; } else{ return false; } } void Player::addAttacked(const Player* attacked) { if(accessLevel >= ACCESS_PROTECT) return; if(!attacked || attacked == this) return; AttackedSet::iterator it; unsigned long attacked_id = attacked->getID(); it = attackedSet.find(attacked_id); if(it == attackedSet.end()){ attackedSet.insert(attacked_id); } } void Player::clearAttacked() { attackedSet.clear(); } void Player::addUnjustifiedDead(const Player* attacked) { if(getAccessLevel() >= ACCESS_PROTECT || attacked == this) return; std::stringstream msg; msg << "PvP: " << getName() << " (Level: " << getLevel() << ") Matou " << attacked->getName() << " (Level:" << attacked->getLevel() << ")."; g_game.addAnimatedText(this->getPosition(), 129, "Drink!"); for(AutoList<Player>::listiterator it = Player::listPlayer.list.begin(); it != Player::listPlayer.list.end(); ++it){ if(dynamic_cast<Player*>(it->second)) (*it).second->sendTextMessage(MSG_STATUS_CONSOLE_BLUE, msg.str().c_str()); } Editado Outubro 29, 2015 por deivisonamorim Link para o comentário Compartilhar em outros sites More sharing options...
0 Deadpool 862 Postado Outubro 29, 2015 Share Postado Outubro 29, 2015 Posta o config.lua Link para o comentário Compartilhar em outros sites More sharing options...
0 deivisonamorim 1 Postado Outubro 29, 2015 Autor Share Postado Outubro 29, 2015 (editado) -------- config.lua ---------- Config file for OTServ -------------------------------- data directory locationdatadir = "data/"-- map locationmap = "data/world/Evolutions.otbm"-- mapkind-- options: OTBM for binary map, XML for OTX mapmapkind = "OTBM"-- map store location (for XML only)mapstore = "data/world/Evolutions-mapstore.xml"-- house store location (for XML only)housestore = "data/world/Evolutions-housestore.xml"-- bans storage (for XML only)banIdentifier = "data/bans.xml"-- server nameservername = "Drink Servidor 7.92 RPG"-- server locationlocation = "Brasil"-- server ip (the ip that server listens on)ip = "186.192.1.212"-- server port (the port that server listens on)port = "7171"-- server urlurl = "drink.servegame.com"-- server owner nameownername = "Drink Server"-- server owner emailowneremail = "Drink Server Souls RPG."-- world type-- options: pvp, no-pvp, pvp-enforcedworldtype = "pvp"-- exhausted time in ms (1000 = 1 second)exhausted = 800-- exhausted time in ms for non-aggressive spells (1000 = 1 second)exhaustedheal = 1000-- how many ms to add if the player is already exhausted and tries to cast a spell (1000 = 1 second)exhaustedadd = 0-- how long does the player has to stay out of fight to get pz unlocked in ms (1000 = 1 second)pzlocked = 60*3000-- house rent period-- options: daily, weekly, monthlyhouserentperiod = "weekly"-- motd (the message box that you sometimes get before you choose characters)motd = "Bem vindo ao Drink Server RPG 7.92."motdnum = "1"-- login messageloginmsg = "Sejam Bem Vindos ao Drink Server RPG."-- how many logins attempts until ip is temporary disabled-- set to 0 to disablelogintries = 0-- how long the retry timeout until a new login can be made (without disabling the ip)retrytimeout = 60*5000-- how long the player need to wait until the ip is allowed againlogintimeout = 3000-- allow clones (multiple logins of the same char)-- options: 0 (no), 1 (yes)allowclones = 0-- max number of players allowedmaxplayers = "150"-- SQL type-- options: mysql, sqlitesql_type = "mysql"--- MySQL part (ignore if you are using SQLite)sql_host = "localhost"sql_user = "root"sql_pass = "thttu"sql_db = "otserv"--- SQLite part (ignore if you are using MySQL)sqlite_db = "db.s3db"----------------------------------------------------------------------------------------------------------------------------- Evolutions Basic Configuration ------------------------------------------------------------------------------------------------------------------------------- world name (shows in the character list)worldname = "Drink Continent"-- time to save the server (default = 1)autosave = 1-- do you want to enable cap system? (yes/no)capsystem = "yes"-- anti-afk - maximum idle time to kick player (1 = 1min)kicktime = 15-- how many summons player can havemaxsummons = 1-- maximum items in depotmaxdepotitems = 1000-- learn spells (yes/no)learnspells = "no"-- do you want everyone to have premiumfreepremium = "yes"-- remove ammunation? (bolts/arrows)removeammunation = "no"-- remove rune charges? (sd/hmm/gfb)removerunecharges = "yes"-- use item hotkeys? (yes/no)itemhotkeys = "yes"-- shoot trough battle window on players? (yes/no)battlewindowplayers = "yes"-- use account manager? (yes/no)accountmanager = "yes"-- summon follows master everywheresummonsfollow = "yes"-- allow outfit changeoutfitchange = "yes"-- damage to players with the same feetfeetdamage = "yes"-- guild system type (SQL only)(ingame/online)-- online guild system requires the latest Swelia AACguildsystem = "ingame"------------------------------------------------------------------------------------------------------------------------ Multipliers -------------------------------------------------------------------------------------------------------------------------- experience multiplier (how much faster you got exp from monsters)expmul = 1-- experience multiplier for pvp-enforced (how much faster you got exp from players)expmulpvp = 1-- monster lootrating (how much faster you get items from monsters)lootmul = 7878-- skill multiplier (another multiplier in data/vocations.xml)skillmul = 5454-- manaspent multiplier (another multiplier in data/vocations.xml)manamul = 4545-- how many monsters spawn at a time in 1 spawnspawnmul = 2-- Price for each SQM when buying a househouseprice = 25-- level to buy a househouselevel = 300-- maximum death entries per playermaxdeathentries = 10-- max message buffer (default = 4)-- how fast you get mutedmessagebuffer = 8-- minimum action interval (default = 200)minactioninterval = 200-- protection for those under this levelprotectionlimit = 10-- chance to make a critical hit (10 = 10%)criticalhit = 10-- sistema de critical chance and damage {chance, vezes(x) damage}criticaldamage = {"15", "3"}----------------------------------------------------------------------------------------------------------------- Skull System configuration ------------------------------------------------------------------------------------------------------------------ time to lose a white Drink (1 = 1 minute)whitetime = 3-- time to lose one frag (1 = 1 minute)fragtime = 200*0.5 --1440 = 24h---- ban unjust, how many frags you need to get banned (1 = 1 frag)banunjust = 7-- red Drink unjust, how many frags you need to get a red Drink (1 = 1 frag)redunjust = 5-- bantime, for how long the player is banned (1 = 1 hour)bantime = 2--------------------------------------------------------------------------------------------------------------------- GM access rights ------------------------------------------------------------------------------------------------------------------------ access to walk into houses and open house doorsaccesshouse = 3-- access to login without waiting in the queue or when server is closedaccessenter = 1-- access to ignore damage, exhaustion, cap limit and be ignored by monstersaccessprotect = 3-- access to broadcast messages and talk in colors (#c blabla - in public channels)accesstalk = 1-- access to move distant items from/to distant locationsaccessremote = 3-- access to see id and position of the item you are looking ataccesslook = 2 Editado Outubro 29, 2015 por deivisonamorim Link para o comentário Compartilhar em outros sites More sharing options...
0 deivisonamorim 1 Postado Novembro 7, 2015 Autor Share Postado Novembro 7, 2015 @up Link para o comentário Compartilhar em outros sites More sharing options...
0 deivisonamorim 1 Postado Dezembro 15, 2015 Autor Share Postado Dezembro 15, 2015 @up Link para o comentário Compartilhar em outros sites More sharing options...
0 deivisonamorim 1 Postado Dezembro 31, 2015 Autor Share Postado Dezembro 31, 2015 ?@up Link para o comentário Compartilhar em outros sites More sharing options...
0 Lord Stryton 18 Postado Janeiro 1, 2016 Share Postado Janeiro 1, 2016 Nem posso ajudar, tou muito ocupado.Sem Flood Link para o comentário Compartilhar em outros sites More sharing options...
0 deivisonamorim 1 Postado Janeiro 18, 2016 Autor Share Postado Janeiro 18, 2016 @up Link para o comentário Compartilhar em outros sites More sharing options...
0 Luga03 331 Postado Outubro 6, 2016 Share Postado Outubro 6, 2016 Caro membro, seu tópico foi movido de Otserv > Programação para Otserv > Suporte Otserv. Link para o comentário Compartilhar em outros sites More sharing options...
Pergunta
deivisonamorim 1
Editado por deivisonamorim
Link para o comentário
Compartilhar em outros sites
8 respostass a esta questão
Posts Recomendados