Jump to content

Tryskell

Legendary Member
  • Posts

    5,358
  • Credits

  • Joined

  • Last visited

  • Days Won

    62
  • Feedback

    0%

Community Answers

  1. Tryskell's post in Someone To Make A Zone Peaceful. was marked as the answer   
    http://www.maxcheaters.com/topic/188679-how-to-check-remove-and-add-zone/
  2. Tryskell's post in Two Problems In One :3 was marked as the answer   
    Mana potions are using a real, event based item named Pollen. It uses the client name by default, so... You have to edit the .dat.
     
    About other question, I do'nt rem how archid looks like, it can be either under sql or xml.
  3. Tryskell's post in What Does It Take To Create A Custom Chat For Pvpers was marked as the answer   
    You use return inside the for loop, making the whole method execution stops at the first player found. In a for loop you will almost never find return, it's either break or continue.
     
    I let you search what each is doing...
     
    Finally it's a nice habit to put all "invalid" states at the beginning, which avoid those nested if and make the code more readable.
    if (Config.ENABLE_PVP_CHAT && _text.startsWith("-")) { if (activeChar.getPvpKills() < Config.PVP_CHAT_COUNT) { activeChar.sendMessage("You don't have enough pvps in order to talk to this chat"); return; } for (L2PcInstance p:L2World.getInstance().getAllPlayers().values()) p.sendPacket(new CreatureSay(0,16,activeChar.getName(),_text)); } If you want an internal check ot see if each receiver is able to read the chat, make the check
    if (Config.ENABLE_PVP_CHAT && _text.startsWith("-")) { if (activeChar.getPvpKills() < Config.PVP_CHAT_COUNT) { activeChar.sendMessage("You don't have enough pvps in order to talk to this chat"); return; } for (L2PcInstance p:L2World.getInstance().getAllPlayers().values()) { if (p.getPvpKills() < Config.PVP_CHAT_COUNT) continue; p.sendPacket(new CreatureSay(0,16,activeChar.getName(),_text)); } }
  4. Tryskell's post in Mob Agro Range was marked as the answer   
    If you want 2 groups support each other, you have to add a "clan" and a "clanRange". It's what you call in MMO "social aggro".
  5. Tryskell's post in Armor Set Passive Skill was marked as the answer   
    armorsets.sql define the sets and associated skills id. On aCis it has been XMLized under data/xml/armorsets.xml
     
    Skills stats are obviously under data/stats/skills.
  6. Tryskell's post in Removing Grand Bosses. was marked as the answer   
    You have to delete the whole manager or at least every external calls to it, otherwise it loads it from the moment it calls a getInstance(). No other choice.
     
    If you don't need it, the best move is to cleanup.
  7. Tryskell's post in Loled Hard was marked as the answer   
    PvPRewards _instance = null; must be out, otherwise it recreates the instance over and over. Basically said there is no permanent instance.
     
    But this writing style is possible, it was the writing style on L2J IL for example. Correct version should be :
    private static PvPRewards _instance = null; public static PvPRewards getInstance() { if (_instance == null) _instance = new PvPRewards(); return _instance; } More informations about the different possibilities, thread-safe and not :
    http://stackoverflow.com/questions/11165852/java-singleton-and-synchronization
     
    For the trivia, aCis still has a leftover of that era via Announcements.java. Need to rework it.
  8. Tryskell's post in Create Npc Problem. was marked as the answer   
    Check others CUSTOM NPCs, such as Andromeda or Tryskell.
    <npc id="50008" idTemplate="30519" name="Tryskell" title="Crappy Buffer"> A custom NPC must have idTemplate.
  9. Tryskell's post in [Help] Shirt Visual was marked as the answer   
    You have to send UserInfo/CharInfo packets with different informations. Instead of the different paperdoll values of armor you edit it for your fashion suit IDs.
     
    The easiest is to create :
    - an int fashionStuffId on L2PcInstance, setted back to 0 when you remove your item, setted to X when you apply it.
    - a ArmorListener, you got exemples on model.itemcontainer.listeners.
    - A static container, either hardcoded, XML, or SQL containing infos about id = list/array of itemids you want to setup.
     
    PS : I suppose those costumes already exist, and it's not client-sided. Otherwise forget my answer.
  10. Tryskell's post in Interlude Questions was marked as the answer   
    3) That forum is supposed to, depending of the good will of people.
    2) Use the another type of Announcements, which is "critical announcement" type, number 18 on Say2.java. It doesn't show "Announcements:".
    1) The problem comes from the use of int, you have to edit all for long type and still with that painful edition you will be limited because client doesn't handle another value. I invite you to use another currency, or reduce your drop rates / increase prices to balance the economy.
  11. Tryskell's post in Minions Question was marked as the answer   
    L2AttackableAIScript, onKill( section refers to onMasterDie( which got 
    if (_master.isRaid() || force) deleteSpawnedMinions(); Remove
    _master.isRaid() ||
  12. Tryskell's post in Monster Set Target was marked as the answer   
    By Pa'agrio, my eyes are bleeding.
     
    Avoid to create so much methods until they are used in another location. It becomes unreadable.
     
    I guess "npc" is the NPC to attack (let's called him "victim") ? He must walk and reach a position, meanwhile mobs are spawning and must kill it ?
     
    If you want an hint try to make steps...
     
    Step 1 : spawn your victim and make it walk.
    Step 2 : spawn monsters at interval X. We don't care about anything else.
    Step 3 : monsters must run and follow a path. Probably you have to create that path, until monsters spawn around the NPC, which is far easier to handle (no need to care about a lot of thing, you just have to reuse current victim position and spawn monsters).
    Step 4 : monsters must attack the NPC.
     
    Do your stuff in that order and don't go on another step until you reached previous step.
     
    A generic, one time spawn is handled by following :
    NpcTemplate template = NpcTable.getInstance().getTemplate(npcId); if (template != null) { if (randomOffset) { x += Rnd.get(-100, 100); y += Rnd.get(-100, 100); } L2Spawn spawn = new L2Spawn(template); spawn.setHeading(heading); spawn.setLocx(x); spawn.setLocy(y); spawn.setLocz(z + 20); spawn.stopRespawn(); L2Npc result = spawn.doSpawn(isSummonSpawn); if (despawnDelay > 0) result.scheduleDespawn(despawnDelay); // Affect the newly spawned NPC "result" here result.doSomething(); } Where parameters are following :
     
    * @param npcId : the NPC template to spawn. * @param x * @param y * @param z * @param heading * @param randomOffset : if true, set a random position * @param despawnDelay : despawn delay, if any (0 means permanent). * @param isSummonSpawn : if true, spawn with animation (if any exists).   If you want to affect the newly spawned npc, then affect "result", like : result.setWalking(); PS : methods names are perhaps different on your pack, I checked on my own pack, aCis.
     
    The above code should be put in a method, and can be reused on your event. Or simply see addSpawn from Quest.java.
  13. Tryskell's post in [Help]Compiling Error was marked as the answer   
    L2SkillLearn[] >
    List<L2SkillLearn> fixes 2 errors. Regarding last, getCanLearn is probably renamed canLearn. If it doesn't exists even on canLearn, then you have to implement the method.
  14. Tryskell's post in On Spawn Movement To Location was marked as the answer   
    Search for Gordon AI or NpcWalker system on any L2J, and CtrlIntention.INTENTION_MOVE_TO. You should find some exemples. ^^
     
    My DrChaos for example :
    npc.getAI().setIntention(CtrlIntention.MOVE_TO, new L2CharPosition(95928, -110671, -3340, 0)); About where to add it, you can override onSpawn if it's not already done. Dependant exactly what you want to do.
  15. Tryskell's post in Can You Help Me With Some Development Informations? was marked as the answer   
    Google fakepctable or fakepcstable, you should have some matches. First link I found was a L2Universe repo. Just see how they implemented the crap.
  16. Tryskell's post in Where Is The L2Pcinstance was marked as the answer   
    model/Player.java so far.
  17. Tryskell's post in [Interlude][Datapack] Sonatas Adaptation.. was marked as the answer   
    stackType doesn't allow more than one. Currently it reads the whole crap, aka Melody1;Melody2. Meaning if you got a Melody2;Melody3, it won't affect Melody 2 only, but only another Melody1;Melody2 would affect a Melody1;Melody2.
     
    You have to rework entirely the stacktype system to handle the ; parsing, and save the stackType under a List. Copy/paste GoD stackType system.
  18. Tryskell's post in Village Masters (Source Code) Acis was marked as the answer   
    <set name="type" val="L2VillageMasterPriest"/> was refering to that and my answer is accurate. As you can see Maximilian uses a Priest version of the main class, which got priests classes types condition.
  19. Tryskell's post in How To Remove The Ship was marked as the answer   
    Edit the .csv holding boat paths if it's still in old format.
  20. Tryskell's post in Problem With Respawn Time was marked as the answer   
    You have to edit each script individually on the onKill part.
  21. Tryskell's post in Help Me was marked as the answer   
    If your question is how to retrograde epilogue to interlude, the main problems are :
    - packets opcodes / structures.
    - delete postIL content.
    - revert behaviors who changed from IL > Epilogue (concerning skills, monsters, sieges or whatever existing feature).
  22. Tryskell's post in [L2J]Raidboss Alive Or Not was marked as the answer   
    GB stands for grandbosses, which is different of raidbosses.
     
    The line I cped must return a boolean. It's part of a if() check. Finally where you put it is bad.
     
    Simply check how such a NPC works, RaidbossInfo script.
     
    But your point was to make a php script, so why bothering with java ? If your question changed, consider to edit your initial post because I don't understand.
  23. Tryskell's post in L2J C5 Raid Boss Map was marked as the answer   
    You can take aCis free rev (added since rev 72) or latest L2J to find the code.
     
    You have to add RaidBossPointsManager, the associated SQL, and don't forget to add method uses aswell from that class (in the packet you talk about for exemple, but there are more locations like a global task).
  24. Tryskell's post in Npc Weapon Glow/nick Collor was marked as the answer   
    About L2Npc / L2NpcInstance, the IL writing style was L2NpcInstance / L2FolkInstance ( in that order).
     
    About glow, it's on NpcInfo or AbstractNpcInfo depending your pack.
    writeF(_collisionRadius); writeF(_collisionHeight); writeD(_enchantEffect); writeD(_npc.isFlying() ? 1 : 0); Edit : I managed to see NpcInfo from Frozen
    writeC(0x00); // C3 team circle 1-blue, 2-red writeF(_collisionRadius); writeF(_collisionHeight); writeD(0x00); // C4 writeD(0x00); // C6 So bad news for you :
    first, enchant effect isn't supported by Frozen second, your enchant issue isn't linked to that packet.  
    So until L2JFrozen edited it in another place of the code, it's probably linked to your client. You should ask to L2JFrozen forums if someone knows any config linked to that.
     
    Another possibility is that packet isn't currently used. With L2JFrozen, an apple can be a pear, and a pear a cat.
  25. Tryskell's post in Questions About An L2 Server! was marked as the answer   
    1) Telnet is a way to communicate with your server using command line (without game client). The main issue is it isn't secured, the whole stuff is deprecated as fuck and it could benefit of a GUI.
     
    2) The given projects you listed are part of L2JProject. MMOCore is the network core, Java Engine allow external .java scripts to work, Jython Engine is kept for compatibility with .py scripts but will disappear with time (as it did on my own pack). No clue what's netcon. All those project exist "in case of" a update needs to be made. You don't have to bother about it if you're not a really advanced developer.
     
    3) GG is the hacking protection tool for NCSoft, it never worked but always bored a lot of players.
×
×
  • Create New...