How to get player / npc heading?
Forum rules
READ NOW: L2j Forums Rules of Conduct
READ NOW: L2j Forums Rules of Conduct
- DreamStage
- Posts: 222
- Joined: Mon Oct 11, 2010 2:38 am
- Location: Portugal
How to get player / npc heading?
Hello, when i want to add some spawn, i have difficulty to get the heading i want. Is there any admin command to check for my heading number? Like //heading? In game ofc.
Ignorance comes when you dont want to know the truth about facts.
- jurchiks
- Posts: 6769
- Joined: Sat Sep 19, 2009 4:16 pm
- Location: Eastern Europe
Re: How to get player / npc heading?
The NPCs spawned via //spawn should spawn with the same heading as yours. If you're spawning them via a script, check player.getHeading() (it comes from from L2Character, so it's available for all characters).
If you have problems, FIRST TRY SOLVING THEM YOURSELF, and if you get errors, TRY TO ANALYZE THEM, and ONLY if you can't help it, THEN ask here.
Otherwise you will never learn anything if all you do is copy-paste!
Discussion breeds innovation.
Otherwise you will never learn anything if all you do is copy-paste!
Discussion breeds innovation.
- DreamStage
- Posts: 222
- Joined: Mon Oct 11, 2010 2:38 am
- Location: Portugal
Re: How to get player / npc heading?
no that... i said, i didnt want the heading throw code. For that i already know. I mean, i addspawn(xxxxxxx) at some random location, but with some heading. I need to check with my ADMIN inside SERVER what heading i have at the exact same location looking for some location.
Ignorance comes when you dont want to know the truth about facts.
- Zoey76
- L2j Inner Circle
- Posts: 7005
- Joined: Tue Aug 11, 2009 3:36 am
Re: How to get player / npc heading?
http://svn.l2jdp.com/branches/unstable/ ... Shift.java
DP Changeset 8601
Check there, maybe I implement it for players too (if not done already)
DP Changeset 8601
Check there, maybe I implement it for players too (if not done already)
Powered by Eclipse 4.30 | Eclipse Temurin 21 | MariaDB 11.3.2 | L2J Server 2.6.3.0 - High Five
Join our Discord!
Join our Discord!
- jurchiks
- Posts: 6769
- Joined: Sat Sep 19, 2009 4:16 pm
- Location: Eastern Europe
Re: How to get player / npc heading?
Do you want to spawn an npc like "//spawn npcId x y z heading"?
If you have problems, FIRST TRY SOLVING THEM YOURSELF, and if you get errors, TRY TO ANALYZE THEM, and ONLY if you can't help it, THEN ask here.
Otherwise you will never learn anything if all you do is copy-paste!
Discussion breeds innovation.
Otherwise you will never learn anything if all you do is copy-paste!
Discussion breeds innovation.
- DreamStage
- Posts: 222
- Joined: Mon Oct 11, 2010 2:38 am
- Location: Portugal
Re: How to get player / npc heading?
ye, but now i found it, i didnt had that changeset. Thank you Zoey
Ignorance comes when you dont want to know the truth about facts.