Change world weapon shock wave size

Questions, comments, and news on the server side plug-ins and it's API
Post Reply
illeosa
Private
Private
Posts: 1
Joined: Tue Jun 28, 2022 1:39 am

Change world weapon shock wave size

Post by illeosa »

Hey all,

Is there a way to make a world weapon shock wave larger without affecting shock waves from the normal Shock Wave flag?

Thanks,
Grue
User avatar
Zehra
Private First Class
Private First Class
Posts: 914
Joined: Sun Oct 18, 2015 3:36 pm
Location: Within the BZFS API and Beyond it
Contact:

Re: Change world weapon shock wave size

Post by Zehra »

In 2.4.12 and previous builds this is possible, but do note you'll need to use the older world weapons systems for shots and it can get quite a bit tricky in terms of tracking shots and points management.

I believe it's possible to bypass the API in some cases, but it may be a bit tricky to get a workable system. (Modifying BZFS is another option, but far more complicated.)

One possibly viable alternative, is to set the Shock Wave size to smallest you'll use and simply fire additional Shock Wave shots around the center and some distance away from the center point of the "origin" from the "Shock Wave". (Do note that if you're considering to make the "ShockWave" flag shots "bigger", you'll either need to enable the "-noTeamKills" option on the server and not include rogues in the mix or to use much smaller ShockWave shots, so they do not cause players to self-destruct upon firing with the "ShockWave" flag.)

Another option is to simply fire multiple bullets, similar to Enigma's ProxityMines and UselessMines which had some form of a bullet burst. (Do note that both plug-ins were written for 2.x, so they would not work as is for 2.4.x, nor do they have a license, so updates or usage of either one is a bit questionable.)

Hope this helps!

-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 at Strayers.
Visit BZList.net for a modern HTML5 server stats site.

Click here to view the 101 Leaderboard & Score Summaries Last updated 2021-01-12 (YYYY-MM-DD)
Latest 101 thread
Grue
Private First Class
Private First Class
Posts: 27
Joined: Tue Apr 08, 2014 12:23 am
Contact:

Re: Change world weapon shock wave size

Post by Grue »

Zehra,

First off, oops... I see that I accidentally posted this under my sister's account lol.

Secondly, thank you for your reply. I doubt I have the knowledge to bypass the API or modify BZFS, so I'll likely use one of your alternative options you suggested.

Thanks again,
Grue
etigah
Private First Class
Private First Class
Posts: 98
Joined: Tue May 22, 2012 4:08 pm

Re: Change world weapon shock wave size

Post by etigah »

Short answer is, probably not. I needed to do something similar, but found that SW rendering on client can not be controlled per shot. But if what you need is only cosmetic, then there's a hacky method I came up with.

Essentially you would change the bzdb variables that control SW radius right before you fire the world weapon and then reset the variables after the shot expires. See this short video, note the growing circle on radar as the flag goes up.

Obviously that will not be useful in many scenarios, but since I came up with it after reading your post I thought I'd share it anyway :)
Grue
Private First Class
Private First Class
Posts: 27
Joined: Tue Apr 08, 2014 12:23 am
Contact:

Re: Change world weapon shock wave size

Post by Grue »

That's really weird, because I tried that exact thing before I posted this lol, but it didn't have any effect...

Are you running an older version of bzflag or some other mod? I'm not sure why it wouldn't work for me.

Grue
etigah
Private First Class
Private First Class
Posts: 98
Joined: Tue May 22, 2012 4:08 pm

Re: Change world weapon shock wave size

Post by etigah »

I'm running an older version, with mods, but I don't think that's what is making the difference.

One thing I can think of is perhaps you reset the variables too early? All shots that are present when you make a change to the variables will be affected, so if you reset immediately after firing the world weapon it will seem as if nothing is changed. you should instead wait the duration of the life time of the world weapon shot before resetting. In my example I make the lifetime of the WW shot very short (0.1 sec) in order to minimize the effect on regular SW shots.
Post Reply