Plug-in Starter (Now for 2.4.x!)
Plug-in Starter (Now for 2.4.x!)
I've written a simple PHP script to facilitate the plugin-writing process.
http://l4m3r.bzflag.net/scripts/plugin_starter.php
This will set up a skeleton of the C++ code, handling the events and commands of your choosing. While the primary intention is to make plug-in authoring faster (and less boring) for people who know the API, it may also be helpful for those trying to learn how it works.
It's currently in a testing stage. Please leave any comments and report bugs here. (there are sure to be typos...)
http://l4m3r.bzflag.net/scripts/plugin_starter.php
This will set up a skeleton of the C++ code, handling the events and commands of your choosing. While the primary intention is to make plug-in authoring faster (and less boring) for people who know the API, it may also be helpful for those trying to learn how it works.
It's currently in a testing stage. Please leave any comments and report bugs here. (there are sure to be typos...)
Last edited by L4m3r on Thu Oct 09, 2008 7:44 am, edited 2 times in total.
Optimism is just a milder alternative to denial.
I like the point on learning how to make plugins and how they actually function. I'm speaking for someone who has never gone into that direction at all so this might be a good and interesting start. Nice work.
dexter ([phagozytose] : http://www.phago.de)
- flying_popcorn
- Private First Class
- Posts: 88
- Joined: Wed Dec 14, 2005 2:40 am
- Contact:
Re: Plug-in Starter
Sorry for the wait (it's been way too long), but I've finally gotten around to updating this script for 2.4.x. It should now include all API events that are in trunk as of today.
As before, there are bound to be typos or other bugs. Feedback is appreciated, of course.
As before, there are bound to be typos or other bugs. Feedback is appreciated, of course.
Optimism is just a milder alternative to denial.
Re: Plug-in Starter (Now for 2.4.x!)
Not sure if you got my message on IRC, but just to be safe.
There are two typos that I've found so far. When you call on a slash command in the class (the virtual bool SlashCommand()) it's "bz_APIStringList" not "bzAPIStringList." Also, it's
not "bz_registerCustomSlashCommand(const char*)" so it should look like this:
There are two typos that I've found so far. When you call on a slash command in the class (the virtual bool SlashCommand()) it's "bz_APIStringList" not "bzAPIStringList." Also, it's
Code: Select all
bz_registerCustomSlashCommand(const char*, bz_CustomSlashCommandHandler*)
Code: Select all
bz_registerCustomSlashCommand("myCommand", this)
Re: Plug-in Starter (Now for 2.4.x!)
It appears that the link is not working.
Re: Plug-in Starter (Now for 2.4.x!)
Disappointed to have the same as Starmute. Does someone (the author?) have the PHP script? I can host it...
Re: Plug-in Starter (Now for 2.4.x!)
Since l4m3r seems to have lost interest in this project, I wrote a replacement.
http://allejo.me/tools/bzflag-plugin-starter/
To avoid spamming this thread, please PM me any issues that you find or report them here. I do plan on adding some more features to this so let me know if you have any ideas. Like the majority of my code, the code for this website is open source and can be found here.
http://allejo.me/tools/bzflag-plugin-starter/
To avoid spamming this thread, please PM me any issues that you find or report them here. I do plan on adding some more features to this so let me know if you have any ideas. Like the majority of my code, the code for this website is open source and can be found here.
Re: Plug-in Starter (Now for 2.4.x!)
I've rewritten this tool available here: http://projects.allejo.io/bzflagPluginStarter2/
The source code is available here and I welcome pull requests if any: https://github.com/allejo/bzflagPluginStarter2
Please note, this version is built entirely in JavaScript so be sure to have it enabled on your browser when visiting this website. Let me know if there are any errors in the generation of plug-in skeletons and I'll be more than happy to correct them. I'll be taking down the PHP version and having the previous URL redirect to the new one in the coming weeks.
The source code is available here and I welcome pull requests if any: https://github.com/allejo/bzflagPluginStarter2
Please note, this version is built entirely in JavaScript so be sure to have it enabled on your browser when visiting this website. Let me know if there are any errors in the generation of plug-in skeletons and I'll be more than happy to correct them. I'll be taking down the PHP version and having the previous URL redirect to the new one in the coming weeks.
Re: Plug-in Starter (Now for 2.4.x!)
The project has moved to: https://bzflag-plugin-starter.allejo.org/
Version 1 of this tool has been shut down and automatically redirects to the current version.
Version 1 of this tool has been shut down and automatically redirects to the current version.
Re: Plug-in Starter (Now for 2.4.x!)
Greetings!
Last winter I had started a rewrite of my plug-in starter to be more modular and never managed to finish it; until a few days ago that I started development again.
My project has been split-up into three separate projects:
- aclovis (GitHub) - A TypeScript library for generating C++ programmatically
- bzfPluginGen (GitHub) - A TypeScript library using aclovis for generating a C++ BZFlag plug-in
- bzflagPluginStarter3 (GitHub) - A React.js website using bzfPluginGen to give you pretty buttons to generate a plug-in
The core project, bzfPluginGen, already supports generating all of the following:
Thanks for tanking with my projects and please submit any bug reports!
Last winter I had started a rewrite of my plug-in starter to be more modular and never managed to finish it; until a few days ago that I started development again.
My project has been split-up into three separate projects:
- aclovis (GitHub) - A TypeScript library for generating C++ programmatically
- bzfPluginGen (GitHub) - A TypeScript library using aclovis for generating a C++ BZFlag plug-in
- bzflagPluginStarter3 (GitHub) - A React.js website using bzfPluginGen to give you pretty buttons to generate a plug-in
The core project, bzfPluginGen, already supports generating all of the following:
- Custom BZDB settings
- Custom callbacks
- Custom flags
- Custom map objects
- Custom poll types
- Custom slash commands
- Event registration
Thanks for tanking with my projects and please submit any bug reports!
Re: Plug-in Starter (Now for 2.4.x!)
My plugin starter now has an editor for creating and registering custom map objects. With that, bzflagPluginStarter3 has reached feature parity with bzfPluginGen in that there's a UI for everything bzfPluginGen supports.