Expose A_SpawnProjectile/A_CustomComboAttack/etc to ZSC

Post a reply

Smilies
:D :) :( :o :shock: :? 8-) :lol: :x :P :oops: :cry: :evil: :twisted: :roll: :wink: :geek: :ugeek: :!: :?: :idea: :arrow: :| :mrgreen: :3: :wub: >:( :blergh:
View more smilies

BBCode is ON
[img] is OFF
[url] is ON
Smilies are ON

Topic review
   

Expand view Topic review: Expose A_SpawnProjectile/A_CustomComboAttack/etc to ZSC

Re: Expose A_SpawnProjectile/A_CustomComboAttack/etc to ZSC

by Major Cooke » Sat Dec 29, 2018 2:01 pm

Agreed, I will do everything that is simpler first. I'm not ready to take on the bigger stuff.

Re: Expose A_SpawnProjectile/A_CustomComboAttack/etc to ZSC

by Graf Zahl » Sat Dec 29, 2018 1:46 pm

Most likely. If you want to take a shot, pick the simpler stuff first.

Re: Expose A_SpawnProjectile/A_CustomComboAttack/etc to ZSC

by Major Cooke » Sat Dec 29, 2018 1:22 pm

A_CheckLOF too?

Re: Expose A_SpawnProjectile/A_CustomComboAttack/etc to ZSC

by Graf Zahl » Sat Dec 29, 2018 12:38 pm

A_RadiusGive for sure. In general, anything that looks like it is expensive.

Re: Expose A_SpawnProjectile/A_CustomComboAttack/etc to ZSC

by Major Cooke » Sat Dec 29, 2018 12:26 pm

Graf Zahl wrote:Can you help? The long term plan is to scriptify the entirety of p_actionfunctions.cpp (minus a few where performance really matters) but this is a time consuming and mainly unproductive task that always comes with the risk of introducing new regressions.
I could try. However, some of them rely upon matrices so those I'll skip.

Which ones in particular should remain native though? That way I know which ones not to attempt.

Re: Expose A_SpawnProjectile/A_CustomComboAttack/etc to ZSC

by Lord Misfit » Sat Dec 29, 2018 5:56 am

I really am sorry, but messing directly with the main code of GZDoom itself is something I'm not good at, and to be frank, I don't like dealing with the process of getting programs set up to compile it. I've tried to do this in the past just to get certain versions compiled ahead of time because of various reasons, and my results were mixed, I've gotten them to work before, but other times I've failed, and it's a headache I don't want to deal with, right now anyways.

At the same time though, I can understand it's time consuming and it might take quite a while, so I'm not going to try to rush you guys on this. I mostly brought this up originally due to the "inconsistancy" thing, even though these are things that I'd like to see exposed for modding reasons. If it takes a while for them to get added, of course I can accept that, but unfortunately I don't currently have the drive to deal with compiling tools right now, and I also don't have experience in the actual compling language of the port itself, just DECORATE/ACS/ZScript (and my ZScript is the least learned of the three, and I'm not sure how much knowing how to ZScript for mods would help with the process). x.x

That's not to say maybe I won't eventually try, but this is also a bit of a busy time away from the computer for me as well with the new year season right now, so I'll think about if I can really do anything to help directly, but most likely I'd have to settle on waiting for you guys to get to this, or somehow helping in a more indirect fashion.

EDIT: Actually, I suppose I should ask if "helping" could also mean to reference what I did to "recreate" A_CustomMeleeAttack/A_CustomComboAttack (what I mentioned back in the first post) in the ZScript language as well and if that kind of thing would help if I gave that code to someone to add or not? If so, yeah I could do that, but again, I had no luck diciphering various parts of A_SpawnProjectile, so I don't know if I could help "recreate" that one or certain others or not.

Re: Expose A_SpawnProjectile/A_CustomComboAttack/etc to ZSC

by Graf Zahl » Sat Dec 29, 2018 1:32 am

Can you help? The long term plan is to scriptify the entirety of p_actionfunctions.cpp (minus a few where performance really matters) but this is a time consuming and mainly unproductive task that always comes with the risk of introducing new regressions.

Expose A_SpawnProjectile/A_CustomComboAttack/etc to ZSC

by Lord Misfit » Fri Dec 28, 2018 11:27 pm

I noticed recently that apparently A_CustomBulletAttack is available in ZScript for editing, yet multiple similar monster attack functions like A_SpawnProjectile, A_Custom A_CustomComboAttack, A_CustomMeleeAttack, A_CustomRailgun and such are still native only and can't really be modified. [I was able to RECREATE A_CustomMeleeAttack, and A_CustomComboAttack as different named functions, but they are likely not 100% perfect recreations and having the originals exposed would help a lot instead of relying on trying to "reconstructing" the actions/functions].

Why am I asking about these, besides "consistancy" w/ A_CustomBulletAttack? Basically, it would be a big help to optimizing a mechanic of sorts in my mod for spawned monster projectiles if I can directly edit the properties of a just-spawned projectile from within those actions instead of needing to do other possibly hacky workarounds [i.e. using PostBeginPlay() in the projectiles themselves, etc], and I could delete what are essentially slightly modified copies of those projectile attacks.

I can't "reconstruct" more complex actions like A_SpawnProjectile [the one that I'd REALLY need exposed for my optimization idea] unfortunately, so I felt it was worth a try to make a request for those actions here, since AActor was appearantly having more functions and native actions opened up recently.

Sorry if this sounds like a big request, but I figured I'd ask anyways. x.x

Top