Sunday, January 25, 2009

Aurora Engine: The Easy Way to Add Secret and Placeable Doors to Your NWN Mod

It is shocking to me that the Bioware builders page on this subject is so absurdly out of date and incomplete. After extensive trial and error I've managed to document at least enough of the procedure so that Noobs like myself can quickly and easily set up secret and placable doors.

Placeable Doors:
Placeable doors are easy. You cannot use a "Hidden Wall Door" or "Hidden Trapdoor" from the miscelaneous interior standard pallet. Instead go to "Secret Object" and select a door from there. Now give the door a unique tag (For example "DoorPlaceableTag"). Under most circumstances you may want to remove the word "Secret" from the name so only the word "Door" will come up in-game if the player mouses over it.

Finally you need to place the waypoint. This waypoint will be the door's destination. Place the waypoint at the point where you want the door users to teleport to when thy go through the door and give it the same tag as your placeable door with the prefix "DST_" (for example "DST_DoorPlaceableTag").

Optionally you can use any door placeable and a waypoint using the naming conventions above and simply change the OnUsed script to x0_o2_use_wdoor.

If you open the OnUsed script you will see that the comments tell you to use a "LOC_" prefix. This is wrong. It is nothing shy of sadistic that this has never been corrected in any of the patches.


Secret Doors
How it works:
A secret door is simulated by putting an "OnHeartbeat" script on an invisible "trigger placeable" object. Every heartbeat (about once every six seconds) this script checks the skills of nearby players and rolls to see if the most skilled searcher has spotted the secret door.


When one of the players spots the door the trigger placeable destroys itself, spawns in a door at it's location, and sets it's Tag name as a string variable on it.

The door has an OnUsed script that uses the string variable to teleport anyone who uses it (along with henchmen and pets) to a waypoint with the same name.

How to set it up:
Place a "Hidden Trapdoor Trigger" or a "Hidden Wall Door Trigger" where you want the door to appear and give it a unique tag (for example "SecretDoorTag"). You will find the "Hidden Wall Door Trigger" and "Hidden Trapdoor Trigger" in the standard pallet under "Miscellaneous Interior". Place the trigger object in the center of the desired detection radius.

Next you need to place the waypoint that will act as the door's destination. Place the waypoint at the point where you want the door users to teleport when they go through the door to and give it the same tag as the Hidden Door Trigger object with the prefix "DST_" (for example "DST_SecretDoorTag").

I am referring to the "Hidden Trapdoor Trigger" and the "Hidden Wall Door Trigger" as "trigger objects" to avoid confusion, as they are not technically "triggers". In other words... they are not painted from the "trigger" pallet. They are placed from the "placeable" pallet. They're just called "triggers" in the placeable menu.

Hidden door trigger objects use the "invisible object" appearance. When the door appears it will be facing the same direction as the placeable.

To set the secret door's properties change the following fields:

  • Reflex Save: Determines the distance at which a PC can search for this door in meters.
  • Will Save: Determines the DC of finding this door.

Wall Door Placement Guidelines:
When placing wall doors be careful to place the trigger so when the door spawns it will be flush against the wall. Place the "hidden wall door trigger" so the arrow faces away from the wall and the back edge of the invisible object placeable is flush with the wall.

Wall Doors must be placed where they can be accessed by the players in-game. This can be problematic sometimes. For example, when using the city interior tileset the walkmesh often does not extend all the way to the wall, especially in the alcoves. If you spawn your doors so they appear flush against these walls they will be too far off the walkmesh for the players to fire the "OnUsed" event. A few placeable walls can go a long way towards solving this problem. There's a great selection of placeable walls in the Community Expansion Pack. Also... Door Placables set as "static" objects and placed backwards, with the doors facing the wall, can make a reasonable looking wall placable. As a rule if you cannot click-select the door in the toolset's graphic window it's too far off the walkmesh to be usable by the players.


Changing the Door Spawned by Hidden Door Triggers:
You will need to create a new door blueprint and modify the OnHeartbeat script if you want a door other than the default door to spawn.

