Visit the Ironworks Gaming Website Email the Webmaster Graphics Library Rules and Regulations Help Support Ironworks Forum with a Donation to Keep us Online - We rely totally on Donations from members Donation goal Meter

Ironworks Gaming Radio

Ironworks Gaming Forum

Go Back   Ironworks Gaming Forum > Ironworks Gaming Forums > Neverwinter Nights 1 & 2 Also SoU & HotU Forum
FAQ Calendar Arcade Today's Posts Search

Reply
 
Thread Tools Search this Thread
Old 08-25-2005, 10:26 AM   #1
lost prophet
Drow Warrior
 

Join Date: October 23, 2004
Location: Perth, Western Australia, Australia
Age: 33
Posts: 297
having a bit of trouble makeing a few things work on the toolset and was wondering if anyone could help me.

1. I am trying to set up a portal from one level to another and i cant seem to get it to work. Ive got Lilacs script generator and when i put in all the commands and it generates the script it looks something like this:

//Put this OnUsed
void main()
{

object oPC = GetLastUsedBy();

if (!GetIsPC(oPC)) return;

object oTarget;
location lTarget;
oTarget = GetWaypointByTag("pt_warkarea");

lTarget = GetLocation(oTarget);

//only do the jump if the location is valid.
//though not flawless, we just check if it is in a valid area.
//the script will stop if the location isn't valid - meaning that
//nothing put after the teleport will fire either.
//the current location won't be stored, either

if (GetAreaFromLocation(lTarget)==OBJECT_INVALID) return;

SetLocalLocation(oPC, "ls_stored_loc", GetLocation(oPC));

AssignCommand(oPC, ClearAllActions());

DelayCommand(3.0, AssignCommand(oPC, ActionJumpToLocation(lTarget)));

oTarget = oPC;

//Visual effects can't be applied to waypoints, so if it is a WP
//apply to the WP's location instead

int nInt;
nInt = GetObjectType(oTarget);

if (nInt != OBJECT_TYPE_WAYPOINT) ApplyEffectToObject(DURATION_TYPE_INSTANT, EffectVisualEffect(VFX_IMP_UNSUMMON), oTarget);
else ApplyEffectAtLocation(DURATION_TYPE_INSTANT, EffectVisualEffect(VFX_IMP_UNSUMMON), GetLocation(oTarget));

}

When i compile it on the toolset it says that it has no problems, but when i go ingame and attept to use the portal nothing happens lol, does anyone know where it went wrong ( by the way "pt_workarea" is the tag of the portal i wont the first one to connect to. i dont have any script on the second portal. )

2. when i place a trap and go ingame to try and test it out the effect doesnt work. for example i have a IGMS trap with the polygon set out on my mod and all, but when i trip it ingame the "trap triggered" notice comes up above my pc's head but nothing else happens. do i need to place some "when a pc enters a location" script in its properties?

dont you hate it when you feel like an idiot

cheers.
__________________
I have a dream, we all have dreams.
lost prophet is offline   Reply With Quote
Old 08-25-2005, 12:38 PM   #2
Chewbacca
Zartan
 

Join Date: July 18, 2001
Location: America, On The Beautiful Earth
Age: 50
Posts: 5,373
This typo ( in bold) on around line 10 could be the culprit in your script:

oTarget = GetWaypointByTag("pt_warkarea");
__________________
Support Local Music and Record Stores!
Got Liberty?
Chewbacca is offline   Reply With Quote
Old 08-25-2005, 01:11 PM   #3
lost prophet
Drow Warrior
 

Join Date: October 23, 2004
Location: Perth, Western Australia, Australia
Age: 33
Posts: 297
it is actually sposed to be "pt_workarea" ( typo on my behalf ) and ive changed that ingame so it matches with the tag of the destinatin portal. still doesnt work
__________________
I have a dream, we all have dreams.
lost prophet is offline   Reply With Quote
Old 08-25-2005, 01:28 PM   #4
Chewbacca
Zartan
 

Join Date: July 18, 2001
Location: America, On The Beautiful Earth
Age: 50
Posts: 5,373
Hmmm, okay the typo was the most obvious problem.

I use an almost identical script in the character maker to return from the arenas to the main area. I don't see a problem with the script so I assume there is a tag issue somewhere.

Other things to try are shortening the delay from 3.0 to 1.0 and double-check the placeable portal is set to useable but not having inventory.

BTW here is the script I compared with yours:

/* Script generated by
Lilac Soul's NWN Script Generator, v. 1.5

For download info, please visit:
http://www.lilacsoul.revility.com */

