The following warnings occurred:
Warning [2] count(): Parameter must be an array or an object that implements Countable - Line: 906 - File: showthread.php PHP 7.2.24-0ubuntu0.18.04.17 (Linux)
File Line Function
/showthread.php 906 errorHandler->error



Facebook Twitter YouTube Frictional Games | Forum | Privacy Policy | Dev Blog | Dev Wiki | Support | Gametee


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Script Help One script for multiple similar functions
Shadowfied Offline
Senior Member

Posts: 261
Threads: 34
Joined: Jul 2010
Reputation: 5
#1
One script for multiple similar functions

In my custom story there's a place where you get a key which can, or will be able to open a lot of doors. I know there are ways to make a script like this one from White Night, used for the light switches:

void Lamp_Switcher(string &in asEntity, int alState)

{

if( alState == -1)

SetLampLit("swithcher_1_"+StringSub(asEntity,10,11), false, true);

if( alState == 1)

SetLampLit("swithcher_1_"+StringSub(asEntity,10,11), true, true);

}

I have about 10 doors called "cell_1" and up, can I somehow make a similar script so that I don't have to make individual parts of script for each door?

Thanks in advance.

Current - Castle Darkuan
Other - F*cked Map
02-13-2012, 09:40 AM
Find


Messages In This Thread
One script for multiple similar functions - by Shadowfied - 02-13-2012, 09:40 AM



Users browsing this thread: 1 Guest(s)