Before you ask... No... You cannot use the secret doors under "secret object" in the standard pallet. The OnUsed script is wrong. The door placeables in the "secret object" pallet are for use with the Secret Object Triggers in the standard "Triggers" pallet. Use of these triggers is beyond the scope of this post.

  1. First... create a new blueprint for the door appearance that you want to spawn. For example... the default wall door has a wooden appearance. To create a stone door select the Hidden Wall Door and "Edit Copy". Change the appearance, for example, to "Wall Door Stone". I also like to change the name to "Secret Door" (it just looks cooler than the default name). Make a note of the new placeable resref for the next step, modifying the hidden trigger's OnHeartbeat script.
  2. Now place a Hidden Wall Door Trigger or Hidden Trapdoor Trigger placeable object where you want your custom secret door to spawn.
  3. Copy and Paste the below script into the script editor. Change the area highlighted in red (around line 116) to the resref (not tag) of the placable object that you created in step one. Give your new script a unique name. Now go into the properties of your hidden door trigger and replace the OnHeartbeat script with your new script.
  4. Set the destination waypoint the same way you would if you were using a default door. Just place a waypoint at the point where you want the door users to teleport to and give it the same tag with the prefix "DST_" (for example "DST_SecretDoorTag").
The OnHeartbeat script for your Hidden Door Trigger object:
Copy and paste everything in black. The red font you will replace with the resref of your custom door placeable.

//::///////////////////////////////////////////////
//:: nw_o2_dtwalldoor.nss
//:: Copyright (c) 2001-2 Bioware Corp.
//:://////////////////////////////////////////////
//
// This script runs on either the Hidden Trap Door
// or Hidden Wall Door Trigger invisible objects.
// This script will do a check and see
// if any PC comes within a radius of this Trigger.

// If the PC has the search skill or is an Elf then
// a search check will be made.

// It will create a Trap or Wall door that will have
// its Destination set to a waypoint that has
// a tag of DST_

// The radius is determined by the Reflex saving
// throw of the invisible object

// The DC of the search stored by the Willpower
// saving throw.

//
//:://////////////////////////////////////////////
//:: Created By : Robert Babiak
//:: Created On : June 25, 2002
//::---------------------------------------------
//:: Modifyed By : Robert, Andrew, Derek
//:: Modifyed On : July - September
//:://////////////////////////////////////////////

void main()
{
// get the radius and DC of the secret door.
float fSearchDist = IntToFloat(GetReflexSavingThrow(OBJECT_SELF));
int nDiffaculty = GetWillSavingThrow(OBJECT_SELF);

// what is the tag of this object used in setting the destination
string sTag = GetTag(OBJECT_SELF);

// has it been found?
int nDone = GetLocalInt(OBJECT_SELF,"D_"+sTag);
int nReset = GetLocalInt(OBJECT_SELF,"Reset");

// ok reset the door is destroyed, and the done and reset flas are made 0 again
if (nReset == 1)
{
nDone = 0;
nReset = 0;

SetLocalInt(OBJECT_SELF,"D_"+sTag,nDone);
SetLocalInt(OBJECT_SELF,"Reset",nReset);

object oidDoor= GetLocalObject(OBJECT_SELF,"Door");
if (oidDoor != OBJECT_INVALID)
{
SetPlotFlag(oidDoor,0);
DestroyObject(oidDoor,GetLocalFloat(OBJECT_SELF,"ResetDelay"));
}

}


int nBestSkill = -50;
object oidBestSearcher = OBJECT_INVALID;
int nCount = 1;

// Find the best searcher within the search radius.
object oidNearestCreature = GetNearestCreature(CREATURE_TYPE_PLAYER_CHAR, PLAYER_CHAR_IS_PC);
int nDoneSearch = 0;
int nFoundPCs = 0;

while ((nDone == 0) &&
(nDoneSearch == 0) &&
(oidNearestCreature != OBJECT_INVALID)
)
{
// what is the distance of the PC to the door location
float fDist = GetDistanceBetween(OBJECT_SELF,oidNearestCreature);

if (fDist <= fSearchDist) { int nSkill = GetSkillRank(SKILL_SEARCH,oidNearestCreature); if (nSkill > nBestSkill)
{
nBestSkill = nSkill;
oidBestSearcher = oidNearestCreature;
}
nFoundPCs = nFoundPCs +1;
}
else
{
// If there is no one in the search radius, don't continue to search
// for the best skill.
nDoneSearch = 1;
}
nCount = nCount +1;
oidNearestCreature = GetNearestCreature(CREATURE_TYPE_PLAYER_CHAR, PLAYER_CHAR_IS_PC, OBJECT_SELF ,nCount);
}

if ((nDone == 0) &&
(nFoundPCs != 0) &&
(GetIsObjectValid(oidBestSearcher))
)
{
int nMod = d20();

// did we find it.
if ((nBestSkill +nMod > nDiffaculty))
{
location locLoc = GetLocation (OBJECT_SELF);
object oidDoor;
// yes we found it, now create the appropriate door, EDIT THE LINE BELOW TO CHANGE RESREF OF SPAWNED DOOR
oidDoor = CreateObject(OBJECT_TYPE_PLACEABLE,"NW_PL_HIDDENDR01",locLoc,TRUE);

SetLocalString( oidDoor, "Destination" , "DST_"+sTag );
// make this door as found.
SetLocalInt(OBJECT_SELF,"D_"+sTag,1);
SetPlotFlag(oidDoor,1);
SetLocalObject(OBJECT_SELF,"Door",oidDoor);

} // if skill search found
} // if Object is valid
}







