Graal Forums

Graal Forums (https://forums.graalonline.com/forums/index.php)
-   Feature request (https://forums.graalonline.com/forums/forumdisplay.php?f=194)
-   -   Over & Under (https://forums.graalonline.com/forums/showthread.php?t=134267306)

Kiwi27 10-28-2012 12:14 AM

Over & Under
 
There should be a way you can make so if the player is walking from the left or right, they go over an NPC, and if they come from above or below it they walk under it, and vice versa.

That's all.

maximus_asinus 10-28-2012 12:16 AM

it has been a while I have scripted but I thought setshape2 could achieve this?

Kiwi27 10-28-2012 12:23 AM

Idk. I remember reading a thread a while ago where someone was asking if it was possible, and the answer was no. Sorry if I'm wrong.

Tricxta 10-28-2012 12:24 AM

Quote:

Originally Posted by Kiwi27 (Post 1706523)
There should be a way you can make so if the player is walking from the left or right, they go over an NPC, and if they come from above or below it they walk under it, and vice versa.

That's all.

I achieved this with no npc server in gs1. It really depends on if you're doing this for a single player instance or a normal level.

If you're doing it for a single player instance you can just use drawoverplayer() and what not, for multiple players I had a weapon that called showani to draw a replica of the player over the player that's shown to everyone, and then you can control on which layer the player draws. It's not the best method but it works. I'm sure with the resources gs2 and a npc have to offer there's a much more elegant solution but I haven't really played with all of it that much.

Kiwi27 10-28-2012 12:27 AM

Ah. I was wrong, nevermind. I just found the thread. Not sure why it stuck in my mind that you couldn't though. http://forums.graalonline.com/forums...hp?t=134261769

Crono 10-28-2012 01:24 AM

you know i could have sworn i saw this back in 2001 on some version of sanstrata...

callimuc 10-28-2012 01:35 AM

it is possible to do such a thing on your own. somewhere on my computer i still have it i think

DustyPorViva 10-28-2012 02:15 AM

There are two ways to do it, neither are very attractive.

The first way, which is the smoothest way, is to do the detections yourself. The problem with this method is that it only applies to you. Other players will not reflect their status with the NPC(let's say a bridge in this case). If you touch the bridge and you make the bridge draw over you, it will draw over ALL other players. This method works fine offline though.

The second way is to use attachplayertoobj(), the benefit is that it remedies the issues with the above. Players are attached to the NPC, so if a player is on the bridge and the bridge is drawn over your player, so will the players on the bridge. The issue with this method though is it's serverside, so there is substantial lag when trying to attach/detach players. For instance when you touch the bridge to walk over it, you will keep going, then BAM it'll snap your player back to the end of the bridge because it has finally synced your player with the server. This is fairly annoying, imo.

The only way to resolve this would to be able to change the layers of players themselves.

Tricxta 10-28-2012 02:59 AM

I think my showani solution is worth considering.


All times are GMT +2. The time now is 09:06 AM.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.