Radio
Overview
A plugin for giving players the option to broadcast and receive long distance messages across a server using radio towers.
Features
- Construction of a broadcast tower for radio signals
- Transmission of long distance messages via Radio towers
- Ability to receive signals on specific frequencies
- Ability to scan for signals on unknown frequencies
- Ability to customize signal distance, clarity, and colour.
Commands & Permissions
Command | Permission | Usage |
/radio tune [frequency] | radio.radio.tune | Tunes to the specified [frequency] |
/radio scan | radio.radio.scan | Scans for any radio signals in range |
/radio off | radio.radio.off | Turns off the hand-held radio receiver |
Usage
For a quickstart, check out zippe's tutorial on the MinerAp wiki.
Constructing a Radio
The most primitive radio possible is constructed by placing a jukebox, then 1 iron bar above it, then a sign on one of the sides of the jukebox with the frequency and a message.
The first line on the sign is the frequency at which the radio will broadcast at. It is written in the form [123.45], where [] are necessary brackets surrounding the frequency, and 123.45 is any valid decimal frequency. Alphabetical characters are not allowed, but any number which can fit on a sign (e.g. [0.0000000000] to [99999999999]) is valid.
Frequencies are truncated, meaning that [0.000] is the same as [0.00] and [0] But none of those are the same as the frequency [0.0010000].
Any other line on the sign holds a message. Additional signs can be placed on the radio. The frequency will only be read off of one sign, meaning that on the other signs the first line can be used to extend your message. The message on all of the signs is stitched into a single long one on broadcast.
The message ignores the fact that signs have limited space and does not split the message. In order to split your message into multiple lines, use the newline character \n.
The order of these steps DOES NOT matter. What does matter though, is that the radio receive redstone power AFTER all of the other steps have been concluded. REDSTONE COMES LAST. The radio must be receiving a constant redstone signal in order to broadcast. Radios broadcast on a time-delay, not based on how fast their redstone power is fluctuating.
Receiving a Signal
Once a radio is broadcasting, the signal it emits can be picked up by a player. To do this, the player must be holding the pipboy. By default this is the compass. The pipboy does not have to be in the player's hand to receive signals, but it must be in their hotbar. However, to perform Radio commands, the pipboy must be in the player's hand.
Once the pipboy is in the player's hand, the tune command (e.g. /radio tune 123.45 for a radio broadcasting on frequency [123.45]) will tune to that signal and broadcast to the player any signals from any nearby radios with a matching frequency.
The player can also use /radio scan which will rarely (1% chance by default) pickup a signal in-range on a random frequency.
The player can use /radio off to shut off their radio.
Enhancing a Radio
Range Boosting
Adding additional iron blocks on top of a Radio (in a vertical line, to make a radio tower) increases the range of the Radio's broadcast. With the default settings, a radio with a tower 170 blocks high will transmit in a 14000 block radius circle. The configuration for amount of boost provided with each additional iron bar is not exact, as the scale is exponential, with INCREASING returns for each additional iron bar added.
Signal Clarity
By default, a Radio's signal quality rapidly diminishes, and even after a short distance will rapidly degrade into illegibility. Adding an iron block, lapus block, gold block, or diamond block (these blocks and their values can be configured) directly above the jukebox (and underneath the iron bars) increases the signal quality.
Without one of these blocks, the signal clarity is 0%, meaning it begins to degrade at distance 0. However, iron bars also slightly increase the clarity.
By default, a gold block will keep the signal clarity at 50%. This means that if the Radio's broadcast distance is 2000 blocks, then approximately 1000 blocks away from the radio, the signal will begin to degrade, but closer than 1000 blocks to the radio it will be crystal clear. A diamond block has a clarity of 99% by default, making it the best for transmitting a powerful signal.
Colouring your Messages
You can place a coloured wool block above the jukebox to change the colour of the transmitted message. If used in conjunction with a signal clarity block, the wool block must go above the clarity block. So from bottom-to-top, jukebox, signal block, wool, iron bars is correct.
Configuration
Many aspects of the plugin are configurable. At the moment, the options wallRadioPersist and userRadioPersist do nothing.
Due to a programming miscommunication, signal clarity blocks cannot be changed within the configuration at the moment.
Source
https://github.com/Indiv0/Radio
Download
http://dev.bukkit.org/server-mods/radio/files/
Changelog
Version | Changes | Compatible Builds |
1.16.0 | Update to 1.7.2 | 1.7.2 |
1.15.2 | Minimize jar size | 1.6.4 |
1.15.1 | Fix plugin-breaking bug introduced in 1.15.0 | 1.6.4 |
1.6.2 | ||
1.15.0 | Fix hard-coded signal clarity values | 1.6.4 |
1.6.2 | ||
1.14.0 | Fix fugue state bug | 1.6.2 |
1.11.1 | Initial commit | 1.5.2 R-1.0 |
Bugs/TODO
All bugs and TODO information can be found on the issue tracker for this project on GitHub.
Very cool plugin indeed! :-) Coupled with localchat, it adds an extra layer of immersion for me. You can be hiding out & you send a broadcast out for help(You don't know what your in for, so to speak). Hostile players, friendly carebears or whatever else may come your way. :-O Great work! 8-)
Fun plugin that has some nice adaptability. A language / text config file would be nice though.
Altering the pipb item doesn't affect the text shown when commands are typed whilst not holding it - it still states a compass is needed. Making this a text-input field would open it up for mod-items and custom data values ^_^
And being able to assign radio names to the frequencies instead of [Radio
] would be cool :p
@hiphip85
Thanks for the ideas, I'll consider them!
@n0etics
Glad to hear that!
@nytmaster
That is not possible.
@nullschritt
Scan functionality on my server is meant to be a rare occurrence, and not player-dictated. I will however put that on the tracker as a future feature for an alternative scan method.
@alphatails
Sorry, but I can't determine the conflict from that trace. If you are using any of my other plugins (BlockSaver, BookDupe, etc.), the conflict is probably there. This is because all my plugins rely on a specific API, and they will interfere with each other as I link the library into the jar. I will provide the option for an API-less jar so you can download the API separately and then the plugins will be inter-compatible. HOWEVER, I believe that currently, if the major versions of the plugins match up (i.e. 1.16.* Radio and BookDupe), then they should work.
@Dimentio099
I'll add an option for delay, but not for randomly picked messages.
Can we add our own delay and possibly more messages picked at random in the future?
Not exactly sure what the ordeal is, prolly a conflict somewhere... The plugin was working great for a few days, a lot of players liked it. It is most likely a conflict with something I installed, but I'm not sure.
Edit: I removed about ten plugins, it started working again. Not sure which one caused the error.
Startup Dump
[23:03:45] [Server thread/INFO]: [Radio] Enabling Radio v1.16.0 [23:03:45] [Server thread/ERROR]: Error occurred while enabling Radio v1.16.0 (Is it up to date?) java.lang.VerifyError: Bad access to protected data in getfield Exception Details: Location: com/amshulman/mbapi/commands/DelegatingCommand.registerSubcommand(Lcom/amshulman/mbapi/commands/BukkitCommand;)V @5: getfield Reason: Type top (current frame, stack[2]) is not assignable to 'com/amshulman/mbapi/commands/DelegatingCommand' Current Frame: bci: @5 flags: { } locals: { 'com/amshulman/mbapi/commands/DelegatingCommand', 'com/amshulman/mbapi/commands/BukkitCommand' } stack: { 'com/amshulman/typesafety/TypeSafeMap', 'java/lang/String' } Bytecode: 0000000: 2ab4 0026 2bb4 0084 b600 63b9 0088 0200 0000010: 9900 0dbb 0081 5912 8ab7 008d bf2a b400 0000020: 262b b400 84b6 0063 2bb9 0091 0300 572a 0000030: b400 302b b400 84b6 0063 b900 9402 0057 0000040: b1 Stackmap Table: same_frame(@29)
at in.nikitapek.radio.RadioPlugin.onEnable(RadioPlugin.java:17) [?:?] at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:218) [craftbukkit-1.7.2-R0.2.jar:git-Bukkit-1.7.2-R0.2-b2974jnks] at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader.java:457) [craftbukkit-1.7.2-R0.2.jar:git-Bukkit-1.7.2-R0.2-b2974jnks] at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:384) [craftbukkit-1.7.2-R0.2.jar:git-Bukkit-1.7.2-R0.2-b2974jnks] at org.bukkit.craftbukkit.v1_7_R1.CraftServer.loadPlugin(CraftServer.java:298) [craftbukkit-1.7.2-R0.2.jar:git-Bukkit-1.7.2-R0.2-b2974jnks] at org.bukkit.craftbukkit.v1_7_R1.CraftServer.enablePlugins(CraftServer.java:280) [craftbukkit-1.7.2-R0.2.jar:git-Bukkit-1.7.2-R0.2-b2974jnks] at net.minecraft.server.v1_7_R1.MinecraftServer.m(MinecraftServer.java:342) [craftbukkit-1.7.2-R0.2.jar:git-Bukkit-1.7.2-R0.2-b2974jnks] at net.minecraft.server.v1_7_R1.MinecraftServer.g(MinecraftServer.java:319) [craftbukkit-1.7.2-R0.2.jar:git-Bukkit-1.7.2-R0.2-b2974jnks] at net.minecraft.server.v1_7_R1.MinecraftServer.a(MinecraftServer.java:275) [craftbukkit-1.7.2-R0.2.jar:git-Bukkit-1.7.2-R0.2-b2974jnks] at net.minecraft.server.v1_7_R1.DedicatedServer.init(DedicatedServer.java:175) [craftbukkit-1.7.2-R0.2.jar:git-Bukkit-1.7.2-R0.2-b2974jnks] at net.minecraft.server.v1_7_R1.MinecraftServer.run(MinecraftServer.java:424) [craftbukkit-1.7.2-R0.2.jar:git-Bukkit-1.7.2-R0.2-b2974jnks] at net.minecraft.server.v1_7_R1.ThreadServerApplication.run(SourceFile:617) [craftbukkit-1.7.2-R0.2.jar:git-Bukkit-1.7.2-R0.2-b2974jnks]
Great plugin, but would be neat if you could scan for channels by right clicking the air with the pipboy in hand.
Should put in, were u can place record in jukebox so when the message gets transmitted the records plays full song. That way if you are using custom resource pack and have custom music ingame being played threw different stations..
@n0etics
ok so I tired it out and not only is it super easy to use, it's really cool! Thanks for the great plugin!
@Indivisible0
I don't need something that's too up-to-date as I'm not interested in a tutorial, I kinda jut wanted to see it in action.
I've a lot of ideas for this wonderful plugin.
/!\ boosts blocks don't work in 1.6.2 for me. Use a lot of iron bar
submit idea >> add the fonction to display only the better signal (for broadcast of same frequency). Radio pirates ^^
@n0etics
@wezerds
There are no up-to-date videos. I will make one eventually.
For now, if you need a simpler explanation, just read this.
@wezerds
I was just looking for a video as well.
can you put up a vid
@BigBananaMan
My oh my that is quite an essay.
I'm sorry to hear about your motherboard.
As for your problem with dependencies, the server hosting the core API that this plugin relies on actually went down a few days ago and has not come back up yet, so that might explain why Maven failed to compile.
I have a bleeding edge release of Java because I run Arch Linux, which uses rolling release distribution. This means I always have the absolute latest version of Java, whether I want to or not.
I might consider compiling against Java 1.6 in the future, but I believe the API I use requires Java 1.7 for something, so that might not be possible. In that case, I guess I can look into a way of downgrading my Java for strictly compilation purposes.
Thank you so much for all of your information and your time. I'm really sorry that the plugin couldn't work for you. Maybe it will in the future some day.
As for your last comment, I have no idea. :/
EDIT: Although I have no idea what any other cause of this issue might be, are you sure it's because of the Java version? According to mcstats only 4 out of 27 servers are running Radio with 1.7.0_40.
@Indivisible0
FUCKING ASUS! Never ever EVER buy an ASUS motherboard. I had typed up a full essay detailing about half of the steps I've taken to fail at getting this plugin to work but my computer crashed like it does every day literally right after I completed it and was browsing over it!!! AHHHHHHHHHH!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! Like it often does, it can't boot now and just sits at a black screen without even loading the BIOS. I've built many computers, probably more than 100, and I've personally owned 2 Asus boards, the first one would crash often and eventually an IC burned out. This current one crashes daily and I've diagnosed it down to something within the voltage regulator. Absolutely least reliable motherboard manufacture I've ever seen and I say it every day of my life. Just don't buy Asus, I've lost a lot of money and a lot of time to this motherboard. I can't wait until it burns out, I'm going to shoot the ever living shit out of it with my rifle and put a pipe bomb on the dust and then set the crater on fire.
I'm not going to retype everythign, my hands are bleeding, when this laptop battery dies that's it because I haven't repaired the carging circuit on the board yet, and all of the error logs I saved are on my piece of shit desktop computer. I have broken glass and fan chair everythig ot clean up.
The basics are that I already have the most up to date Java package that is available so I compiled the latest build from source. I had to install a dozen dependencies into the chroot jail but when I compiled it spit out 1.1MB worth of error messages. I am absolutely not oing to sit down and fix that many errors just to have divine intervention thwart me again.
next I found out exactly why our versions aren't compatible. https://blogs.oracle.com/darcy/entry/bootclasspath_older_source
I figured since your rt.jar file is creating object files that are incompatible with mine, your 1.7.0_40 code is probably the same code you would have written under 1.7.0_25 thus I could just compile it on my end and it'll be compatible. Well that wasn't the case, I compiled it with javac and the error messages hinted that your code couldn't be compiled at all. Then I tried with ant which said it's missin the build file (makefile?) and I'm not going to take a Java class to complete this. Then I compiled it with Mvn and guess what, it requires access to a repository and the idiots not only wrote the domain backwards (like org.bukkit.dev for example) but it wasn't in the config files, the idiots hard coded it! This project is cursed! It really is, there's something following every step to make sure nothing works. I've never seen anything like these past days in my life. I swear it's coming out and affecting even hardware and a fan next to the computer that failed.
That's the end, I've hit the brick wall at the end of the halley and I ould bang my head into it until the wall falls down so that I can start working on the next problem but no. Not happening.
Thanks for your input anyway Indivisble0. I'm not looking for help any more because I'm not going to use this plugin but maybe all tose logs I didn't post will help the next guy. Aside from a few extra security measures and some shell code I wrote to automate things, the system is essentailly stock and fully up to date. This server's software closely represents most servers on the internet. I can guarantee a lot of the people out there who would want to install your plugin, installed RealisticChat or something else instead.
On a final note, I never ask more of somebody who is working for free so this is more of a FYI but it is possible to compile java to be backwards compatible but it would require you to get old rt.jar files and compile a version of your plugin for each likely version of Java out there and that's not really reasonable unless you're making money. Otherwise maybe remove or substitute whatever it is in your source code that is requiring you to use such a bleeding edge release of Java and go with whatever is the stable release. All the other plugins on the server work fine so the latter must be what everybody else is doing.
Why, why did Notch have to write Minecraft in Java instead of C or Python?
@BigBananaMan
It looks like you need JDK version 1.7.0_40, not 1.7.0_25. Try installing that and let me know if it works.
@Indivisible0
Well I thought I figured out what was wrong so I'll post more detailed information on the java version while I explain that. I often run servers that connect to the internet in chroot jails or VMs rather than directly in the same environment as the server OS. I have the Java on the server up to date however when Java 7 was released and I installed it on the server, I neglected to do it within that chroot jail.
Below is what was returned by "java -version".
I replaced the plugin .jar, installed the latest version of Java, and checked that both the chroot jail and server OS are running the same version but nothing changed. The following is the relevant portion of the log.
I thought that surely was it but it looks like upgrading from Java 6 to 7 didn't change the outcome. I can't really think of anything else to do at the moment, let me know if you need any more info or for me to try anything.
@BigBananaMan
Unsupported major.minor version 51.0 means that your version of Java is too outdated to run this plugin.
However this seems not to be the case as you say you have Java 1.7.0_25.
Could you tell me if you have a JDK or JRE installed?
Having trouble figuring out what I'm doing wrong with this plugin, it appears to be out of date but it's working for everybody else. I've set the file permissions to 750 with daemon as the owner (the server runs in a chroot jail under daemon) and my account as the group (exact same setup as all the plugins) however with or without other plugins loaded, this plugin attempts to load but gives the following excuse:
05:33:22 [SEVERE] Could not load 'plugins/radio-1.14.0.jar' in folder 'plugins' org.bukkit.plugin.InvalidPluginException: java.lang.UnsupportedClassVersionError: in/nikitapek/radio/RadioPlugin : Unsupported major.minor version 51.0
OS: Ubuntu 12.04 (server) Craftbukkit: git-Bukkit-1.6.2-R1.0-b2879jnks (MC: 1.6.2) (Implementing API version 1.6.2-R1.0) Java: 1.7.0_25 Plugins: None