Jump to content
  • 0

I need info about create an effect to be seen only by party


GsL

Question

Recommended Posts

  • 0

then i think it is simpler, you can go to Creature class or L2Character (differs between packs) and go to the broadcastPacket method which is called when a skill is being casted, there you will add an if with the skill's id you want to be broadcasted only to party members and if the player that casts it is in a party then you will only broadcast it for those members

Link to comment
Share on other sites

  • 0

The 50% of the solution is already posted before. The other 50% is located at your CharInfo.java.

You have to edit this server packet too, just because after you done with this skill,effect ... The time you will user any other skill that is a 'normal' one like battle heal for example, it will broadcast all your  abnormal effects to your knownlist. 

Edited by melron
Link to comment
Share on other sites

  • 0
On 5/10/2021 at 11:03 PM, melron said:

The 50% of the solution is already posted before. The other 50% is located at your CharInfo.java.

You have to edit this server packet too, just because after you done with this skill,effect ... The time you will user any other skill that is a 'normal' one like battle heal for example, it will broadcast all your  abnormal effects to your knownlist. 

 

 

// Send a packet starting the casting.
        final int actionId = caster.isSummon() ? ActionData.getInstance().getSkillActionId(_skill.getId()) : -1;
        if (!_skill.isNotBroadcastable() || ((_skill.getId() != 10033) || ((_skill.getId() != 10032) && caster.isInParty())))
        {
            caster.broadcastPacket(new MagicSkillUse(caster, target, 0, 0, displayedCastTime, reuseDelay, _skill.getReuseDelayGroup(), actionId, _castingType));
        }

 


 

this 

 

 

and on char info this 

 

 

    final Set<AbnormalVisualEffect> abnormalVisualEffects = _player.getEffectList().getCurrentAbnormalVisualEffects();
        packet.writeD(abnormalVisualEffects.size() + (_gmSeeInvis ? 1 : 0)); // Confirmed
        // boolean party = _player.isInParty();
        // packet.writeD(abnormalVisualEffects.size() + (party ? 1 : 0));
        for (AbnormalVisualEffect abnormalVisualEffect : abnormalVisualEffects)
        {
            packet.writeH(abnormalVisualEffect.getClientId()); // Confirmed
        }
        if (_gmSeeInvis)
        {
            packet.writeH(AbnormalVisualEffect.STEALTH.getClientId());
        }
        if (!_player.isInParty())
        {
            packet.writeH(AbnormalVisualEffect.IN_A_DECAL.getClientId());
        }


This don't work forgot to say*

Link to comment
Share on other sites

  • 0

L2Party.java create a method broadcastToParty

public void broadcastToParty(final GameServerpacket gsp)
{
    for (final var member : getPartyMembers())
    {
        member.sendPacket(gsp);
    }

}

L2PcInstance create a method broadcastToMyParty

public void broadcastToMyParty(final GameServerPacket gsp)
{
    final var party = getParty();
    
    if (party != null)
        party.broadcastToParty(gsp);
    else
        sendPacket(gsp);
}

L2SkillTemplate.java create method isPartyBroadcast

final boolean _partyBroadcast;

constructor:
    _partyBroadcast = set.getBoolean("PartyBroadcast", false);
    
getter

    public boolean isPartyBroadcast()
    {
        return _partyBroadcast;
    }

L2Character.java find this (more than one)
broadcastPacket(new MagicSkillUse(...));

change it to

if (skill.isPartyBroadcast())
    broadcastToMyParty(new MagicSkillUse(...));
else
    broadcastPacket(new MagicSkillUse(...));

 

 

PS: No need to thank me, please don't talk shit about me next time Cheers

Link to comment
Share on other sites

  • 0
2 hours ago, iTopZ said:

🙈you try to ruin another mans store with your good knowledge of what is shared or not and now you ask for help 🙉

 

🙊

 

see you're funny 🙂

 

Really ? 

 

 

1 hour ago, xdem said:

L2Party.java create a method broadcastToParty

