lfnetwork.com mark read register faq members calendar

Thread: Door Scripting
Thread Tools Display Modes
Post a new thread. Add a reply to this thread. Indicate all threads in this forum as read. Subscribe to this forum. RSS feed: this forum RSS feed: all forums
Old 11-27-2006, 09:12 PM   #1
CalcProgrammer1
Rookie
 
CalcProgrammer1's Avatar
 
Join Date: Jul 2006
Posts: 91
Door Scripting

Is there a way to make a script for rotating doors that can be used for more than just one door or door set? I tried to set the target of the affect to get the parm1 of the entity. In the target_scriptrunner entity i set parm1 to "door" (which is the script_targetname the func_static entity of the door with a origin brush for its hinge). The script looks like this


Code:
do ( "opendoor" );
wait ( $get( FLOAT, "SET_PARM3")$ );
do ( "closedoor" );

task ( "opendoor" )
{

   affect ( $get( STRING, "SET_PARM1")$, /*@AFFECT_TYPE*/ INSERT )
   {
      rotate ( $get( VECTOR, "SET_PARM4")$, $get( FLOAT, "SET_PARM2")$ );
   }

}


task ( "closedoor" )
{

   affect ( $get( STRING, "SET_PARM1")$, /*@AFFECT_TYPE*/ INSERT )
   {
      rotate ( < 0.000 0.000 0.000 >, $get( FLOAT, "SET_PARM2")$ );
   }

}

(this was copied from the .txt, it was created in behavEd)
When I run the game, this version crashes it, previous versions showed an "affect" in the debugger but the door never was affect-ed...
Is it even possible to use parms as entity names, or do you have to hard code that into the script?


CalcProgrammer1 is offline   you may: quote & reply,
Old 12-03-2006, 04:39 PM   #2
Gug Eyewalker
 
Gug Eyewalker's Avatar
 
Join Date: Nov 2000
Posts: 74
So you are trying to create multiple rotating doors that activate on command?

Why couldnt you just create a func_rotating for each door that is activated on a trigger, or set as usable?
Or maybe if you want all the doors to activate at once link them all to one trigger? Am I understanding u?


We are the music makers, and WE are the dreamers of the dream. -Willie Wonka
Gug Eyewalker is offline   you may: quote & reply,
Old 12-04-2006, 04:08 PM   #3
CalcProgrammer1
Rookie
 
CalcProgrammer1's Avatar
 
Join Date: Jul 2006
Posts: 91
func_rotating's can't be moved to specific points and stopped, the script is to make a door that swings open and closed, using the rotate() command. A func_rotating would just spin in a fixed direction in a circle until targeted, then it would stop, and when targeted again, start in the same direction. It will not work for a hinged door.


CalcProgrammer1 is offline   you may: quote & reply,
Post a new thread. Add a reply to this thread. Indicate all threads in this forum as read. Subscribe to this forum. RSS feed: this forum RSS feed: all forums
Go Back   LucasForums > Network > JediKnight Series > Editing Central > JA Mapping > Door Scripting

Thread Tools
Display Modes

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 Off
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 01:58 AM.

LFNetwork, LLC ©2002-2011 - All rights reserved.
Powered by vBulletin®
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.