I think the answer is yes. Sort of. I'm running on linux but I get what you're asking.
My server install is ~/server and there's a symbolic link for plugins there that goes to ~/quests/plugins. So ~/server/plugins points to ~/quests/plugins So they're one and the same. Or they should be. At any rate, players.pl is there. Code:
eqadmin@eqemu:~/server/plugins$ ls Code:
eqadmin@eqemu:~/server/quests/plugins$ ls |
"So the ghanja's code works, but it sends me to the zone safe spots rather than the druid ring. Would it make sense to add the x,y,z,h values into the $porthash array and call them in a quest::movenpc rather than a quest::zone command?"
You will want to use quest::movepc(zone_id,x,y,z,h) not quest::movenpc because the object you're trying to port is the player character. Just using quest::zone sends to the save coordinates of the zone. Simply run to the druid rings of your destination zone, target yourself, type #loc (NOT /loc unless you like reversing x and y), and use that location in the quest::movepc command. The zone_id portion will accept numbers for the zone IDs or pass it the zone shortname with $text. I haven't searched the plugins folder for it but someone may have made a plugin that converts zone shortname to ID#. |
|
Ah, yeah, I posted that before you posted what you said. No problem.
|
Quote:
Code:
quest::movenpc($porthash{$key}[1],[2],[3],[4],[5]); |
1) You have to access the hash elements the same way every single time.
Code:
quest::movepc($porthash{$key}[1], $porthash{$key}[2], $porthash{$key}[3], $porthash{$key}[4], $porthash{$key}[5]); |
Not sure if you made changes yet, but for anyone following the thread:
Code:
sub EVENT_SPAWN { |
I figured it out about 30 minutes ago, then saw your PM. I really appreciate the help from everyone on this. Hopefully I can pay it forward. Here's what I came up with:
Code:
sub EVENT_SAY{ The last thing I'd like to do with this is make the Superior Camo not be a self-cast (if its possible). Been looking at some other threads about group spells, but technically it's not a group spell. You just have to be in the group for it to land on you. If there's a way to fake the NPC casting this on the player, I'm all ears: Code:
quest::selfcast(34); Code:
$npc->CastSpell(34, $client); |
Crude as hell, but, hopefully you gain something from it:
Code:
sub EVENT_SPAWN { |
Sorry for the time gap. Work and brain melt. Had to take a break. Tried the above code but it seems to only be performing this part of the action:
Code:
else { I'm ok with using the selfcast but if you self-cast and already have the spell it sends an error that the player is already invisible. Is there a way to check for a spell effect active on the player? If there is I could just throw an if statement in there to see if player is already invisible and skip the selfcast if they are. Digging through the lexicon now because I'm not quite sure what I"m searching for. Edit2: BreakInvis(); will do. :) Code:
else { |
Or not even cast it if they already have it, though, breaking the invis would allow for a "fresh" cast, so whichever way you prefer:
Code:
sub EVENT_SPAWN { You can also use: Code:
$client->BuffFadeBySpellID(43); Code:
$group_member->BuffFadeBySpellID(43); |
Quote:
Quote:
Code:
$client->FindBuff(); |
Thanks to everyone for their help on this. Admittedly, I feel that ghanja did a lot of the heavy lifting here so I'd be remiss to not give credit where credit is due. I mainly built upon his suggestions. Big thanks for all your patience.
Here's the finished product, but first - some notes: 1. This requires the NPC be either a druid or a wizard class. In my case, I added druid NPCs to druid rings and wizard NPCs to wizard spires using this method and slapped this script on them. 2. This ports to old world maps. More specifically, Vanilla EQ original maps (except Lavastorm - working on that). With minor tweaking of the zone ID# and x,y,z,h locations in the %porthash(es) or adding additional zones, it could easily be made to work with other zones. Though if you wanted to, you could add them anywhere you wanted to stick a porter. 3. It automatically casts invis on whoever is being ported (this is to allow evil races to use them with minimal risk of druids eating them). 4. It has spell effects and a small delay for aesthetics. Code:
########################################################### Code:
sub EVENT_SPAWN { |
All times are GMT -4. The time now is 09:54 PM. |
Powered by vBulletin®, Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.