public void broadcastToParty(final GameServerpacket gsp)
{
    for (final var member : getPartyMembers())
    {
        member.sendPacket(gsp);
    }

}

L2PcInstance create a method broadcastToMyParty

public void broadcastToMyParty(final GameServerPacket gsp)
{
    final var party = getParty();
    
    if (party != null)
        party.broadcastToParty(gsp);
    else
        sendPacket(gsp);
}

L2SkillTemplate.java create method isPartyBroadcast

final boolean _partyBroadcast;

constructor:
    _partyBroadcast = set.getBoolean("PartyBroadcast", false);
    
getter

    public boolean isPartyBroadcast()
    {
        return _partyBroadcast;
    }

L2Character.java find this (more than one)
broadcastPacket(new MagicSkillUse(...));

change it to

if (skill.isPartyBroadcast())
    broadcastToMyParty(new MagicSkillUse(...));
else
    broadcastPacket(new MagicSkillUse(...));

 

 

PS: No need to thank me, please don't talk shit about me next time Cheers

public void broadcastToParty(final IClientOutgoingPacket[] gsp)
    {
        for (final var member : getMembers())
        {
            member.sendPacket(gsp);
        }

    }

 

{gr]

 

epidi einai mobius i paparia exeis idea pws kanw adapt edw?

  • Sad 1
Link to comment
Share on other sites

  • 0
11 minutes ago, GsL said:

 

Really ? 

 

 

public void broadcastToParty(final IClientOutgoingPacket[] gsp)
    {
        for (final var member : getMembers())
        {
            member.sendPacket(gsp);
        }

    }

 

{gr]

 

epidi einai mobius i paparia exeis idea pws kanw adapt edw?

public void broadcastToParty(final IClientOutgoingPacket[] gsp)

 

alakse to se

 

public void broadcastToParty(final IClientOutgoingPacket ... gsp)

Link to comment
Share on other sites

  • 0
6 minutes ago, xdem said:

public void broadcastToParty(final IClientOutgoingPacket[] gsp)

 

alakse to se

 

public void broadcastToParty(final IClientOutgoingPacket ... gsp)

L2SkillTemplate  == SkillCaster tha les logika ?

Link to comment
Share on other sites

  • 0
10 hours ago, xdem said:

SkillTemplate sto mobius

skill apla prepei na legete , nmz to fixara

 

to last part 

L2Character.java find this (more than one)
broadcastPacket(new MagicSkillUse(...));

change it to

if (skill.isPartyBroadcast())
    broadcastToMyParty(new MagicSkillUse(...));
else
    broadcastPacket(new MagicSkillUse(...));

 

 

prepei na exei parei auto apo to l2character k na to exei balei sto skillcaster  o mobius

opote paw ekei k kanw to check

 

example pws einai 

 

 

    // Send a packet starting the casting.
        final int actionId = caster.isSummon() ? ActionData.getInstance().getSkillActionId(_skill.getId()) : -1;
        
        if (!_skill.isNotBroadcastable())
        {
            caster.broadcastPacket(new MagicSkillUse(caster, target, 0, _skill.getDisplayId(), displayedCastTime, reuseDelay, _skill.getReuseDelayGroup(), actionId, _castingType));
        }
        
        if (caster.isPlayer() && !instantCast)
        {
            // Send a system message to the player.
            caster.sendPacket(_skill.getId() != 2046 ? new SystemMessage(SystemMessageId.YOU_USE_S1).addSkillName(_skill) : new SystemMessage(SystemMessageId.SUMMONING_YOUR_PET));
            
            // Show the gauge bar for casting.
            caster.sendPacket(new SetupGauge(caster.getObjectId(), SetupGauge.BLUE, displayedCastTime));
        }

 

 

[gr]

 

arxidia , zitaei k alla sto skillcaster , to mobius to exei allaksi entelos , plus eixa kataferi na kripso ta animation alla to thema einai oti einai abnormal effect k auto fenete gt to thelw na einai monimo panw stous players k auto fenete akoma k an to ekriba

 