Monday, July 28, 2008

NWN 1.69 is Out

Bioware has just released the last ever patch for Neverwinter Nights 1, and OH WHAT A PATCH! Ridable horses, amazing new tilesets, and outstanding new models. I especially like the new armor models... very western European.

The downside, of course, being that I now need to completely rebuild Rel Mord in the new system.

Sadly I must bid a fond (and hopefully temporary) adieu to the Community Creature Pack.

Picking the CCP creatures out has been a major headache, but it needed to be done anyway as the newer versions were not compatible with the version 4 I was using anyway. I will be re-adding it as soon as it's up to speed with 1.69.

I'll be running out my new mod for NWNCon4.

Wednesday, June 11, 2008

Bad Urk! Bad Bad Urk!

Well, yours truly has been banned by the bioware boards for "Atari Bashing". Not publicly in the forums but privately to the moderators.

Normally I would not air this type of laundry publicly, but now it seems that nobody in the community believes me... so here it is. The entire exchange... complete and unvarnished.

The following messages were logged in that exchange.

================================
Subject: Warning! (R)
From: Selene Moonsong (Add to Buddy List)
Received: Fri, 28 March 2008 04:02PM
Options: Reply | Reply without quote | Forward to my E-mail | Delete


UrKnightErrant

In my opinion, you are attempting to get circumvent the Rules of Conduct and still directly bash Atari. If you have issues with Atari, take them up with Atari, but not in these forums as you have in your last two posts shown below.

Consider this a severe warning since everyone has already been warned twice in this thread , with a reminder of the Rules of Conduct posted by me. Your post has been deleted as per the Rules of Conduct.


As posted by UrKnightErrant:

Quote: Posted 03/28/08 18:02 (GMT) by JBNL

Quote: Posted 03/28/08 17:32 (GMT) by UrKnightErrant

OK... so I'm waiting for a game that's finished because the DRM has not been developed (or tested) yet?

No wonder this game is so buggy.

I feel bad for Ossian. They're a great team of devs that just keeps getting screwed by... those who shall not be named for fear of a thread lock.

:-/

I wish I'd never bought this stupid game.

Now now, this is unfair. Don't blame the developers, who really have done their best on this, for the publisher's mistakes and lack of foresight.

I'm not blaming the devs. Re read the post. Obs and Ossian have done thier jobs. The dark force that must not be named for fear of thread lockage must therefore be...

?

Hint: Rhymes with "Fat Lardy".
_________________
~Selene
Community Member/Moderator
Official Patches
Community Updates

================================
Subject: Re: Warning!
To: Selene Moonsong
Sent: Fri, 28 March 2008 06:45PM
Options: Forward to my E-mail | Delete


Fine. I'm out.

This is why I don't post on the NWN2 boards any more.

You are quite right. I am VERY critical of Atari. I believe that they are milking this franchise into the ground and I find it infuriating.

Atari doesn't need my help to look bad. They do just fine at that all by themselves.

