Page 1 of 1

Plugin Question.

Posted: Wed Sep 03, 2008 8:49 pm
by Big Cheese
i've searched a bit with no luck, but is their a plugin that allows flags to spawn once a certain number of players have joined a server?

like when theres only 3 people in a map and one of them gets a super-flag, they can really dominate for awhile. is their a plugin that would allow me to say gm and laser wont fall till 6 or more people in the server?

Thanks
Nathan

Posted: Wed Sep 03, 2008 10:23 pm
by Marines
i do not think there is a plugin for that. yet :)

Posted: Thu Sep 04, 2008 5:05 pm
by A Meteorite
The 2.0 API does not allow that sort of flag control. I'm assuming that it would be possible to be added to the API, though, as the server controls dropping flags (not sure how much work it'd take, though, I haven't really looked at flag control).

You'd probably be better off, say, bz_removePlayerFlag(int playerID)'ing the player if they have y flag and if there is less than x players.

Posted: Thu Sep 04, 2008 5:54 pm
by Spazzy McGee
A Meteorite wrote:The 2.0 API does not allow that sort of flag control. I'm assuming that it would be possible to be added to the API, though, as the server controls dropping flags (not sure how much work it'd take, though, I haven't really looked at flag control).

You'd probably be better off, say, bz_removePlayerFlag(int playerID)'ing the player if they have y flag and if there is less than x players.
No, I think it could be possible. Am I correct in assuming that a plugin can execute a /command with admin permissions? In which case get your plugin to run /flag up (which removes all flags) when the player count is under a threshold, and then /flag reset all when it's higher. Problem solved.

Posted: Thu Sep 04, 2008 6:55 pm
by JeffM
Spazzy McGee
you are incorrect, a plugin can not call any generic / command, it can only call the API functions defined in the API.

some of the flag commands are in the API.

Posted: Fri Sep 05, 2008 4:49 am
by flying_popcorn
Ok I just made one. It doesn't let you pick up any flags until there are 4 or more players.

Licence: GPLv3

Later i will add more things, like configuring it only to drop certain flags, sending a message to the player explaining why they dropped the flag, etc.

Posted: Fri Sep 05, 2008 8:11 pm
by Marines
lol i think flying popcorn is the plugin master! :D

theme97

Posted: Fri Sep 05, 2008 10:00 pm
by optic delusion
nobody asked for it, but i'm gonna mention theme97's plugins.
he hasn't been seen for awhile, but this page still exists
There may be something you find intersting there... spawnByPlayerCount maybe...

http://theme.freehostia.com/bzflag/plugins

Re: Plugin Question.

Posted: Wed May 02, 2018 2:35 am
by Zehra
I updated flying_popcorn's plug-in and didn't want to start a new topic, so here it is.

Description: Prevents players from picking up flags, if there is less than 4 players.
Min Version: 2.4.2
Files: NoFlags
License: GPLv3

Only difference from flying_popcorn's work is the event used for it.
Instead of using bz_eFlagGrabbedEvent and removing the flag afterwards, bz_eAllowFlagGrab is used, which takes advantage of a newer feature available in the API.

-Zehra

p.s. Sorry for bumping such an old thread.