Jump to content

Silma

Legendary Member
  • Posts

    69
  • Joined

  • Last visited

  • Feedback

    0%

Everything posted by Silma

  1. Check this maybe help you
  2. Topic Locked. Reason solved
  3. check your config RateRaidDropItems = 1. and make this in drop min max <drop itemid="6657" min="1" max="1" chance="1000000"/> <!-- Necklace of Valakas -->
  4. ( system ) npcname-e.dat
  5. Location.java public int getZ() { return _z; }
  6. ALTERNATE_CLASS_MASTER = Boolean.valueOf(customSettings.getProperty("AlternateClassMaster", "False")); Alakseto se players kai meta ta config soy baleta sto players.properties
  7. k kaneta copy paste eki pou 8es
  8. Hello! I'm selling L2Gold Server in Java stable and no bugs server. The pack is worked for 2 years by 3 guys. Can be worked as a pvp server also because of the perfect balance between the characters. For more information send me PM, don't ask here.
  9. Trusted person. Good luck!!
  10. When i see the name, @StinkyMadness i know the server will be good. GL Mada.
  11. in your config true false # Disable the penalty level paralize curse, false by default DisableRaidCurse = True
  12. ta config ta ides einai true ? sou bgazi kanena error
  13. https://imgur.com/Uqx46Iy
  14. l2.int file edit and edit h name and save 111 [General] Start=Lineage II (Starting) Exit=Lineage II (Exiting) Run=Lineage II (Running) Product=Lineage
  15. ena login tha exis 2 database sto gameserver 7777 kai 7778 kai eisai koble
  16. Caused by: java.sql.SQLException: Access denied for user 'root '@'localhost' (using password: YES) kitakse ligo sta config exis bali password sto mysql ?? an oxi bgale to password apo to config
  17. is for acis https://pastebin.com/Cy2PWqX0
  18. how to search in google
  19. <stat name='classes' val='97,105,112' /> #P L2jFrozen_GameServer Index: head-src/com/l2jfrozen/gameserver/datatables/xml/ZoneData.java =================================================================== --- head-src/com/l2jfrozen/gameserver/datatables/xml/ZoneData.java (revision 1132) +++ head-src/com/l2jfrozen/gameserver/datatables/xml/ZoneData.java (working copy) @@ -56,6 +56,7 @@ import com.l2jfrozen.gameserver.model.zone.type.L2DerbyTrackZone; import com.l2jfrozen.gameserver.model.zone.type.L2EffectZone; import com.l2jfrozen.gameserver.model.zone.type.L2FishingZone; +import com.l2jfrozen.gameserver.model.zone.type.L2FlagZone; import com.l2jfrozen.gameserver.model.zone.type.L2FortZone; import com.l2jfrozen.gameserver.model.zone.type.L2JailZone; import com.l2jfrozen.gameserver.model.zone.type.L2MotherTreeZone; @@ -268,6 +269,8 @@ case "SwampZone": temp = new L2SwampZone(zoneId); break; + case "FlagZone": + temp = new L2FlagZone(zoneId); } // Check for unknown type Index: head-src/com/l2jfrozen/gameserver/model/zone/type/L2FlagZone.java =================================================================== --- head-src/com/l2jfrozen/gameserver/model/zone/type/L2FlagZone.java (nonexistent) +++ head-src/com/l2jfrozen/gameserver/model/zone/type/L2FlagZone.java (working copy) @@ -0,0 +1,258 @@ +/* + * This program is free software: you can redistribute it and/or modify it under + * the terms of the GNU General Public License as published by the Free Software + * Foundation, either version 3 of the License, or (at your option) any later + * version. + * + * This program is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS + * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more + * details. + * + * You should have received a copy of the GNU General Public License along with + * this program. If not, see <[url="http://www.gnu.org/licenses/>."]http://www.gnu.org/licenses/>.[/url] + */ +package com.l2jfrozen.gameserver.model.zone.type; + +import java.util.List; +import java.util.concurrent.Future; + +import javolution.util.FastList; + +import com.l2jfrozen.gameserver.datatables.SkillTable; +import com.l2jfrozen.gameserver.model.L2Character; +import com.l2jfrozen.gameserver.model.L2Skill; +import com.l2jfrozen.gameserver.model.actor.instance.L2MonsterInstance; +import com.l2jfrozen.gameserver.model.actor.instance.L2PcInstance; +import com.l2jfrozen.gameserver.model.actor.instance.L2PlayableInstance; +import com.l2jfrozen.gameserver.model.zone.L2ZoneType; +import com.l2jfrozen.gameserver.thread.ThreadPoolManager; +import com.l2jfrozen.util.random.Rnd; + +/** + * @author Strato + * @author Elfocrash (for the correction) + */ +public class L2FlagZone extends L2ZoneType +{ + int _skillId, _skillLvl; + private int _chance; + private int _initialDelay; + private int _reuse; + private boolean _enabled; + private String _target; + private Future<?> _task; + private static List<Integer> _forbiddenClasses = new FastList<>(); + + public L2FlagZone(int id) + { + super(id); + _skillId = 1323; + _skillLvl = 1; + _chance = 100; + _initialDelay = 0; + _reuse = 30000; + _enabled = true; + _target = "pc"; + } + + @Override + public void setParameter(String name, String value) + { + if (name.equals("skillId")) + { + _skillId = Integer.parseInt(value); + } + else if (name.equals("skillLvl")) + { + _skillLvl = Integer.parseInt(value); + } + else if (name.equals("chance")) + { + _chance = Integer.parseInt(value); + } + else if (name.equals("initialDelay")) + { + _initialDelay = Integer.parseInt(value); + } + else if (name.equals("default_enabled")) + { + _enabled = Boolean.parseBoolean(value); + } + else if (name.equals("target")) + { + _target = String.valueOf(value); + } + else if (name.equals("reuse")) + { + _reuse = Integer.parseInt(value); + } + else if (name.equals("classes")) + { + String[] propertySplit = value.split(","); + for (String classId : propertySplit) + { + int classes = Integer.parseInt(classId); + _forbiddenClasses.add(classes); + } + } + else + { + super.setParameter(name, value); + } + } + + @Override + protected void onEnter(L2Character character) + { + if (character instanceof L2PcInstance) + { + character.setInsideZone(L2Character.ZONE_NOSUMMONFRIEND, true); + character.setInsideZone(L2Character.ZONE_NO_HEALER, true); + if (isForbiddenClass(((L2PcInstance) character))) + { + for (L2Skill skill : character.getAllSkills()) + { + switch (skill.getSkillType()) + { + case HEAL: + case HEAL_PERCENT: + case BALANCE_LIFE: + case RESURRECT: + ((L2PcInstance) character).disableSkill(skill); + ((L2PcInstance) character).sendSkillList(); + break; + } + } + } + + // Set pvp flag + ((L2PcInstance) character).setPvpFlag(1); + ((L2PcInstance) character).sendMessage("Entrando em Zona Flag!!!"); + ((L2PcInstance) character).broadcastUserInfo(); + if ((character instanceof L2PlayableInstance && _target.equalsIgnoreCase("pc") || character instanceof L2PcInstance && _target.equalsIgnoreCase("pc_only") || character instanceof L2MonsterInstance && _target.equalsIgnoreCase("npc")) && _task == null) + { + _task = ThreadPoolManager.getInstance().scheduleGeneralAtFixedRate(new ApplySkill(/* this */), _initialDelay, _reuse); + } + } + } + + @Override + protected void onExit(L2Character character) + { + if (character instanceof L2PcInstance) + { + character.setInsideZone(L2Character.ZONE_NOSUMMONFRIEND, false); + character.setInsideZone(L2Character.ZONE_NO_HEALER, false); + if (isForbiddenClass(((L2PcInstance) character))) + { + for (L2Skill skill : character.getAllSkills()) + { + switch (skill.getSkillType()) + { + case HEAL: + case HEAL_PERCENT: + case BALANCE_LIFE: + case RESURRECT: + ((L2PcInstance) character).enableSkill(skill); + ((L2PcInstance) character).sendSkillList(); + break; + } + } + } + + ((L2PcInstance) character).setPvpFlag(0); + ((L2PcInstance) character).sendMessage("Saindo da Zona de Flag!!"); + ((L2PcInstance) character).broadcastUserInfo(); + } + if (_characterList.isEmpty() && _task != null) + { + _task.cancel(true); + _task = null; + } + } + + public L2Skill getSkill() + { + return SkillTable.getInstance().getInfo(_skillId, _skillLvl); + } + + public String getTargetType() + { + return _target; + } + + public boolean isEnabled() + { + return _enabled; + } + + public int getChance() + { + return _chance; + } + + public void setZoneEnabled(boolean val) + { + _enabled = val; + } + + class ApplySkill implements Runnable + { + @Override + public void run() + { + if (isEnabled()) + { + for (L2Character temp : _characterList.values()) + { + if (temp != null && !temp.isDead()) + { + if ((temp instanceof L2PlayableInstance && getTargetType().equalsIgnoreCase("pc") || temp instanceof L2PcInstance && getTargetType().equalsIgnoreCase("pc_only") || temp instanceof L2MonsterInstance && getTargetType().equalsIgnoreCase("npc")) && Rnd.get(100) < getChance()) + { + L2Skill skill = null; + if ((skill = getSkill()) == null) + { + System.out.println("ATTENTION: error on zone with id " + getId()); + System.out.println("Skill " + _skillId + "," + _skillLvl + " not present between skills"); + } + else + skill.getEffects(temp, temp); + } + } + } + } + } + } + + public static boolean isForbiddenClass(L2PcInstance player) + { + if (player.isGM()) + return false; + + if (_forbiddenClasses == null) + return false; + + if (_forbiddenClasses.contains(player.getClassId().getId())) + return true; + + return false; + } + + public static List<Integer> getForbiddenClasses() + { + return _forbiddenClasses; + } + + @Override + public void onDieInside(L2Character character) + { + + } + + @Override + public void onReviveInside(L2Character character) + { + onEnter(character); + } +} \ No newline at end of file Index: head-src/com/l2jfrozen/gameserver/model/L2Character.java =================================================================== --- head-src/com/l2jfrozen/gameserver/model/L2Character.java (revision 1132) +++ head-src/com/l2jfrozen/gameserver/model/L2Character.java (working copy) @@ -322,8 +322,8 @@ /** The Constant ZONE_CLANHALL. */ public static final int ZONE_CLANHALL = 16; - /** The Constant ZONE_UNUSED. */ - public static final int ZONE_UNUSED = 32; + /** The Constant ZONE_NO_HEALER. */ + public static final int ZONE_NO_HEALER = 32; /** The Constant ZONE_NOLANDING. */ public static final int ZONE_NOLANDING = 64; DATAPACK ### Eclipse Workspace Patch 1.0 #P L2jFrozen_DataPack Index: data/zones/zone.xml =================================================================== --- data/zones/zone.xml (revision 1132) +++ data/zones/zone.xml (working copy) @@ -275,11 +275,13 @@ <spawn X='17577' Y='170128' Z='-3534'/> <spawn X='19737' Y='170976' Z='-3583'/> </zone> -<zone id='11037' type='Town' shape='Cuboid' minZ='-3500' maxZ='-3400'> +<!-- <zone id='11037' type='Town' shape='Cuboid' minZ='-3500' maxZ='-3400'> --> + <zone id='11037' type='FlagZone' shape='Cuboid' minZ='-3800' maxZ='-3100'> <stat name='name' val='Primeval Isle'/> <stat name='townId' val='19'/> <stat name='taxById' val='8'/> <stat name='noPeace' val='true'/> + <stat name='classes' val='97,105,112' /> <spawn X='10468' Y='-24569' Z='-3645'/> <spawn X='10928' Y='-24641' Z='-3643'/> <spawn X='8480' Y='-23706' Z='-3727'/>
  20. Good luck with your project Dimis! Over the years your server's prooved that you're worthy. L2Mafia is a very good and stable PvP server with promising features.
  21. check this
×
×
  • Create New...

AdBlock Extension Detected!

Our website is made possible by displaying online advertisements to our members.

Please disable AdBlock browser extension first, to be able to use our community.

I've Disabled AdBlock