I'd like if there was a function for triggering onCap world weapons.
So it would be possible to introduce a few new modes and to also be able to trigger them when using altered or enhanced CTF modes.
(Triggering onCap with flags/kill streaks/points..etc..)
base
position 100 0 0
rotation 0
size 10 10 0
color 1
oncap SW
end
-Zehra
Those who are critical of me, I'll likely be the same of them. ~Zehra The decisions we make are the ones we look forward too and the ones we regret. ~Zehra There's a difference between knowing my name and knowing me, one shows respect to my name and the other is to who I am. ~Zehra
See where I've last been active atStrayers. Visit BZList.net for a modern HTML5 server stats site.
I'm not sure if I'm missing something, so please correct me if I'm wrong, but I checked for 'bz_triggerFlagCapture' with Notepad++ on bzfsAPI.h from BZFlag version 2.4.10 and didn't find it.
I'm probably doing something wrong, so could a little bit of help be given?
-Zehra
Those who are critical of me, I'll likely be the same of them. ~Zehra The decisions we make are the ones we look forward too and the ones we regret. ~Zehra There's a difference between knowing my name and knowing me, one shows respect to my name and the other is to who I am. ~Zehra
See where I've last been active atStrayers. Visit BZList.net for a modern HTML5 server stats site.
// game type info
BZF_API bz_eGameType bz_getGameType ( void );
BZF_API bool bz_triggerFlagCapture(int playerID, bz_eTeamType teamCapping, bz_eTeamType teamCapped);
Note: 2.4.12 or above is required to run any plug-in with the bz_triggerFlagCapture function.
I still have to see if it triggers world weapons though.
-Zehra
Last edited by allejo on Sun May 20, 2018 5:58 am, edited 1 time in total.
Reason:Stop with the small font sizes
Those who are critical of me, I'll likely be the same of them. ~Zehra The decisions we make are the ones we look forward too and the ones we regret. ~Zehra There's a difference between knowing my name and knowing me, one shows respect to my name and the other is to who I am. ~Zehra
See where I've last been active atStrayers. Visit BZList.net for a modern HTML5 server stats site.
bz_triggerFlagCapture calls the internal bzfs function which is used whenever a flag capture happens regularly, meaning a flag capture event is fired. The onCap world weapons listen to the flag capture event, so unless the current code is broken, it'll trigger the world weapons.
Keep in mind, this function will destroy all of the tanks and modify team scores as dictated. It won't *just* fire off onCap world weapons.