Script Open

Ask about ACS, DECORATE, ZScript, or any other scripting questions here!

Moderator: GZDoom Developers

Forum rules
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. If you still don't understand how to use a feature, then ask here.

Please bear in mind that the people helping you do not automatically know how much you know. You may be asked to upload your project file to look at. Don't be afraid to ask questions about what things mean, but also please be patient with the people trying to help you. (And helpers, please be patient with the person you're trying to help!)
Dudweiser
Posts: 60
Joined: Mon Jan 08, 2018 5:54 pm

Script Open

Post by Dudweiser »

When trying to use an Enter or Open script I get a red (!) and an error message. Script works perfect using Void. Any ideas why?

This is using the GZ Doom Builder script editor.

Code: Select all

script 2 (open)
{	
	Thing_SpawnFacing(2000, 30002, false, 0);
}
User avatar
Arctangent
Posts: 1235
Joined: Thu Nov 06, 2014 1:53 pm

Re: Script Open

Post by Arctangent »

That's not an OPEN script. That's a untyped script that's trying to define an argument attached the variable open, but since there's no variable type before the variable name it ends up trying to define a nameless variable of type open, which is complete nonsense to the interpreter.

Remove the parenthesis; those are used to define arguments, which are completely irrelevant to OPEN scripts.
Dudweiser
Posts: 60
Joined: Mon Jan 08, 2018 5:54 pm

Re: Script Open

Post by Dudweiser »

Thanks buddy

Return to “Scripting”