Jump to content
  • 0

Prevent Npc's Heading Being Adjusted To Player's Heading.


Question

Posted (edited)

I don't know but it might client side(but i think it can be changed from server side since client shows server's values, right? :P). I was wondering, is there any way to prevent NPCs change their heading according to player's? When a player speaks to an NPC, this NPC change its face to the player so player and NPC can have their "conversation. I know that this is taking place to some templates only, but i think it can be changed from server (enlighten me).

 

EDIT: L2jserver high five.

Edited by Solomun

Recommended Posts

  • 0
Posted (edited)

MoveToPawn is the key, it makes character go to npc and when it is close, run function that turns npc around. You cannot drop that packet, because it would be impossible to come near Npcs. To fix this problem you need to dig into Engine.dll and drop  ?AdjustPawnLocation@UGameEngine@@QAEXPAVAPawn@@ABVFVector@@@Z calls.

 

egjE0iD.png

Edited by vampir
  • 0
Posted

First of all, NPC heading never changes, its just an effect only the player who target can see.

 

Its a ServerPacket, I don't really remember its name but you will find it if you look at methods onAction L2NPC and friends

  • 0
Posted

First of all, NPC heading never changes, its just an effect only the player who target can see.

 

Its a ServerPacket, I don't really remember its name but you will find it if you look at methods onAction L2NPC and friends

I have searched already there. However, since NPC heading is never changed and this happens only to specific NPCs, it can be client side, right? 

  • 0
Posted

I tried this, but it ain't working..

 

MoveToPawn.java

 

 

.

.

.