They are mismanaging themselves into the ground. Atari didn't go from like $65.00 a share 5 years ago to todays HIGH of $1.44 because of their astounding foresight and competence. And this AFTER a 10:1 reverse split last year? If you don't know what that means I'll explain it to you... The REAL value of a $65 share of Atari 5 years ago is FOURTEEN CENTS today. There's no nice way to say it. These people are IDIOTS. They shouldn't be running a corner bodega, much less a multi-national corporation.

And now Atari expects me to wait two months or more to buy a finished game which was promised last month so they can bundle in a completely untested software package that will disable the entire application if it doesn't work right?

Now who's being treated with contempt? ME. That's who!

I retreat now back to whence I came... to the NWN1 forums where customer input is welcomed (or at least tolerated), and considered even when it's negative.

================================
Subject: Re: Warning! (R)
From: Selene Moonsong (Add to Buddy List)
Received: Fri, 28 March 2008 07:50PM
Options: Reply | Reply without quote | Forward to my E-mail | Delete


Quote: Sent 03/28/08 23:45 (GMT) by UrKnightErrant

I retreat now back to whence I came... to the NWN1 forums where customer input is welcomed (or at least tolerated), and considered even when it's negative.

I invite you to re-read the Rules of Conduct you agreed to and be advised that those rules apply to the BioBoards, not just NWN 2 and will be enforced when necessary.
_________________
~Selene
Community Member/Moderator
Official Patches
Community Updates


================================
Don't BS me Selene. You want me to stay off your boards, fine, I leave you to your ever diminishing support base of sycophants and fan-boys. But we both know that Bio doesn't use the TOS the way Obs does.

I know the rules of conduct. I did not spam, slander, flame, stray off topic, telephone, impersonate, fight (I was in fact agreeing with the tone of the thread), or promote any illegal topics.

I did lay in a backhanded dig on you mods for being lock-happy. Maybe that's what really pissed you off, I don't know. Don't really care.

And I've been on these forums for 8 years. I only changed handles because I lost access to my old Email account when I moved last year.

Bio doesn't lock threads because they or their bosses are getting razzed. Case in point...
Click Here

11 pages. No lock. SCATHING criticisms of EA and Bioware.

That's how you handle angry customers. You let them say what they need to say, and you either help them or stay out of their way. You don't fan their anger by bullying them into silence.


================================
Subject: Banned (R)
From: Chris Priestly (Add to Buddy List)
Received: Sat, 29 March 2008 10:53PM
Options: Reply | Reply without quote | Forward to my E-mail | Delete


Since you asked to be banned, you are gone from these pages.

If you want to come back, you can ask me to allow you to return.

_____________________
Subject: Re: Banned
To: Chris Priestly
Sent: Sun, 30 March 2008 11:24AM
Options: Forward to my E-mail | Delete


Who am I? Oliver ***ing Twist? I quite willingly volunteered to stay off your boards.

Atari is the most pathetic excuse for a game publisher in business today, and if they were based out of any country but japan they'd have gone out of business years ago. Sooner or later the japanese government is going to get tired of carrying them and that's going to be that.

That's not "Atari Bashing". That's called "reading a financial report".

Like I said in my post...
I wish I had never bought NWN2. As much as I want to support my beloved D&D franchise, my NWN2 experience has been a long, drawn out MISERY. I believe that Obs and Ossian have done the best they can do. I blame Atari.

This is not "Atari Bashing". This is how I feel. That this is unspeakable on your boards says volumes... but the only message that matters is, "Fan-Boys Only."

Atari is in such a hurry to produce salable content to shore up their ridiculously low bottom line that they are releasing buggy games and failing to provide the devs with the zots needed to patch them. You know it. I Know it. Everyone in the industry knows it.

Now... In the Game Publisher equivalent of "Jumping the Shark" they have convinced themselves that if they can just stop the evil pirates from stealing their games their problems will be solved and they will be magically transported back into the black.

Like I said. Pathetic.

This strategy will fail. It always does. Some pimple faced german kid will crack the game in a week, and their new DRM software, not properly tesated on the thousands of possible hardware/software configurations, will cause the application to fail on hundreds if not thousands of machines. This will piss off tjousands of paying customers, while thousands of game pirates fail to run out and buy the game.

Atari will do what it always does... ignore the problem in favor of devloping more salable content.

No doubt you will then have to ban more angry customers from their boards.

