Page 1 of 1
A_AttachLight is causing a problem
Posted: Sat May 04, 2024 2:32 pm
by SPZ1
Something is wrong with this A_AttachLight?
Code: Select all
ACTOR Stone_Arrow_Floor_Invisible 20045 {
Scale 3.0
Radius 2
Height 6
Alpha 0.0
RenderStyle "Translucent"
+BRIGHT
//+DORMANT
+ISMONSTER
States {
Spawn:
EMPT AAAAAAAAAA 12 A_FadeIn(0.1)
EMPT A 0 A_SetRenderStyle(1.0, STYLE_Normal)
EMPT A 15 A_AttachLight("FloorArrowLight01", DynamicLight.PointLight, "Blue", 96, 96, DYNAMICLIGHT.LF_DONTLIGHTSELF)
EMPT A -1
Stop
}
}
Code: Select all
Execution could not continue.
Script error, "DECORATE.lmp:decorate.lmp" line 27155:
Expected ',', got '.'.
Re: A_AttachLight is causing a problem
Posted: Wed May 15, 2024 5:55 am
by metalx1000
Could it possibly be because
Note: this function is not fully supported by DECORATE.
If used from DECORATE, all parameters starting from ofs should be omitted.
Consider switching to ZScript to fully utilize this function.
https://zdoom.org/wiki/A_AttachLight
I have not used the A_AttachLight function myself, but I saw this message we'll looking into your problem and thought it might be the issue.
Re: A_AttachLight is causing a problem
Posted: Thu May 16, 2024 11:30 pm
by ramon.dexter
Just one simple question: why do you insist on using decorate, when programmer like you has obviosly no problem with zscript? Just write it directly in zscript and completely forget decorate and many of problems will be gone...
Re: A_AttachLight is causing a problem
Posted: Fri May 17, 2024 2:48 pm
by SPZ1
If used from DECORATE, all parameters starting from ofs should be omitted.
All parameters from
ofs are omitted.
Just one simple question: why do you insist on using decorate
Well for one... DECORATE allows me to use Map Editor Numbers and SpawnIDs. I use it to split my simpler things from my more complicated ones. I don't think this bug should exist because there is a newer way that allows things to be broken.

Re: A_AttachLight is causing a problem
Posted: Fri May 17, 2024 7:46 pm
by Blue Shadow
DECORATE doesn't support the
<classname>.<constant> syntax. To solve this, either switch to ZScript, or, if you must stay with DECORATE, replace
DynamicLight.PointLight with 0, and
DYNAMICLIGHT.LF_DONTLIGHTSELF with 4.
You can find those DynamicLight constants
here.
SPZ1 wrote: ↑Fri May 17, 2024 2:48 pm
Well for one... DECORATE allows me to use Map Editor Numbers and SpawnIDs
You assign those in MAPINFO nowadays, be it for DECORATE or ZScript.
https://zdoom.org/wiki/MAPINFO/Editor_number_definition
https://zdoom.org/wiki/MAPINFO/Spawn_number_definition
Re: A_AttachLight is causing a problem
Posted: Sun May 19, 2024 8:16 am
by SPZ1
Thank you for pointing me in the right direction