//Put this OnUsed
void main()
{

object oPC = GetLastUsedBy();

if (!GetIsPC(oPC)) return;

object oTarget;
location lTarget;
oTarget = GetWaypointByTag("WP_UD_ArenaReturn");

lTarget = GetLocation(oTarget);

//only do the jump if the location is valid.
//though not flawless, we just check if it is in a valid area.
//the script will stop if the location isn't valid - meaning that
//nothing put after the teleport will fire either.
//the current location won't be stored, either

if (GetAreaFromLocation(lTarget)==OBJECT_INVALID) return;

AssignCommand(oPC, ClearAllActions());

DelayCommand(1.0, AssignCommand(oPC, ActionJumpToLocation(lTarget)));

oTarget = oPC;

//Visual effects can't be applied to waypoints, so if it is a WP
//apply to the WP's location instead

int nInt;
nInt = GetObjectType(oTarget);

if (nInt != OBJECT_TYPE_WAYPOINT) ApplyEffectToObject(DURATION_TYPE_INSTANT, EffectVisualEffect(VFX_IMP_UNSUMMON), oTarget);
else ApplyEffectAtLocation(DURATION_TYPE_INSTANT, EffectVisualEffect(VFX_IMP_UNSUMMON), GetLocation(oTarget));

}


__________________
Support Local Music and Record Stores!
Got Liberty?
Chewbacca is offline   Reply With Quote
Old 08-25-2005, 03:23 PM   #5
lost prophet
Drow Warrior
 

Join Date: October 23, 2004
Location: Perth, Western Australia, Australia
Age: 33
Posts: 297
Fixed it. after much head banging i realised that the toolset looks for a waypoint with the tag "pt_workarea" and i had put that tag on the portal i wished to teleport to thiking that it would work the same, however it wouldnt. In the end i created a waypoint directly over the portal and adjusted the waypoint accordingly and it worked.

thanks Chewy for your help... in the end it was my lack of proper reading that stuffed me up.
__________________
I have a dream, we all have dreams.
lost prophet is offline   Reply With Quote
Old 08-25-2005, 03:25 PM   #6
Legolas
Jack Burton
 

Join Date: March 31, 2001
Location: The zephyr lands beneath the brine.
Age: 39
Posts: 5,459
I ran your original script myself and it worked for me, with of course one minor bug. If you move between clicking the portal and being teleported you cancel the teleportation action. The visual effect remains, however.
Solve that by disabling player commandability for the 3 second duration, for example.

Since the script was otherwise just fine, the problem must be one of the following:
- Your portal is not useable or not present
- Your portal's OnUsed script is not this script or missing completely
- Your waypoint tag is not pt_workarea or pt_workarea, or there is no waypoint. Note that using upper or lower case letters does make a difference.
In any event, the flaw is not in the code itself.

EDIT: Nevermind, you're done already [img]smile.gif[/img]

[ 08-25-2005, 03:26 PM: Message edited by: Legolas ]
Legolas is offline   Reply With Quote
Old 08-25-2005, 03:43 PM   #7
Chewbacca
Zartan
 

Join Date: July 18, 2001
Location: America, On The Beautiful Earth
Age: 50
Posts: 5,373
Quote:
Originally posted by lost prophet:
Fixed it. after much head banging i realised that the toolset looks for a waypoint with the tag "pt_workarea" and i had put that tag on the portal i wished to teleport to thiking that it would work the same, however it wouldnt. In the end i created a waypoint directly over the portal and adjusted the waypoint accordingly and it worked.

thanks Chewy for your help... in the end it was my lack of proper reading that stuffed me up.
You are welcome. Glad you got it working. [img]smile.gif[/img]
__________________
Support Local Music and Record Stores!
Got Liberty?
Chewbacca is offline   Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is On

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Probs with XP Walks Wizards & Warriors Forum 24 05-29-2004 09:45 PM
Solved some probs, now NEW probs :( Taski Wizards & Warriors Forum 4 01-02-2003 07:35 AM
Com probs Merlin Al'Thor Baldurs Gate & Tales of the Sword Coast 1 08-30-2002 07:16 AM
tech probs tflyt Baldurs Gate II Archives 3 11-17-2001 10:47 PM
never short of probs Trigovudd T'halimund Baldurs Gate II: Shadows of Amn & Throne of Bhaal 1 07-25-2001 08:16 AM


All times are GMT -4. The time now is 05:54 AM.


Powered by vBulletin® Version 3.8.3
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
©2024 Ironworks Gaming & ©2024 The Great Escape Studios TM - All Rights Reserved