OldHero 12 Report post Posted September 12, 2016 Hello guys i need ur help how i can make ppl cant feed in maps like,vod cod with alts any help any script to share ? ty Quote Share this post Link to post Share on other sites
Foxseiz 138 Report post Posted September 13, 2016 Prevent a player on entering those maps if they have the pet food or fruit or whatever. Go to entry.lua and add the code under the function "function check_can_enter_garner2( role, copy_mgr )" local Num_1 = CheckBagItem(role, ITEM_ID) If Num_1 >= 1 then SystemNotice(role, "Please remove [ITEM_NAME] from your inventory to enter.") return 0 end Quote Share this post Link to post Share on other sites
V3ct0r 2,121 Report post Posted September 13, 2016 You also can put a small check for character map in functions of these items in ItemEffect.lua Quote Some useful links / Полезные ссылки Tips for making a topic in 'Questions & Help' / Рекомендации по созданию тем в разделе "Помощь" Server Advertising Section Rules / Правила раздела "Реклама серверов" Available e-mail domains for registration / Допустимые e-mail домены для регистрации User groups / Группы пользователей User ranks / Звания пользователей "Broken" pictures on the forum / "Битые" изображения на форуме Beware of scammers! / Осторожно, мошенники! My developments / Мои разработки Mods for client and server / Моды для клиента и сервера PKOdev.NET website for Tales of Pirates Server / PKOdev.NET веб-обвязка для сервера Пиратии I do not provide any help in private messages and outside the forum. Use 'Questions & Help' section please. Thank you for understanding! Я не оказываю какую-либо помощь в личных сообщениях и вне форума. Пожалуйста, используйте раздел "Пиратия: Помощь". Благодарю за понимание! Share this post Link to post Share on other sites
OldHero 12 Report post Posted September 13, 2016 yea bro i had this script in my mind but what if his alt get this item what need to enter hmm ? Quote Share this post Link to post Share on other sites
OldHero 12 Report post Posted September 13, 2016 @V3ct0r hm how you mean ? Quote Share this post Link to post Share on other sites
MonkeyCode 453 Report post Posted September 14, 2016 he means, by putting the check inside the item function. prohibmap = { garner2 = true, vod = true } if prohibmap[GetChaMpaName(role)] then UseItemFailed(role) return end Also, try putting the signatures of fruit item function into a table, and loop through the table and hooking it using _G not necessarily needed but may help you decrease the time to add the checks to each fruit. Quote Share this post Link to post Share on other sites
V3ct0r 2,121 Report post Posted September 14, 2016 @OldHero Let's take Fairy Ration (ID 227) for example. Its function in ItemEffect.lua is ItemUse_SiLiao function ItemUse_SiLiao(role, Item, Item_Traget) local Cha_Boat = 0 Cha_Boat = GetCtrlBoat(role) if Cha_Boat ~= nil then SystemNotice(role, "Cannot use while sailing") UseItemFailed(role) return end local Item_Traget_URE = GetItemAttr(Item_Traget, ITEMATTR_URE) local Item_Traget_MAXURE = GetItemAttr(Item_Traget, ITEMATTR_MAXURE) local Item_type = GetItemType(Item) local Item_Traget_Type = GetItemType(Item_Traget) local Num = 2500 if Item_type == 57 and Item_Traget_Type == 59 then if Item_Traget_URE < Item_Traget_MAXURE then Give_ElfURE (role, Item_Traget, Num) else SystemNotice(role, "Fairy is full") UseItemFailed(role) return end end end Then you can get character's map using GetChaMapName() function and make a small check: function ItemUse_SiLiao(role, Item, Item_Traget) local Cha_Boat = 0 Cha_Boat = GetCtrlBoat(role) if Cha_Boat ~= nil then SystemNotice(role, "Cannot use while sailing") UseItemFailed(role) return end -- Our check for map local map_name = GetChaMapName(role) if map_name == "garner2" then SystemNotice(role, "You can't use this item in Chaos Argent!") UseItemFailed(role) return end local Item_Traget_URE = GetItemAttr(Item_Traget, ITEMATTR_URE) local Item_Traget_MAXURE = GetItemAttr(Item_Traget, ITEMATTR_MAXURE) local Item_type = GetItemType(Item) local Item_Traget_Type = GetItemType(Item_Traget) local Num = 2500 if Item_type == 57 and Item_Traget_Type == 59 then if Item_Traget_URE < Item_Traget_MAXURE then Give_ElfURE (role, Item_Traget, Num) else SystemNotice(role, "Fairy is full") UseItemFailed(role) return end end end Now players can't feed fairies in Chaos Argent. @KONG your code has a typo: GetChaMpaName => GetChaMapName 1 Quote Some useful links / Полезные ссылки Tips for making a topic in 'Questions & Help' / Рекомендации по созданию тем в разделе "Помощь" Server Advertising Section Rules / Правила раздела "Реклама серверов" Available e-mail domains for registration / Допустимые e-mail домены для регистрации User groups / Группы пользователей User ranks / Звания пользователей "Broken" pictures on the forum / "Битые" изображения на форуме Beware of scammers! / Осторожно, мошенники! My developments / Мои разработки Mods for client and server / Моды для клиента и сервера PKOdev.NET website for Tales of Pirates Server / PKOdev.NET веб-обвязка для сервера Пиратии I do not provide any help in private messages and outside the forum. Use 'Questions & Help' section please. Thank you for understanding! Я не оказываю какую-либо помощь в личных сообщениях и вне форума. Пожалуйста, используйте раздел "Пиратия: Помощь". Благодарю за понимание! Share this post Link to post Share on other sites
Billy 164 Report post Posted September 14, 2016 I think he means feed as in boosting score by killing alts, not feed as in fairy fruits. Main issue you will have is working out if thy are actually boosting, or of its just a coincidence that the same person keeps looking the same person. One solution is just adding a cool down if the same person kills the same person too many times, but his is not perfect. You might be able to set up a SQL trigger to write cha I'd and IP/MAC to a file on row update, and then check on kill, but the issue is Mac can be changed in login packet and IP by proxy 1 Quote Share this post Link to post Share on other sites