Jump to content

Tryskell

Legendary Member
  • Posts

    5,343
  • Credits

  • Joined

  • Last visited

  • Days Won

    52
  • Feedback

    0%

Everything posted by Tryskell

  1. You have to remove the delete item code when you fails a enchantment and to add instead one line, the same as if the enchant was succeed, but instead of +1 you put -1. About annoucement, it's a bad idea, mainly depending of your server rates. Your chat will be flooded and becomes totally useless, as you can't block annoucement channel. Just forgive if your server (99% of servers) is an high rate, I don't know if you ever bought 100 enchants and try your luck on 5-6 items, imagine that x the number of players now, it's both useless server load and players' care issue. Search first where enchantements are made, after it will be really simple to analyze the part of code you need to remove and add.
  2. I don't think to share private projects are allowed on the board.
  3. I hate too, you have to learn the whole CMS to exploit possibilities, so I handmade mine scavenging scripts and made my own design from 3 differents designs. It's still a lot of work, around one full week. There is no solution, and even paid solution don't have any L2J scripts (templates). You can ripe off the very old L2J C3 website which was integrated with a DiskW distribution, it has a full interface and some PHP scripts (some ppl in MxC even dare to post the "who's online" map after so many years) but I have to warn you, the design is prehistoric and you have to search this "relic" by yourself. I can ask for a world without wars or a real Pokemon for christmas, but I think it will goes in the same basket than your ask :P.
  4. Google is your friend for non related developping question. This is the help section for developement issues. You spam with such nonsense questions that makes me cry. It's like I was asking what weather it does tomorrow, or if crowsbows are better than longbows in Mount & blade. It just haven't his place here, this isn't Yahoo Questions. You can try to post in the spam section too, it will be more appropriate.
  5. It can add a whole new gameplay for dagger type class if tweaked correctly. Never played on Aion ? Imo the only decent feature L2 should take from Aion is the Hide skill. Ofc, it needs a rebalance of daggers, like a HPs max decrease ^^. But it worth it. ---- You should add a random time, not a fixed time. For exemple 10-30 seconds. It avoids the skill/potion to be too much overpowered. About modified skills the Stealth could be mod for pvp purpose when the silent move toggle works for pve. The idea is just fine, settings have to be made according to personal opinion, no reason to discuss on this topic. ---- And ty for a new feature to implement :).
  6. You should contact your webhoster yup, I read some could firewalling ports to avoid spamming, which avoids to be blacklisted. Did you tried with other websites, because google isn't the only one :). Try with 2-3 others, and if it's still no, just ask to your host. You normally have an admin panel too in your webhoster, check about ports options if there is one.
  7. In IL, the only decent pack was Archid, but not the new version, the older (rev 1293M). The new got too much customs, even NPCs are custom. Too much datapack work side. Another option is to pickup the timeline from L2J and correct all your pack with their timeline, 1 by 1. This is the hard way, but sometimes you find amazing pieces of shit left in IL code. For example, 99% of running IL servers have a characters table with too much infos on it. All primal infos as stats etc are totally useless. You can go to L2JFree if you know how to compile it. Personally I have given up at first time, and L2JFree forum isn't helpful regarding old chronicles. Currently there aren't any decent IL pack, I had the idea to make one from old Archid (I talked to Sethek about it, don't begin a troll war) and fix all the missing skills etc (and currently my test server got signets and some skills you never heard about), but I dunno if people will follow.
  8. The $server variable was under ""... And what about the @ before fsockopen, I don't see the use. If that still doesn't work, try with another existing hostname, instead of your IP put www.google.com About the timeout, I have no idea how it is influenced by the ping. If it is, it could be one way. There is a default timeout set in your php.ini, so this optio is pretty useless anyway (from what I read). See more about fsockopen here : http://www.php.net/manual/en/function.fsockopen.php
  9. You tried to empty your browser cache...? Lol. Be clear with your words, you're saying when the server is off, it says "offline", and when it is online, it says nothing. You're wrong or I'm wrong ? Because if it's true we got a track, if not that make a useless post on MxC lol. Both off and on server should call nothing, if you got images when the server is offline, it's a draw problem. Lol. Try replace your images with just a damn echo too. I put the code in quote because it looks like christmas tree if you put in code tags. If you got something it's related to your images. About wamp, it was just if your current thing was a developement lab. You are supposed to be able to do the link between 2 hosts. What have you tried with mySQL so far ? Is your webhoster got security policies you didn't read ? :P EDIT : TRY TO CHANGE THE HOSTNAME FOR A REAL ONE >> WWW.GOOGLE.COM
  10. First, this faction engine sux, just from the little you shared. I don't think you can do it heavier lol. Second, this famous bug happens when you don't have actionFailed packet call. You have to add actionFailed packet else you're stuck like you say. Guess what, you're not supposed to have this bug but you have it, congratulations. Third, you have to target yourself and press escape to move again. Fourth, what chronicle ? It's supposed to be Interlude bug if it's not related to your shared code. And apparently, it doesn't have to be. Fifth, only my faction server will rule the world and elpies, muahahah.
  11. I just try to remove the followers from the "die" list :P. - PHP - mySQL - ports ---- <?php echo 'Hello world !' ; echo "Hello world !" ; ?> Just to see if it's PHP or not. If it's already broken, the "fat|cow" will becomes a burger. ---- Have you tried to put off your server, to see what the result ? ---- I don't want to give you hope, but I think it could be the use of " instead of ' when you try to call (echo) images. I remember now something like that happened to me too... Some months ago. To give a try, try my first echo situation and replace ' per ". I added the 2 versions in my code tag if you're lazy lol. If you see only one *Hello world* instead of 2, you got your answer.
  12. Akken will PM me with solution, if found :). Others can still continue searching why it bugs, and how to fix (via PM to keep it clear and save the test :D). ---- Personally, I found WHY it bugs, now I have to search HOW to correct it. It's 75% problem / 25% test now ^^. I will give the reason it does the NPE today far evening, like that you could search how to fix the problem tomorrow. All informations about the reason is write in my big post, top of page 2. You don't miss any infos. ---- Okay, we're in end of afternoon, so here is the trick : The Timer error is related to nothing. This is a false positive. The real problem is of course the line 108, which do a NPE. But why a NPE occurs sometimes ? I said in EXPERIENCES with tests the leader of the castle had to be online for the system works. Let's analyze my code (the onEnter one, not another part as xAdd was right to cry about :D) : @Override protected void onEnter(L2Character character) { if (_castle.getSiege().getIsInProgress()) { character.setInsideZone(L2Character.ZONE_PVP, true); character.setInsideZone(L2Character.ZONE_SIEGE, true); if (character instanceof L2PcInstance) { L2PcInstance activeChar = (L2PcInstance) character; activeChar.sendPacket(new SystemMessage(SystemMessageId.ENTERED_COMBAT_ZONE)); Until that part of code, nothing is custom. When you enter in the area, and if a castle siege is in progress in this area, it decides to put you on a pvp zone and a siege zone at the same time. Then it verifies if you're a L2PcInstance (aka a player) and send you a message "You entered in in a combat zone". // Mise a jour de la relation (excepte pour GMs et joueurs sans clan) if (!activeChar.isGM() && activeChar.getClan() != null) { //si le possesseur du chateau est different de rien if (_castle.getOwnerId() > 0) { This part of code says following orders will be skipped for clanless people and GMs. It adds a check to see if the castle is NPC or players sided. Nothing wrong too. ---- Now, here is the funny part and where I have problem. To remember you, the purpose of this "custom" area is to make a check on the castle owning faction. The "easiest" way is to find the faction of the leader of the clan which owns the castle where we are. Many infos needed, aren't they ? Let's process : //recherche du clan possesseur, et ensuite du clan leader L2Clan clanOwner = ClanTable.getInstance().getClan(_castle.getOwnerId()); if (clanOwner != null) { Will look the clan owner, according to the castleId. Just with that we made the "the clan which owns the castle where we are" part. It returns (from what I rem) the Id of the clanOwner. If the clan owner doesn't exists (case of bugged clans), it will skip the check. This is the part where I got my problem, and the line 108. L2PcInstance castleLord = clanOwner.getLeader().getPlayerInstance(); // si le joueur est d'une faction differente du clan possesseur, // il est affiche en ennemi - sinon il est affiche en defenseur if (activeChar.getFactionId() != castleLord.getFactionId()) activeChar.setSiegeState((byte) 1); else activeChar.setSiegeState((byte) 2); This part is the crucial point of course :). It tries to pickup the castle lord from the given clanId. After that, it uses the getPlayerInstance to reach the player's data (in this exemple, getFactionId, which is normally linked to L2PcInstance). So now, the explanation : getPlayerInstance() can't be null. If you check this method (in any chronicle) you will see a check saying if it's null, it should return. In others words, in the actual state, from the moment this player (the leader) isn't online, the check can't be made correctly, as this instance of this player isn't existing right now. So it fock up the whole system :). ---- Now you understood the problem, how to fix it ? Adding a null check is useless, as it means if the leader is offline, there won't never have siegeState checks. It would resolve the NPE, but not the problem. I think you get it, we have to recreate the check in another format :). The question now is : How to call one L2PcInstance stat (any : faction, but could be class, level, total experience, pvpkills) from a clanId, as it's the only real reliable information we got. The show must go on :) o_o
  13. He said "worth". There is no currently IL project, assuming you don't want to post every 10mins on MaxCheater forum, which won't be the good support forum anyway.
  14. Another dumb check, you said you changed IP on L2J configs, but didn't say about L2J ports. >> Are they matching ? About that > I've tried using a non-L2J related script, still having the same issue. >> if you got the same issue with a normal PHP script (try JUST an echo), it's PHP which is wrong :). >> if you tried with another stylished ports script, try with an echo :P Btw your LS/GS IP isn't the webserver one ? I have to understand you use 2 different computers if you hide your IP ? Because you just have to put 127.0.0.1 if it's the same computer. If you haven't no more solution, try install/reinstall WAMP/LAMP, and test on it :P. And try to remember what the heck you drink to fock your script yesterday, or at least what you did, haha :).
  15. Dumb question, but have you tried with a total another PHP script (not L2J related), or is there any running script which currently work in the same time than your script ? Just to verify if PHP works correctly... What's your error ? White blank screen ? Another type ? You can test your PHP/mySQL link using another type of call, like an heroe/pvp/pk/another page, to see if php and mySQL can exchange data. If you tested several scripts, that doesn't come (obviously) from script, assuming they all work :P. If others PHP scripts work, that don't come from PHP. If you can do a webpage calling heroes/etc, it doesn't come from php/mySQL link :P. If all those things higher are true, than you 're in a big shit lol :). Nha, if all is true, it can only be a firewall problem, or your router. From my PoV anyway, and I'm not a guru in PsHitP... Btw, you say in 2nd line it's not working now, and after your quote you're saying it works without issue... Have you changed something between the 2 states ? If it's a developement platform, use an all-in-one solution like WAMP/LAMP. That avoids... Many problems. Sry to don't give a real answer, but currently except if someone had exactly the same error in the past there is no real answer :D.
  16. Yup, when I began to expose my case yesterday I thought about a section which could show examples of real/fake problems, with solutions if found/possible. But it would need a complete section, one topic for one case. Currently, it should be the HELP section but... Lol :). ---- Akken wanted to lock the topic because of the flames (and your post doesn't help :P), he is willing to help people who ask. I ask, so he helps ^^. The fact I do that in public can show all internal problems you can find developing a server, and more, to develop accurate ideas of NEW gameplay (stop your fockin DM / KOTH / Newbie faction) :D. Stop to blame the bear, and check your own developer penis :P. If my contribution can help Akken to show his skills, or better, to see his handle-all-problems level, I'm glad. Stop the hate, and think about my problem :). If he finds it and you no, guess what ? It's you who will be in fault. Akken didn't affirm he was the c00lest dev in the world, he just give a try on your problem. Please understand it that way and stop the war :). And if that can help people to improve their knowledge, or give ideas of mods, "Tout est pour le mieux dans le meilleur des mondes possibles", dixit Voltaire. Back to topic please :). Dunno how it will end, but that's the funny part.
  17. Aff, double post... Time I search the delete button Matim will come and delete it :P. PS : no delete button found :o
  18. Exactly the same thing, and I didn't want to say you're wrong :). People often don't believe one people, when they're more, they trust. Like when you dl a torrent you check comments about the torrent to see if it's a fake or no :).
  19. When you do this sort of check you haven't to put == 1, because isOnline give back his own answer. Well if it's not clear, just test and if it works be happy... Lol. If not, edit your first post and add the error.
  20. xAdd, don't troll please, he tries to help :). For others, if you have any idea of resolution, don't hesitate to PM me to give me your feelings. I can let it as a test for our "helpful developer soul" and give the resolution too if he doesn't find :). ABOUT THE TEST - It is mainly to show your developing skills to others, but it's a real problem I actually try to resolve. - According how you help, people will trust you more or less, so do your best and ask the good questions :). - I can give any parts of code you will judge necessary to resolve the problem, you just can't have the full code. - YOU DON'T NEED TO RESOLVE THE PROBLEM YOURSELF, YOU CAN HELP GIVING ME TRACKS. Once again it's just to see "how you think" and "how far your logic can go". - This case is possible to resolve without the whole acess to all source. I begin to have an idea why it is buggy (see "EXPERIENCES" tab). DA ERROR ! Check my screen in first post to see the full NPE. Error in line 108 of my code (I updated sources, so it's not anymore line 106, but 108), which is supposed to be if (activeChar.getFactionId() != castleLord.getFactionId()) EXPERIENCES - I discovered than the system worked only when the leader of castle was on (so yeah, now I have a track). - I implemented the GameTimeController from L2Jrev, with javolution.jar update etc, without effect. Consider it's not a GameTimeController problem. ABOUT THE SYSTEM L2JArchid, interlude, very very old project :). The project itself isn't to blame in my case. Don't begin a troll war about lacks in Archid. My siege system is fully custom, and you need only the idea to understand it. You can't find it on any place, as I have handed-scripting all. Yeah, some people likes to develop their own ideas and not only apply patches :). L2 got castles, they're NPCs sided at begin. I have a faction server, aka 2 teams fighting each other. One of the goal of my server is to adapt sieges for factions, without using any registering NPCs. For that, I use the castle zone area, which is activated when a siege occurs. Areas got an Enter/Exit solution which is perfect for the purpose. When you enter in a castle zone, AND IF a siege occurs, a check is made about the SiegeState (RelationChanged packet). According to castle lord faction and your own faction, you are put 1 (attacker) or 2 (defender). If you got no clan or are a GM, you're set to 0. This check is usefull only for guards aggro, doors open/kill and artefact skill cast. ---- About your ask, even if I know it won't be useful to resolve this case : package com.l2jarchid.gameserver.model.zone.type; import javolution.util.FastList; import com.l2jarchid.gameserver.datatables.ClanTable; import com.l2jarchid.gameserver.datatables.MapRegionTable; import com.l2jarchid.gameserver.instancemanager.CastleManager; import com.l2jarchid.gameserver.model.L2Clan; import com.l2jarchid.gameserver.model.L2ClanMember; import com.l2jarchid.gameserver.model.actor.L2Character; import com.l2jarchid.gameserver.model.actor.instance.L2PcInstance; import com.l2jarchid.gameserver.model.actor.instance.L2SiegeSummonInstance; import com.l2jarchid.gameserver.model.entity.Castle; import com.l2jarchid.gameserver.model.zone.L2ZoneType; import com.l2jarchid.gameserver.network.SystemMessageId; import com.l2jarchid.gameserver.network.serverpackets.RelationChanged; import com.l2jarchid.gameserver.network.serverpackets.SystemMessage; import com.l2jarchid.gameserver.network.serverpackets.UserInfo; import java.util.logging.Logger; /** * A castle zone * * @author durgus */ public class L2CastleZone extends L2ZoneType { private static Logger _log = Logger.getLogger(L2CastleZone.class.getName()); private int _castleId; private Castle _castle; private int[] _spawnLoc; public L2CastleZone() { super(); _spawnLoc = new int[3]; } @Override public void setParameter(String name, String value) { if (name.equals("castleId")) { _castleId = Integer.parseInt(value); // Register self to the correct castle _castle = CastleManager.getInstance().getCastleById(_castleId); _castle.setZone(this); } else if (name.equals("spawnX")) _spawnLoc[0] = Integer.parseInt(value); else if (name.equals("spawnY")) _spawnLoc[1] = Integer.parseInt(value); else if (name.equals("spawnZ")) _spawnLoc[2] = Integer.parseInt(value); else super.setParameter(name, value); } @Override protected void onEnter(L2Character character) { if (_castle.getSiege().getIsInProgress()) { character.setInsideZone(L2Character.ZONE_PVP, true); character.setInsideZone(L2Character.ZONE_SIEGE, true); if (character instanceof L2PcInstance) { L2PcInstance activeChar = (L2PcInstance) character; activeChar.sendPacket(new SystemMessage(SystemMessageId.ENTERED_COMBAT_ZONE)); // Mise a jour de la relation (excepte pour GMs et joueurs sans clan) if (!activeChar.isGM() && activeChar.getClan() != null) { //si le possesseur du chateau est different de rien if (_castle.getOwnerId() > 0) { //recherche du clan possesseur, et ensuite du clan leader L2Clan clanOwner = ClanTable.getInstance().getClan(_castle.getOwnerId()); if (clanOwner != null) { L2PcInstance castleLord = clanOwner.getLeader().getPlayerInstance(); // si le joueur est d'une faction differente du clan possesseur, // il est affiche en ennemi - sinon il est affiche en defenseur if (activeChar.getFactionId() != castleLord.getFactionId()) activeChar.setSiegeState((byte) 1); else activeChar.setSiegeState((byte) 2); } } //sinon tout le monde est considere comme ennemi. else activeChar.setSiegeState((byte) 1); //renvoit les infos du joueur au joueur activeChar.sendPacket(new UserInfo(activeChar)); //puis aux joueurs autour de lui for (L2PcInstance player : activeChar.getKnownList().getKnownPlayers().values()) player.sendPacket(new RelationChanged(activeChar, activeChar.getRelation(player), activeChar.isAutoAttackable(player))); } } } } @Override protected void onExit(L2Character character) { if (_castle.getSiege().getIsInProgress()) { character.setInsideZone(L2Character.ZONE_PVP, false); character.setInsideZone(L2Character.ZONE_SIEGE, false); if (character instanceof L2PcInstance) { L2PcInstance activeChar = (L2PcInstance) character; activeChar.sendPacket(new SystemMessage(SystemMessageId.LEFT_COMBAT_ZONE)); //reset le state activeChar.setSiegeState((byte) 0); //renvoit les infos du joueur au joueur activeChar.sendPacket(new UserInfo(activeChar)); //puis aux joueurs autour de lui for (L2PcInstance player : activeChar.getKnownList().getKnownPlayers().values()) player.sendPacket(new RelationChanged(activeChar, activeChar.getRelation(player), activeChar.isAutoAttackable(player))); } } // les siege summons sont desummones s'ils quittent la zone if (character instanceof L2SiegeSummonInstance) ((L2SiegeSummonInstance)character).unSummon(((L2SiegeSummonInstance)character).getOwner()); } @Override protected void onDieInside(L2Character character) {} @Override protected void onReviveInside(L2Character character) {} public void updateZoneStatusForCharactersInside() { if (_castle.getSiege().getIsInProgress()) { for (L2Character character : _characterList.values()) { try { onEnter(character); } catch (NullPointerException e) {} } } else { for (L2Character character : _characterList.values()) { try { character.setInsideZone(L2Character.ZONE_PVP, false); character.setInsideZone(L2Character.ZONE_SIEGE, false); if (character instanceof L2PcInstance) ((L2PcInstance)character).sendPacket(new SystemMessage(SystemMessageId.LEFT_COMBAT_ZONE)); if (character instanceof L2SiegeSummonInstance) ((L2SiegeSummonInstance)character).unSummon(((L2SiegeSummonInstance)character).getOwner()); } catch (NullPointerException e) {} } } } /** * Removes all foreigners from the castle * @param owningClanId */ public void banishForeigners(int owningClanId) { for (L2Character temp : _characterList.values()) { if(!(temp instanceof L2PcInstance)) continue; if (((L2PcInstance)temp).getClanId() == owningClanId) continue; ((L2PcInstance)temp).teleToLocation(MapRegionTable.TeleportWhereType.Faction); } } /** * Sends a message to all players in this zone * @param message */ public void announceToPlayers(String message) { for (L2Character temp : _characterList.values()) { if (temp instanceof L2PcInstance) ((L2PcInstance)temp).sendMessage(message); } } /** * Returns all players within this zone * @return */ public FastList<L2PcInstance> getAllPlayers() { FastList<L2PcInstance> players = new FastList<L2PcInstance>(); for (L2Character temp : _characterList.values()) { if (temp instanceof L2PcInstance) players.add((L2PcInstance)temp); } return players; } /** * Get the castles defender spawn * @return */ public int[] getSpawn() { return _spawnLoc; } } TO COMPLETE Sry for french comments, but if you're smart, you can understand it easily. Good luck :D.
  21. I don't correct fail packs, and if I have to, I prefer correct my pack. I suppose it's not the only error in this distribution, so better change of distribution if dev team sux. Less problems for you.
  22. I understand why some people believe to God, aliens or other non-existant things when I read this sort of topic. Use Joomla or other CMS to do some of the work, but seriously, just give up if you're "lazy" or if you haven't the money. People don't work for free, and when they do, they do for their own. If you search slaves, you are born too late I guess. And even if my answer is highly flame-type, you got your answer in yellow, that will avoid to read my whole post because of your lazyness...
  23. Edit your first post to add the FULL error. Btw, this check == 1 can be removed. if (onlinePlayer.isOnline()) is normally enough.
  24. Currently my test is too a real problem, where he *as he offers his service public* can help. I put it public to people see if the guy can resolve things, or just appply patchs. My last post wasn't a I-already-got-a-solution problem :). Else I won't post a difficult problem. I'm a biatch, but not this day :D. I search myself the solution at this moment, lol :). ---- I didn't say it, but it's interlude, so shouldn't have any difficulty to search solution, even if L2Jbrasil/equal. About packs, they often destroy things in it, but the main code is 98% the same. The main code is around... 90% the same from IL to any other chronicle. If you remove special features (vitality, kamael) of the chronicle, ofc. Don't blame packs owners who commit nothing except credits change :D (ironic).
  25. Each time you use L2JBrasil pack, God slay a kittie. ---- What are your programming skills ? I mean, what have you done ? As Sido says it's fine you offer your services, but I have to add => what do you offer ? :) ---- LET'S GIVE YOU A TEST (and others, if you get an idea, you can help me ^^). To give you a concrete exemple, I currently work on a new siege system : when you go to the castle area, you become enemy/friend automaticaly (it's a faction system, it's why this system can work without being registered). To be short, you enter in the area, a check is made only if a siege is up on this area. If the siege check is ok, it decides if you're enemy or friend with the castle lord faction. I got a recurrent NPE, which happens when you enter in the area. I currently don't understand why it happens. Here is the onEnter code :). There are many things which are useless, it's to help me find thing which bug. @Override protected void onEnter(L2Character character) { if (_castle.getSiege().getIsInProgress()) { character.setInsideZone(L2Character.ZONE_PVP, true); character.setInsideZone(L2Character.ZONE_SIEGE, true); if (character instanceof L2PcInstance) { L2PcInstance activeChar = (L2PcInstance) character; activeChar.sendPacket(new SystemMessage(SystemMessageId.ENTERED_COMBAT_ZONE)); // Mise a jour de la relation (excepte pour GMs et joueurs sans clan) if (!activeChar.isGM() && activeChar.getClan() != null) { //si le possesseur du chateau est different de rien if (_castle.getOwnerId() > 0) { activeChar.sendMessage ("ClanID du possesseur : "+_castle.getOwnerId()); activeChar.sendMessage ("Faction du joueur : "+activeChar.getFactionId()); //recherche du clan possesseur, et ensuite du clan leader L2Clan clanOwner = ClanTable.getInstance().getClan(_castle.getOwnerId()); activeChar.sendMessage ("clanOwner : "+clanOwner); if (clanOwner != null) { activeChar.sendMessage ("clanOwner.getLeader : "+clanOwner.getLeader()); activeChar.sendMessage ("clanOwner.getLeader.getPlayerInstance : "+clanOwner.getLeader().getPlayerInstance()); // si le joueur est d'une faction differente du clan possesseur, // il est affiche en ennemi - sinon il est affiche en defenseur if (activeChar.getFactionId() != clanOwner.getLeader().getPlayerInstance().getFactionId()) { activeChar.sendMessage ("State mis a 1"); activeChar.setSiegeState((byte) 1); } else { activeChar.sendMessage ("State mis a 2"); activeChar.setSiegeState((byte) 2); } } } //sinon tout le monde est considere comme ennemi. else { activeChar.sendMessage ("Pas d'owners, alors tout le monde est un attaquant"); activeChar.setSiegeState((byte) 1); } activeChar.sendPacket(new UserInfo(activeChar)); } } } } activeChar.sendMessage ("clanOwner.getLeader : "+clanOwner.getLeader()); is supposed to be the 108th line in my NPE report. Let's see if you can understand the code, or even better, help me :D. I added a slideshow to give you an idea what it does ingame : http://img818.imageshack.us/slideshow/webplayer.php?id=shot00025u.jpg Comment on images : 1: siege start 2: castle lord enter in castle siege area 3: left the area, you lose the siege state 4: creation of another clan of the same faction than castle lord one 5: Evil joined the castle lord clan, so his state is updated 6: Sealiah is in another clan, but same faction than lord one, so she's in defense state. 7: Sealiah left the area 8: Lolicon from a good clan is coming in the castle area, his state is updated to attackers 9: As lolicon is an attacker, he can cast on the artefact. Later I will implement mercenaries too. To finish and complete the "how-to", all this trick is made thanks to the state. The state is put to 1 or 2 depending of castle lord faction. According to this state, you can or cant open/kill doors, be attacked by guards and cast on artefact.
×
×
  • Create New...