Then Atari will find itself right back where it started... A failed business with incompetent officers and a self destructive corporate culture.

You offer two choices.

1) Fall in lock step and march joyfully in lock step to our party line.

2) *** and get out of here.

I choose option 3.


================================
Subject: Re: Banned (R)
From: Chris Priestly (Add to Buddy List)
Received: Sun, 30 March 2008 11:48AM
Options: Reply | Reply without quote | Forward to my E-mail | Delete


Well, I think it is a shame you feel that way since you were a great NwN1 advocate and a long time supported or NwN1. You could have voluntarily stayed off of the Neverwinter Nights 2 forums and refrained from bashing them on the NwN1 boards and simply enjoyed the NwN 1 games and fan content and waited until our next games, like Dragon Age came out and then enjoyed those.

However, since you feel you cannot be a part of this community and NOT bash Atari (and there are a great many peopel who are forumites where who have zero interest in Atari or NwN2 in any way), then your account remains banned.

Hopefully, someday, you will realize there is more to this community than Atari and again choose to take part in it.


================================
Subject: Re: Banned
To: Chris Priestly
Sent: Sun, 30 March 2008 02:15PM
Options: Forward to my E-mail | Delete


Like I said.

"Fan Boys Only"

Got it. Enjoy your little circle jerk.

-Urk

Thursday, May 8, 2008


Well, I've made it into the Neverwinter Connection's DM Hall of Fame. Special thanks to all my players, especially Dave_O who would rather run his foot over with a car than forget to review me, and has me on his favorites list like 3 times!!!

We'll be moving our Neverwinter Nights game night to Mondays from now on. I'm always looking for Noobies to join our merry band, so if you would like to join us for some vicarious high adventure please, set yourself up with an account at www.neverwinterconnections.com and PM me. My handle there is "Urk".

Saturday, May 3, 2008

The Real Thing

My wife and I are moving to New Orleans in the not too distant future, and while driving home from an appointment to view a potential apartment my lovely wife allowed me to stop and explore the Battleship Memorial Park in Mobile. Foolishly I told her I'd be back in a half hour, then dashed from one side of the museum to the other furiously clicking away at everything I could find. An hour later she crossly pulled up next to me as I was snapping quarter bow shots of the Gato Class sub USS Drum.

I'll recommend some good WWII naval warfare games in the not-to-distant future, but this experience was the real thing, so sorry folks... no game talk today.

The star of the park is the battleship Alabama.

Designated BB-60 she's a South Dakota Class Battleship. Launched in 1942 she served in the South Pacific theater of operations. She was nicknamed the "Lucky A". During her active service not a single crewman was killed in enemy action.

The Battleship was the largest most sophisticated machine of that era. All due respect to the devotees of Aircraft Carriers, the floating flat-topped buckets of WWII pale in comparison to the floating fortress of the BB: 2500 highly trained men integrated with the same clockwork precision of the CV crew into a single machine with a single function...

Destroy anything in sight.

And it was very good at it's job.

Lucky-A's armament would still strike fear into any foe not equipped with a state of the art guided missile system. Truth be told, most of today's anti ship missiles would be hard pressed to penetrate her foot thick armor plating. Mind you, if ships like this were still on the line that wouldn't be the case. These behemoths no longer have a place in the modern navy, but as recently as 1992 they served with distinction.


Shown here are 2 of Alabama's 10 Double 5" Gun turrets. Secondary weapons, any destroyer or submarine foolish enough to blunder into range of one of these batteries broadside would not likely live long enough to abandon ship. In the foreground you can see 2 of her 12 40mm Anti-Aircraft Auto Cannons.


The main armaments of the Alabama were 9 16 inch guns organized into 3 turrets, 2 mounted on the foreward deck, and one aft.


These guns were able to launch steel shells packed with explosives a little over 23 miles. Each shell weighs about as much as a Volkswagon bus.


On the aft deck you can see the catapult rail that would be used to launch one of Alabama's 2 OS2U Kingfisher Scout planes (pictured below) right off the deck. These planes would be used to scout the surrounding waters for enemy forces. The crane was used to recover the aircraft once they had landed in the water. Also seen here are 3 of Lucky-A's 52 20mm Machine Guns for use against enemy aircraft.