kserw oti m ena 10-15e to exw .. fraga exw .. alla ithela to gamidi na to codaro egw 😕

 

 

Edited by GsL
  • Sad 1
Link to comment
Share on other sites

  • 0

 

16 hours ago, iTopZ said:

This is so funny, so this guy leaves bad comments on @Kara for shared codes while cant handle a limit on effect. amazing!

 

[Offtopic] I'm sorry, i'm way too successful seller/developer in this forum to try even observe tiny people. ☺️ [/Offtopic]

 

PS. Someone tell that low GsL that this is EN section and greek is not allowed.

Edited by Kara
Link to comment
Share on other sites

Guest
This topic is now closed to further replies.



  • Posts

    • DISCORD :   utchiha_market   telegram    https://t.me/utchiha_market   SELLIX STORE :   https://utchiha-market.mysellix.io/   Join the server for more products :   https://discord.gg/hoodservices
    • When it comes to encrypting passwords, using a strong hashing algorithm like SHA-256 or bcrypt is recommended. These algorithms help ensure that passwords are securely stored and protected from being easily decrypted.
    • ***CLExt L2OFF Extender Premium Account Save - Auto Login***   We would like to sell account panel for save accounts for server owners or self player.  You can login and save your id and pass accounts or delete it etc.       Price: 100 euro.   ***CLExt L2OFF Extender Premium Auto-Farm Macro System*** We would like to sell Auto-Farm Macro System for server owners or self player.  You can add your potions and your macro to farm your character with your standars.       Price: 100 euro.   If you like to order send me DM or skype zoumhs999.
    • Diablo III, the action-packed hack-and-slash RPG developed by Blizzard Entertainment, has captivated gamers worldwide since its release in 2012. Now, imagine a world where Diablo III's source code is opened up to the community, inviting developers and enthusiasts alike to enhance and refine this beloved game. This topic delves into the possibilities, challenges, and community desires surrounding the idea of Diablo III as an open-source project.   Key Points: 1. Defining Diablo III: Diablo III is an action role-playing game set in the dark fantasy world of Sanctuary. Players traverse through randomized dungeons, battling hordes of demons and collecting loot to strengthen their characters. With its compelling storyline, addictive gameplay mechanics, and rich lore, Diablo III has amassed a dedicated fanbase over the years.   2. Open Source Potential: Opening up the source code of Diablo III could unlock a wealth of opportunities for the game's future. Community developers could introduce new features, enhance existing gameplay elements, and address long-standing issues. The modding community, known for its creativity and innovation, could breathe new life into the game by creating custom content, game modes, and user interface improvements. 3. Community Interest: The question arises - would the gaming community welcome the idea of Diablo III becoming open source? Many players are eager to see the game evolve beyond its current state, with enhancements such as improved balance, expanded end-game content, and enhanced multiplayer features. By involving the community in the development process, Diablo III could foster a stronger sense of ownership and collaboration among its players. 4. Challenges and Considerations: While the concept of Diablo III as an open source is enticing, it also presents several challenges. Ensuring the integrity of the game's balance and preventing cheating would be paramount concerns. Additionally, coordinating development efforts and maintaining a cohesive vision for the game could prove challenging in a community-driven environment. However, with proper oversight and collaboration, these obstacles can be overcome. 5. Is Diablo III an MMORPG? Diablo III is often categorized as an action RPG rather than a traditional MMORPG (massively multiplayer online role-playing game). While it does feature online multiplayer elements, including cooperative play and player-versus-player combat, it lacks the persistent open world typically associated with MMORPGs. Instead, Diablo III focuses on instanced dungeons and smaller-scale multiplayer interactions. The Benefits of Improvement: Improving Diablo III through open-source development could revitalize the game, attracting new players and re-engaging existing fans. By embracing community-driven innovation, Diablo III could remain relevant and enjoyable for years to come. Additionally, fostering an active modding community could extend the game's longevity and create new opportunities for player expression and creativity.   Source code  
  • Topics

×
×
  • Create New...