Welcome to my repository!
Dynamic Signature is meant to be used for tracking the progress of a Runescape bot scripts. The project allows script writers (for any java based runescape bot) to add automatically generated dynamic signatures/progress reports for all of a script's users. Currently, the recorded data is the script's name, the encrypted script password, the forum username, the time that the script has been running, and 5 long values. I should be running this for the foreseeable future provided it isn't abused.
The project contains 3 components:
The server receives progress reports from a script and stores it in a database and creates the signatures. You may either use my own server, or download the code and use it yourself. Every time a user's script sends a progress report, a new image is generated based on background image supplied by the scripter, a configuration file (see designer) and the updated values in the user's database entry. If you wish to use my server, The image is located at ctrl.software/signatures/SCRIPT_NAME/OSBOT_USERNAME.png and the image for all users of a script is located at ctrl.software/signatures/SCRIPT_NAME/All Users.png. An update is only accepted if it sends along with it the script's password which is encrypted using RSA encryption. This means that someone can't packet sniff to find a script's password and upload fake data.
The client is a few classes to be added to your script which allows a you to implement the progress tracking. It supports updating at regular intervals (incase the exit method is never called such as from a computer crash) and updating from a separate thread so the script doesn't pause while it uploads.
First UserData.java, StatsUpdater.java and StatsUpdaterThread to your script. Create a new instance of StatsUpdater in your onStart() method (or equivalent). The parameters are the script name (all lower case and one word e.g. dicloniusmta), your script password saved in your config file, the users forum username (client.getUsername() if using OSbot) and finally the upload interval in minutes (Optional).
For basic usage with intervals, call sendScheduleThreaded() during your script's onLoop() and onExit() (or equivalent). The time ran is recorded automatically (with minute accuracy). The five (or fewer) long values can record anything you want, e.g xp gained, fish caught etc. Successfully sent values are recorded and subtracted when sending each update so you should always pass the current values.
This program allows scripters to create a config file which the server interprets when it creates new images. It allows you to choose the location, font, colour and format (where applicable) of the tracked values with a real time preview. This code is badly written so it does have a few bugs, is easy to break and doesn't have any error checking.
First you need a background image for the values to be drawn on top of. This must be in .png format. When you run the program, you will be prompted with a file selection, you should open your background image. Previously saved config files should automatically be opened.
Next you will be presented with two windows, the preview is self explanatory. You may need to resize it to show your entire background image.
Use the option window (shown below with crude annotations drawn in paint) to modify the location, font, colour and number format for each of your values. Use the preview text box to enter values to be previewed in the other window. When typing a value into either of the two spinners or text field, you must press enter to set the values. The format selector is only applicable to time ran and the 5 long values. If you want to write your own formats (must be a method that takes a long as a parameter and returns string) just contact me on OSBot. When you press save, you are prompted to enter a password for your script. A client can only upload data if they know this password. Configuration files are saved in the same directory as the background image as "config".
Once done you may contact me on OSBot: http://osbot.org/forum/user/655-diclonius/ where I will create your database entry and upload your config and background files, Or run the server module on your own server.