It was sad to see the condition of the old girl. She needs a face lift in the worst way.

The steel structure is in excellent shape, almost timeless, and the three degree list that is apparently left from Katrina is not even noticeable. But the wooden decks need to be completely replaced. The once polished teak is now gray and warped.

Most infuriating, however, is the thin layer of paint on the starboard side barely managing to conceal years of graffiti.


Sadder still was the condition of the Drum. Damaged in hurricane George she is now consigned to living the rest of her days mounted on blocks, her tail section a frayed and rusted out tangle of steel.

Many of the aircraft in the museum's collection are piled next to her, likewise twisted and mangled by storm damage.

But the saddest blow is the Vietnam Veterans memorial. The Huey, the foot soldiers angel of mercy in that conflict, was once mounted over the Vietnam Veterans Memorial in eternal flight. Now it is gone, leaving only the skids freakishly suspended in the air over the rest of the sculpture.


Then I reminded myself that God did this. He reached down from heaven and swatted down that Huey. And it is God's contribution to this memorial that makes the starkest and most important statement of all. Have we done with the veteran's of that war exactly what we have done to their memorial? Have we left them underfunded and neglected? Have we let our shame of defeat and unwillingness to admit our own fallibility obscure the contribution these men made to our country and our culture, many with their lives?

To me that missing helicopter is a challenge to put up or shut up. It is a divine reminder that not all heroes fight and win. Sometimes all a man can do is fight and die.

I cannot recommend strongly enough a visit to this place. You have the opportunity to explore a battleship stem to stern. Take the whole day. You won't regret it.

And leave a few extra dollars in the collection jar at the ticket desk. Let's get that Huey put back up.

Thursday, April 24, 2008

Hail The Hamster!

It's been about a year since I last logged into The Fantastically adequate Hamster Republic Home Page.

This is more than the home of Jame's Page's OHRRPGCE, it is also, I suspect, a clever reference to Boo the Space Hamster.

OHRRPGCE is an old school CRPG engine. Remember Final Fantasy 2? It could be easily reproduced using the OHRRPGCE (Short for Official Hamster Republic Role Playing Game Creation Engine). The system is VERY flexible, though. I'm using it to build a Star Trek Game that will likely never be finished but has allowed me to explore the system. A good stable core system supported by Hamster Speak, a powerful yet ridiculously simple scripting language.

I was surprised to find an updated released as recently as January. No longer a DOS system the system is now Windows Based, and is capable of supporting better sound, better graphics, and larger files. The only downside I can see is that the system can no longer build self executable games. An OHRRPGCE game file can only be played with a full install of the engine.

Saturday, April 19, 2008

Alcohol Anonymous

The Event with Skunkeen last Saturday was a success, but a less than stellar one.

The module, Alcohol Anonymous, was a very clever one. The build was amateurish and entirely Dependant on DM participation, but the plot and NPCs were amusing and the whole game had a very survival-horror feel, which is... to say the least... right up my alley.

This event was intended for aspiring DMs. As PCs died (and oh how horribly they died) they were given DM passwords and we taught them tricks of the trade as the adventure progressed. After the adventure the survivors also logged on as DMs and we began a question and answer session on how to use the DM client.

Now as a rule I run Open events. No passwords or anything. I'm always happy to field new players, or shall I say, I USED TO BE happy to field new players.

One of our invited players was running X-Fire during the game, and while we were playing an X-Fire Griefer calling himself RagdollKnight piggybacked in.

I've been running events on Neverwinter Connections for about a year, and in all those games... say 20 or more... I've yet to run into a griefer.

So this guy starts wreaking all the havok that a DM can Wreak, and a DM can wreak a lott of havok. He basically ruined the question and answer session.

I wasn't running a dedicated server, so it forced a server reboot and password change to boot him off. Very frustrating.

What is is with Griefers? I simply do not understand the mindset that ruining other peoples experience is somehow intrinsically fun. It seems even more pitiful than it is aggravating. Is your life so empty? Are you so small and useless in RL that you can only assert yourself by being a bully in cyberspace? I shall ask my wife about it. She's a doctoral candidate working on her degree in Psychology.

Anyway... Many thanks to Skunkeen for the event. We'll do it again... but next time it will be a password protected application only event on a dedicated server.