@Override
protected final void writeImpl()
{
  if (target instanceof L2Npc)
  {
   L2Npc npc = (L2Npc) target;
   if (npc.getId() == 37004) //My custom NPC id
   {

    return;
   }
  }
  writeC(0x72);
 
  writeD(_charObjId);
  writeD(_targetId);
  writeD(_distance);

.

.

.

 

 

 

In case it plays any role (i doubt it), i forget to mention that i am working on L2jserver High Five.

  • 0
Posted

My answer is the only good answer. L2J didn't have that behavior for a very long time, from IL to latest, I'm the one who reported it.

 

http://www.l2jserver.com/forum/viewtopic.php?f=90&t=23583

 

And how exactly id differs from mine? You repeated the same thing only adding the severpacket's name

  • 0
Posted

And how exactly id differs from mine? You repeated the same thing only adding the severpacket's name

 

Mate, stop the ego bullshit, I could even say "I gave the answer back in 2011, you only repeat what I say in 2011" if we go on that way.

 

Grow up, one day. I hope.

 

By "my answer is the only good answer", I meant there is no other possibility. If you feel buttfuck, that's only your problem.

  • 0
Posted (edited)

Mate, stop the ego bullshit, I could even say "I gave the answer back in 2011, you only repeat what I say in 2011" if we go on that way.

 

Grow up, one day. I hope.

 

By "my answer is the only good answer", I meant there is no other possibility. If you feel buttfuck, that's only your problem.

Huh man, dont waste time on that retard, simply ignore him, dont read his trash ...

Edited by LightFusion
  • 0
Posted

Mate, stop the ego bullshit, I could even say "I gave the answer back in 2011, you only repeat what I say in 2011" if we go on that way.

 

Grow up, one day. I hope.

 

By "my answer is the only good answer", I meant there is no other possibility. If you feel buttfuck, that's only your problem.

 

whose buttfuck me or you? I didn't said it to offend you if thats what you believe. I just said that the solution was already given but you repeated it in a way that you proposed something different whereas you could simply agree and include the serverpacket name.

 

No hard feelings whatsoever, look at the post bellow you, you now have a new girlfriend pet.

  • 0
Posted (edited)

data\scripts\handlers\actionhandlers\L2NpcAction.java

 

I have done this, but NPC is turning even if the packet is not being sent.

 

 

 

// Turn NPC to the player.
     if (npc.getId() != 37004) //NPC id i want to prevent from turning
     {
      activeChar.sendPacket(new MoveToPawn(activeChar, npc, 100));
     }

 

 

 

In case u didnt mean this Tryskell, could you explain it better, of what should i do in order to fix it?

 

EDIT:

 

On the same file (l2npcaction) some lines below, i added this IF statement:

 

 

else
      {
       if (npc.getId() != 37004)
       {
        npc.showChatWindow(activeChar);
       }
      }

 

 

 

Now, as it is natural, when i talk to the NPC it doesnt open its HTML, but in addition, it doesnt turning either...which means, i ve no idea how to continue :( Of course i checked showChatWindow method, but nothing related to position or something...

Edited by Solomun
  • 0
Posted

Verify with L2PHX if you end getting the packet or no. The rotation effect is only due to this packet call (at least up to Hi5). Maybe L2J got it in 2 different places, so if you drop it somewhere it still calls it from another location.

  • 0
Posted

The only classes that call-use MoveToPawn packet is L2NpcAction in datapack (I have tried to prevent it) and 2 times in L2AbstractAI which is (with my poor knowledge) using it in order to make the L2PcInstance player move close to npc if he targets it from range. For example i am at giran maximillian and target the gatekeeper, my char walks to the GK and then L2NpcAction is taking effect...

 

P.S: I hope i was clear...posting from phone :)

  • 0
Posted

he gave you the "only correct answer"

 

still bumping? kappa

Since my problem ain't solved why shouldn't i bump? I tried what Tryskell said, or at least what i understood from what Tryskell said but it did not work, so...

Guest
This topic is now closed to further replies.


  • Posts

    • [CENTER] [SIZE=6][B][COLOR=#C084FC]L2JMOBIUS CLASSIC INTERLUDE[/COLOR][/B][/SIZE] [SIZE=5][B]QUEST AUTO MOVE + SMART TELEPORT SYSTEM[/B][/SIZE] [COLOR=#8B5CF6]━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━[/COLOR] [SIZE=4][B][COLOR=#22D3EE]FOR SALE[/COLOR][/B][/SIZE] A complete [B]Quest Navigation System[/B] for [B]L2JMobius Classic Interlude[/B] Designed for servers that want to make quest progression easier and more modern without turning the game into an Auto Quest / Auto Complete server. [COLOR=#8B5CF6]━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━[/COLOR] [SIZE=5][B][COLOR=#C084FC]MAIN FEATURES[/COLOR][/B][/SIZE] [/CENTER] [B][COLOR=#22D3EE]● QUEST AUTO MOVE[/COLOR][/B] Players can automatically move toward the next required quest objective. Supported destinations can include: [LIST] []Quest NPCs []Monsters []Quest locations []Return NPCs []Next quest stages []Class-transfer objectives [/LIST] The route can automatically update when the current quest stage is completed. [B][COLOR=#22D3EE]● SMART QUEST PROGRESS DETECTION[/COLOR][/B] The system reads the player's current quest progress and determines the next valid objective. Example: [CENTER] [B]Talk to NPC[/B] ↓ [B]Hunt Monsters[/B] ↓ [B]Collect Quest Items[/B] ↓ [B]Return to NPC[/B] ↓ [B]Continue Next Quest Stage[/B] [/CENTER] When the quest condition changes, the navigation system can automatically load the next destination. [B][COLOR=#22D3EE]● SMART TELEPORT[/COLOR][/B] For distant objectives, the system can provide controlled teleport assistance. The player is not necessarily teleported directly on top of the NPC or monster. Instead: [CENTER] [B]Teleport Near Destination[/B] ↓ [B]Auto Move[/B] ↓ [B]Reach Actual Quest Target[/B] [/CENTER] This keeps the original gameplay feeling while reducing unnecessary long-distance travel. [B][COLOR=#22D3EE]● AUTO MOVE + TELEPORT LOGIC[/COLOR][/B] The system can choose the most appropriate navigation method depending on the quest route. [CENTER] [COLOR=#4ADE80][B]NEAR OBJECTIVE[/B][/COLOR] Auto Move [COLOR=#8B5CF6]──────────────[/COLOR] [COLOR=#FACC15][B]DISTANT OBJECTIVE[/B][/COLOR] Teleport Assistance ↓ Auto Move ↓ Final Quest Destination [/CENTER] [B][COLOR=#22D3EE]● AUTOMATIC NEXT STEP[/COLOR][/B] Quest navigation does not stop after the first destination. Example: [CENTER] Player reaches NPC ↓ Quest state changes ↓ System detects new quest condition ↓ Next route becomes available ↓ Player continues automatically [/CENTER] This allows complete multi-stage quest chains to be supported. [B][COLOR=#22D3EE]● FIRST CLASS TRANSFER SUPPORT[/COLOR][/B] The system can also support the Classic Interlude first class-transfer quest chains. Example flow: [CENTER] Complete First Mark ↓ Complete Second Mark ↓ Complete Third Mark ↓ Required Marks Detected ↓ Navigate Player Toward Class Transfer [/CENTER] Useful for Human, Elf, Dark Elf, Orc and Dwarf class progression. [B][COLOR=#22D3EE]● MISSING ROUTE DETECTION[/COLOR][/B] If navigation information has not yet been configured for a quest, the system can report it instead of sending the player somewhere incorrectly. Example: [CODE] Path of the Human Knight - Missing route data [/CODE] This makes development and future quest expansion easier. [CENTER] [COLOR=#8B5CF6]━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━[/COLOR] [SIZE=5][B][COLOR=#C084FC]HOW IT WORKS[/COLOR][/B][/SIZE] [/CENTER] Example quest flow: [CODE] Quest Started | v Current Quest Condition | v Find Navigation Route | +----------------------+ | | v v Nearby Target Distant Target | | v v Auto Move Teleport | v Auto Move | v Quest Objective | v Quest State Update | v Next Route [/CODE] [CENTER] [COLOR=#8B5CF6]━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━[/COLOR] [SIZE=5][B][COLOR=#C084FC]CONFIGURATION[/COLOR][/B][/SIZE] [/CENTER] Navigation can be configured individually for quests. Possible configuration options: [LIST] []Quest ID []Quest condition / state []Target NPC []Target monster []Target coordinates []Teleport coordinates []Final Auto Move coordinates []Required quest items []Required item count []Minimum / maximum distance []Enable Auto Move []Enable Teleport []Route identifier []Next quest step [/LIST] [CENTER] [COLOR=#8B5CF6]━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━[/COLOR] [SIZE=5][B][COLOR=#C084FC]EXAMPLE[/COLOR][/B][/SIZE] [/CENTER] Player starts a class-transfer quest. [CENTER] [B]Sir Klaus Vasper[/B] ↓ Auto Move ↓ Quest Updated ↓ New Destination Detected ↓ Teleport to Required Region ↓ Auto Move ↓ Kill Required Monsters ↓ Collect Quest Item ↓ Return Route Activated ↓ Return to NPC ↓ Continue Quest [/CENTER] [CENTER] [COLOR=#8B5CF6]━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━[/COLOR] [SIZE=5][B][COLOR=#C084FC]IMPORTANT[/COLOR][/B][/SIZE] [/CENTER] [COLOR=#F87171][B]THIS IS NOT AN AUTO QUEST / AUTO COMPLETE SYSTEM.[/B][/COLOR] Players must still: [LIST] []Talk to the required NPC []Kill the required monsters []Collect required quest items []Meet quest conditions [*]Complete the original quest logic [/LIST] The system assists with: [B]Navigation + Travel + Quest Route Guidance[/B] The original quest mechanics remain active. [CENTER] [COLOR=#8B5CF6]━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━[/COLOR] [SIZE=5][B][COLOR=#C084FC]COMPATIBILITY[/COLOR][/B][/SIZE] [/CENTER] [B]Platform:[/B] L2JMobius [B]Chronicle:[/B] Classic Interlude [B]Implementation:[/B] Server Side [B]Language:[/B] Java [B]Quest Integration:[/B] Java / XML [B]Delivery Format:[/B] Source modifications / Patch [CENTER] [COLOR=#8B5CF6]━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━[/COLOR] [SIZE=5][B][COLOR=#C084FC]PACKAGE INCLUDES[/COLOR][/B][/SIZE] [/CENTER] [LIST] []Quest Auto Move Engine []Smart Teleport System []Quest Condition Detection []Automatic Next-Step Detection []Route Management []Missing Route Detection []Class Transfer Support []Quest Route Configuration []Supported Quest Routes []Installation Instructions []Source Code Changes []Unified .patch File [/LIST] [CENTER] [COLOR=#8B5CF6]━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━[/COLOR] [SIZE=5][B][COLOR=#C084FC]IDEAL FOR[/COLOR][/B][/SIZE] [/CENTER] [LIST] []Retail-style servers []Low-rate servers []Craft-oriented servers []Classic Interlude servers []New-player friendly servers []Premium membership features [*]Custom Quest Helper systems [/LIST] Especially useful for low-rate environments where quests remain important but players may not remember every NPC, region and quest route. [CENTER] [COLOR=#8B5CF6]━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━[/COLOR] [SIZE=5][B][COLOR=#C084FC]SCREENSHOTS[/COLOR][/B][/SIZE] [IMG][/IMG] [IMG] [COLOR=#8B5CF6]━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━[/COLOR] [SIZE=5][B][COLOR=#C084FC]PRICE[/COLOR][/B][/SIZE] [SIZE=5][B][COLOR=#4ADE80]€50.00[/COLOR][/B][/SIZE] Additional quest routes or custom integrations can be discussed separately. [COLOR=#8B5CF6]━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━[/COLOR] [SIZE=5][B][COLOR=#C084FC]UPDATES[/COLOR][/B][/SIZE] Future updates may include: Quest route improvements Additional supported quests Additional class-transfer routes Navigation improvements Compatibility fixes [COLOR=#8B5CF6]━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━[/COLOR] [SIZE=5][B][COLOR=#C084FC]CONTACT[/COLOR][/B][/SIZE] [B]Contact:[/B] PM HERE [COLOR=#8B5CF6]━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━[/COLOR] [SIZE=5][B][COLOR=#22D3EE]QUEST SMARTER[/COLOR][/B][/SIZE] [SIZE=4][B]Navigate Faster — Keep the Classic Gameplay[/B][/SIZE] [B][COLOR=#C084FC]L2JMobius Classic Interlude Quest Auto Move + Smart Teleport System[/COLOR][/B] [/CENTER]
    • Interesting service. I've been looking into Telegram bot promotion and your pricing seems reasonable for the keywords and country targeting.
    • [WTS] Celestial Destiny | L2 Essence 563 | Source Code or Full Project | Lifetime Support 📄 VIEW THE FULL PRESENTATION — FEATURES & SCREENSHOTS Celestial Destiny — Lineage 2 Essence | Protocol 563 2 years of development · Extensive custom features · RU / EN Celestial Destiny is available for purchase — as server pack source code or as a complete project. After two years of development, the project was shut down following a DDoS attack. The owner no longer has the funds to restore operations and continue development, leading to the decision to sell. Key features Essence mechanics: classes, skills, bosses, collections, guardians, and progression systems. Over 3,000 bug reports processed across the projects. Telegram bot: Telegram Stars payments, character statistics, notifications, teleportation, resurrection, and auto-hunting controls. Live class balancing: adjust damage, defense, critical damage, and individual multipliers without restarting the server. PvP content: 1v1 and 3v3 Olympiad, castle sieges, World Siege of Aden, and scheduled PvE/PvP modes. Enhanced client: additional skill bars, improved auto-hunting, searchable inventory, bulk enchanting, and convenient item management. Custom systems: expanded costumes, seasonal collections, Combat Power rankings, Revelation skills, Season Pass, promo codes, and two-way Discord chat. Economy: world trading with two currencies and a server-side donation shop that requires no client edits. Two purchase options ① Server pack source code Essence protocol 563 source code with the implemented mechanics and custom features, for use in your own project. ② The entire project The server pack with source code, game client, all web components, donation system, Telegram bot, and all existing configured integrations — transferred in their current state. We will show the project, its web components, and connected systems privately, and discuss the exact scope of the transfer. Free lifetime support All official content and custom features already included in the server pack are covered by free lifetime support, with no monthly fees. Additional custom development is discussed separately. Serious buyers only For serious investors and server administrators with the budget to purchase and develop the project. This is not a low-budget offer. Pricing for both options is discussed privately. Please specify whether you are interested in source code or the complete project. ✉️ CONTACT US ON TELEGRAM — @L2scripts 📄 VIEW THE FULL PRESENTATION — FEATURES & SCREENSHOTS
    • I've found the Conquest maps and Marketplace flipping to be the most reliable for me. Don't sleep on those Diamond Quest challenges either, just watch that 10% tax carefully.
  • Topics

×
×
  • Create New...

Important Information

This community uses essential cookies to function properly. Non-essential cookies and third-party services are used only with your consent. Read our Privacy Policy and We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue..