Uhhh... What happened to A_CustomMissile?
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!)
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!)
-
- Posts: 379
- Joined: Tue Dec 20, 2016 4:53 pm
- Location: MURICAA BROTHER! Just kidding, Brazil.
Uhhh... What happened to A_CustomMissile?
I haven't making decorate for some GOOD time. I just dowloaded slade again and it looks different, more organized. Anyways i tried to use A_CustomMissile, but the monster doens't turn at me like it used to do. So i checked to see if i did anything wrong, and APPARENTLY they are now using A_SpawnProjectile instead of custom missile. The problem IS because "A_SpawnProjectile" Doens't have the color orange on Slade which means it's not a function. Can someone explains me WHY they changed it, why on MY slade it's ins't showing orange, and why A_CustomMissile is not making my monster turns at me. Thank you!
-
- Posts: 21706
- Joined: Tue Jul 15, 2003 7:33 pm
- Preferred Pronouns: He/Him
- Operating System Version (Optional): A lot of them
- Graphics Processor: Not Listed
Re: Uhhh... What happened to A_CustomMissile?
Are you forgetting to A_FaceTarget?
-
- Posts: 379
- Joined: Tue Dec 20, 2016 4:53 pm
- Location: MURICAA BROTHER! Just kidding, Brazil.
Re: Uhhh... What happened to A_CustomMissile?
No. the attack i made is a continous ray. Here is the script for it:wildweasel wrote:Are you forgetting to A_FaceTarget?
Code: Select all
SoulBeamAttack:
ZUNM EFEFEFEFEFEFEF 3 A_FaceTarget
ZUNM E 6 A_PlaySound("grunt/sight")
TNT1 A 0 A_Playsound("zombie/beamattack")
ZUNM F 1 A_FaceTarget
ZUNM FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF 2 A_CustomMissile("SoulBeam", 32, -7)
ZUNM A 15 A_FaceTarget
Goto See
-
- Posts: 469
- Joined: Sat Apr 16, 2016 6:01 am
- Preferred Pronouns: She/Her
Re: Uhhh... What happened to A_CustomMissile?
That's not true at all. SLADE's list of functions is nowhere near extensive and it's missing a lot of them from the syntax highlighting. You can still use the function, you just won't get a handy list of arguments.XASSASSINX wrote:and APPARENTLY they are now using A_SpawnProjectile instead of custom missile. The problem IS because "A_SpawnProjectile" Doens't have the color orange on Slade which means it's not a function.
-
- Posts: 379
- Joined: Tue Dec 20, 2016 4:53 pm
- Location: MURICAA BROTHER! Just kidding, Brazil.
Re: Uhhh... What happened to A_CustomMissile?
Ohhhh... I get it now. Also just fixed the bug, i have to put "A_FaceTarget" TO ALL the frames. That add ALOT of lines. But i do remember that A_CustoMissile ALready made the monster face it target. Or i'm just crazy.
-
- Posts: 2254
- Joined: Mon Jan 06, 2014 11:32 pm
Re: Uhhh... What happened to A_CustomMissile?
Something else sounds wrong here. It should still stay facing the target until the state completes correct?
-
- Posts: 9696
- Joined: Sun Jan 04, 2004 5:37 pm
- Preferred Pronouns: They/Them
- Operating System Version (Optional): Debian Bullseye
- Location: Gotham City SAR, Wyld-Lands of the Lotus People, Dominionist PetroConfederacy of Saudi Canadia
Re: Uhhh... What happened to A_CustomMissile?
I just remember A_CustomMissile would shoot at the target, but I don't remember if it made the actor face the target too.
-
- Lead GZDoom+Raze Developer
- Posts: 49142
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
Re: Uhhh... What happened to A_CustomMissile?
Why should it? Its name is A_CustomMissile, not A_CustomMissileAndFaceTarget.
-
- Posts: 379
- Joined: Tue Dec 20, 2016 4:53 pm
- Location: MURICAA BROTHER! Just kidding, Brazil.
Re: Uhhh... What happened to A_CustomMissile?
So i guess it faced the target because i put the "A_FaceTarget" One line before. But in this continous lines, i have to put "A_FaceTarget" for all of them.Graf Zahl wrote:Why should it? Its name is A_CustomMissile, not A_CustomMissileAndFaceTarget.
-
- Lead GZDoom+Raze Developer
- Posts: 49142
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
Re: Uhhh... What happened to A_CustomMissile?
So?
In ZScript you can just define your own function for such a combined action - there's no need to add it on the engine side.
In ZScript you can just define your own function for such a combined action - there's no need to add it on the engine side.
-
- Posts: 7402
- Joined: Fri Oct 22, 2004 9:22 am
- Graphics Processor: nVidia with Vulkan support
- Location: MAP33
Re: Uhhh... What happened to A_CustomMissile?
You don't even need to use ZScript, thanks to the magic and wonder of Anonymous Functions.
Code: Select all
SoulBeamAttack:
ZUNM EFEFEFEFEFEFEF 3 A_FaceTarget
ZUNM E 6 A_PlaySound("grunt/sight")
TNT1 A 0 A_Playsound("zombie/beamattack")
ZUNM F 1 A_FaceTarget
ZUNM FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF 2 { A_FaceTarget(); A_CustomMissile("SoulBeam", 32, -7); }
ZUNM A 15 A_FaceTarget
Goto See
-
- Posts: 379
- Joined: Tue Dec 20, 2016 4:53 pm
- Location: MURICAA BROTHER! Just kidding, Brazil.
Re: Uhhh... What happened to A_CustomMissile?
Ohhhh... Didn't know about that! Thanks!Kinsie wrote:You don't even need to use ZScript, thanks to the magic and wonder of Anonymous Functions.
Code: Select all
SoulBeamAttack: ZUNM EFEFEFEFEFEFEF 3 A_FaceTarget ZUNM E 6 A_PlaySound("grunt/sight") TNT1 A 0 A_Playsound("zombie/beamattack") ZUNM F 1 A_FaceTarget ZUNM FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF 2 { A_FaceTarget(); A_CustomMissile("SoulBeam", 32, -7); } ZUNM A 15 A_FaceTarget Goto See
EDIT: No Wait! Hold on, i tried using the {A_FaceTarget} But now it's giving me an error!
Code: Select all
"Unexpected Token: ')'
EDIT 3: (Woah that's alot of edits) Nope. Tried to play my mod now with this version. Still getting the same error.
-
- Posts: 9696
- Joined: Sun Jan 04, 2004 5:37 pm
- Preferred Pronouns: They/Them
- Operating System Version (Optional): Debian Bullseye
- Location: Gotham City SAR, Wyld-Lands of the Lotus People, Dominionist PetroConfederacy of Saudi Canadia
Re: Uhhh... What happened to A_CustomMissile?
Impossible to see what went wrong without seeing the entire project.
-
- Posts: 1606
- Joined: Mon Jun 12, 2017 12:57 am
Re: Uhhh... What happened to A_CustomMissile?
You need and must must use semicolon ";" after last symbol of function inside anonimous function, regardless what it, letter of the name or bracket which close line of argument function.XASSASSINX wrote: i tried using the {A_FaceTarget}
-
- Posts: 8193
- Joined: Sun Jan 28, 2007 3:55 pm
- Preferred Pronouns: He/Him
- Location: QZDoom Maintenance Team
Re: Uhhh... What happened to A_CustomMissile?
He has a semicolon. The real problem is, it's in DECORATE which doesn't know how to handle () properly.
In ZScript you use this
In DECORATE however, you must use this:
In ZScript you use this
Code: Select all
A_FaceTarget();
Code: Select all
A_FaceTarget;