I was wondering if someone could give me some code to make the fallowing plug-in:
Creates random world weapons at random positions and random rotations. After a once the shot the world weapon(s) and the shot reloads the world weapon(s) change to another random position and rotation. Have variables (set through the config) that would set the world size (or if that can be detected that would be great), how often shots are fired, and what type of shots are fired (e.g. SW, US, GM, etc.)
Please PM me with the code and not post it.
Thanks,
The Noah
Create Random world weapons
- The Noah
- Private First Class
- Posts: 82
- Joined: Mon Jul 11, 2016 9:38 pm
- Location: United States
- Contact:
Create Random world weapons
I've been working on a real-time stats site called BZList, please check it out! It is still in active development, so some features are missing and watch out for bugs.
GitHub · Website · Get in touch · Stalk Me
GitHub · Website · Get in touch · Stalk Me
Re: Create Random world weapons
Search the API and learn for yourself: https://wiki.bzflag.org/Functions_(API); there's a section for "world weapon management." As for world size, it's a BZDB variable; there's a function for that too. There's also the API header file which is the authoritative source until the official documentation is done: https://github.com/BZFlag-Dev/bzflag/bl ... /bzfsAPI.h
You'd get a better response from me, and possibly others, if you make an attempt first on what code you've tried and ask for feedback from there. I find saying, "hey write this code for me but send it to me privately because I don't want others to see it or learn from it" to be just rude.
If others just write code for you, it'll be a disservice to you since you'll never learn.
You'd get a better response from me, and possibly others, if you make an attempt first on what code you've tried and ask for feedback from there. I find saying, "hey write this code for me but send it to me privately because I don't want others to see it or learn from it" to be just rude.
If others just write code for you, it'll be a disservice to you since you'll never learn.
- The Noah
- Private First Class
- Posts: 82
- Joined: Mon Jul 11, 2016 9:38 pm
- Location: United States
- Contact:
Re: Create Random world weapons
There are a few things I would like to say.
1. I searched the API, and found the world weapon management, but I don't know how to use it.
2. I don't know how I would control multiple world weapons, and keep them separate.
3. I thought of making some code first, but knew I wouldn't get anything other then the frame.
4.
I'm sorry for being rude,
The Noah
1. I searched the API, and found the world weapon management, but I don't know how to use it.
2. I don't know how I would control multiple world weapons, and keep them separate.
3. I thought of making some code first, but knew I wouldn't get anything other then the frame.
4.
I'm sorry you find it rude, and it kinda is, but first, someone requested me making a plug-in for them, and said for it to be private. And seconds, since I didn't know the main part (what makes it do what it does), I ask on the forums.I find saying, "hey write this code for me but send it to me privately because I don't want others to see it or learn from it" to be just rude
I'm sorry for being rude,
The Noah
I've been working on a real-time stats site called BZList, please check it out! It is still in active development, so some features are missing and watch out for bugs.
GitHub · Website · Get in touch · Stalk Me
GitHub · Website · Get in touch · Stalk Me
Re: Create Random world weapons
The world weapon api is very simple, call a function, weapon is triggered, end of story. All world weapons art triggered separately, so your comment of how to “keep them seperate” makes no sense. What are you trying to do that is so are for you?
Calling functions is basic programming....
Calling functions is basic programming....
JeffM
- Zehra
- Private First Class
- Posts: 920
- Joined: Sun Oct 18, 2015 3:36 pm
- Location: Within the BZFS API and Beyond it
- Contact:
Re: Create Random world weapons
From my understanding of plug-ins:
A plug-in will call a function when an event happens.
The logic and functions are all up to whoever decides to write the plug-in.
A list of some plug-ins which use world weapons which have been released on the forums.
(These plug-ins are not part of the official distribution)
* Turret Plugin Release
Triggers world weapons based on players.
* Grenade flag release - as seen on Apocalypse
Fires a shockwave based on timing and where a shot is heading.
* SnakeShots
World weapons are used to "fake/make" extra shots for a player.
* CustomFlags
World weapons are used to "fake/make" extra shots for a player.
* UselessMine - Create mines with the Useless flag (2.x)
World weapons are fired when players drive on zones set by players.
* ProximityMine - What UselessMine should have been (2.x)
World weapons are fired when players reach zones set by players.
* UselessMine - Create Mines with the Useless Flag Once Again!
A version of the useless mines plug-in for 2.4.x.
A list of plug-ins from the official distribution which use world weapons are listed below.(At the time of writing from this post)
* ShockwaveDeath
* wwzones
Hopefully these plug-ins can help give an idea of what can be done with world weapons and to also help assist in writing a plug-in.
-Zehra
A plug-in will call a function when an event happens.
The logic and functions are all up to whoever decides to write the plug-in.
A list of some plug-ins which use world weapons which have been released on the forums.
(These plug-ins are not part of the official distribution)
* Turret Plugin Release
Triggers world weapons based on players.
* Grenade flag release - as seen on Apocalypse
Fires a shockwave based on timing and where a shot is heading.
* SnakeShots
World weapons are used to "fake/make" extra shots for a player.
* CustomFlags
World weapons are used to "fake/make" extra shots for a player.
* UselessMine - Create mines with the Useless flag (2.x)
World weapons are fired when players drive on zones set by players.
* ProximityMine - What UselessMine should have been (2.x)
World weapons are fired when players reach zones set by players.
* UselessMine - Create Mines with the Useless Flag Once Again!
A version of the useless mines plug-in for 2.4.x.
A list of plug-ins from the official distribution which use world weapons are listed below.(At the time of writing from this post)
* ShockwaveDeath
* wwzones
Hopefully these plug-ins can help give an idea of what can be done with world weapons and to also help assist in writing a plug-in.
-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
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