ConnectFour
ConnectFour

WHAT IS IT?
Most of you know "Connect Four" or "Four In A Line". This is the Minecraft version of it.
FEATURES
- play Connect Four in Minecraft
- get statistics about played games
- play multiple ConnectFour-games at the same time
- customizable language file
- create signs to join a game without commands
- very easy setup
- use any blocks you want instead of sand and gravel
- much settings in the config
- items as rewards
- vault economy support
- economy reward
- betting against your opponent
- have fun
INSTALLATION
Simply put the ConnectFour.jar into your plugins folder and restart the server.
CREATE A GAME
Build the Display
- First of all you have to build the display. This must be at least 7 x 7 blocks.
- Now the game needs a throw-in bar. This should be a 7 blocks wide line.
Select those Things
- Type /cfour create <gameName> <gameName> = The name of the game you're creating.
- Now select the Throw-in:
- Put two dirtblocks at the corners of the throw-in bar so there are 7 blocks (air) between them. (see image)
- Put two dirtblocks at the corners of the throw-in bar so there are 7 blocks (air) between them. (see image)
- And the Display:
- Put two cobblestoneblocks at the top corners of the display so there are 7 blocks (air) between them. (see image)
- Put two cobblestoneblocks at the top corners of the display so there are 7 blocks (air) between them. (see image)
- When the selection's done, save it with /cfour save
Set the Spawn
- The last thing you have to do is to set the spawn. For doing that type /cfour setspawn
Create a spawn-sign
- You can create spawn-signs, so you don't have to execute a command to join a game.
- Create a spawn-sign:
| LINE1 | [cfour] |
| LINE2 | <gameName> |
| LINE3 | empty |
| LINE4 | empty |
Set rewards (optional)
- You can do that if you want to give the winners some items.
- Set the rewards for a game: /cfour setrewards <gameName> <id:amount[:damage]> <...>
For example: /cfour setrewards game1 1:10 17:20:1 will set the rewards of "game1" to 10 cleanstone and 20 birchwood
When you've set some rewards but now you've changed your mind, do /cfour removerewards <gameName> for remove the rewards.
Set economy rewards (optional, needs vault)
- You can do that if you want to give some money to the winners.
- Set the economy rewards for a game: /cfour setEcoReward <gameName> <amount>
Set a betting stake (optional, needs vault)
- Use this, if you want your players to bet against each other.
- When a player joins the game, he'll have to pay <amount> of money to play. The winner will receive the whole amount.
- Set a betting stake for a game: /cfour setBetMoney <gameName> <amount>
Change the block IDs (optional)
- If you don't want to play with sand and gravel, you can set other IDs.
- To do that do: /cfour setblocks <gameName> <ID1> <ID2>
Congratulations! Your ConnectFour game is now playable :D
To remove a game type /cfour remove <gameName>
PLAY
How to play
- The players who want play ConnectFour have to type /cfour join <gameName>
- Now they're ingame. The distribution of sand and gravel and who has to begin is absolutley random.
- The player who's turn it is has to put he's block (sand or gravel) on the throw-in bar. Now the block will automaticaly be teleporter to the top of the display and fall down.
How to win
The target is to put the sand/gravel in a row of 4 blocks. This works horizontally, vertically and diagonally.
Be first or you will lose!
NOTICE: If you destroy the blocks whith WorldEdit or anything other, this will only have a visual effect. The real block positions will not be changed (but you can't play very good if you don't see where your block realy is).
CHANGE LANGUAGE
ConnectFour is available in two languages (German and English).
If you want to change the language type in /cfour lang <DE|EN|custom>
| DE | German |
| EN | English |
| custom | loads the texts from the languagefile |
VIDEOS
by Dragon252525
by VariationVault
CONFIG
#the language (DE|EN|custom) language: de #en-/disable "it's your turn" messages enable-*itsYourTurn*-spam: true #should the players be teleported to their previous position when the game is over? teleportOnGameEnd: true #should the display automaticaly be cleared when the game is over? (normaly it'll be cleared as soon as a new game beginns) clearTheDisplayOnGameEnd: false #should you be able to user join-signs enableJoinSigns: true #must the player be in the same world as the game to join? sameWorldToJoin: false #must the player be within a certain radius to join? checkMaxDistaceToGameSpawnOnJoin: false #radius maxDistanceToGameSpawn: 20 #some MySql settings for online statistics use_MySql: false mysql_host: localhost mysql_port: '3306' mysql_database: database mysql_username: username mysql_password: '12345'
COMMANDS AND PERMISSIONS
| Permission | Command | Description |
|---|---|---|
| cfour.user.* | none | All user permissions. |
| cfour.user.play | /cfour join | Join a game. |
| cfour.user.play | /cfour leave | Leave a game. |
| cfour.user.play | /cfour info | Shows a short Tutorial |
| cfour.user.tp | /cfour tp | Teleport to a game. |
| cfour.user.help | /cfour help | Shows the help page. |
| cfour.user.list | /cfour list | List all games. |
| cfour.user.stats | /cfour stats | Show the statistics. |
| cfour.admin.* | none | All admin and user permissions. |
| cfour.admin.reload | /cfour reload | Reload the config. |
| cfour.admin.lang | /cfour setlang <lang> | Change the language. |
| cfour.admin.clean | /cfour clear | Clear the display. |
| cfour.admin.create | /cfour create | Create a game. |
| cfour.admin.create | /cfour setspawn | Set the spawn of a game. |
| cfour.admin.create | /cfour remove | Remove a game. |
| cfour.admin.create | /cfour setrewards | Set the rewards for a game. |
| cfour.admin.create | /cfour removerewards | Remove the rewards from a game. |
| cfour.admin.create | /cfour setEcoReward | Set the economy reward for a game. |
| cfour.admin.create | /cfour removeEcoReward | Remove the economy reward from a game. |
| cfour.admin.create | /cfour setBetMoney | Set the stake for a game. |
| cfour.admin.create | /cfour removeBetMoney | Remove the stake from a game. |
| cfour.admin.create | /cfour setblocks | Change the blocks of a game (instead of sand and gravel). |
| cfour.admin.stop | /cfour stop | Stop a game. |
| cfour.admin.disable | /cfour disable | Disable a game to edit it. |
| cfour.admin.disable | /cfour enable | Enable a game. |
STATISTICS
INGAME
To see the statistics do /cfour stats
ONLINE
If you have a website, you can include this script to get some statistics about played games and players. Example here

Setup the Webstats script
- Open plugins/ConnectFour/config.yml , enter your MySql data and set use_MySql to true.
- If your webspace isn't on the same server as your gameserver, make sure that you have enabled external access to the database.
- Download it here
- Extract the .zip file into any folder on your webspace.
- Open the file yourFolder/config/config.php and edit the options.
- Put a link to yourFolder/index.php on your site or include it with an iframe.
- Be happy :D
Thanks to mig4ng for this awesome script :D
NOTICE
- drawns aren't logged here
- this aren't the same statistics as in the statistics.dat file, so don't remove it
KNOWN BUGS
- Sometimes it happens, that you have four in a row but the plugin doesn't notice it.
- If you enable betting, the players pay automatically when they join but don't get their money back when they leave without playing.
TODO
Bugfixes 1Upload imagesBugfixes 2Upload a videoAdd statisticsBugfixes 3fixed link to example pageimplement some functions that users have suggested

-
View User Profile
-
Send Message
Posted Feb 5, 2013@Dragon252525
Could you please reply? It's pretty easy to find out you are still active. It's not that hard to click the reply button.
-
View User Profile
-
Send Message
Posted Feb 2, 2013@Dragon252525
Dragon, just got to test this again today, and I noticed I've got the same problem. All my blocks are floating at the top and don't drop down. Never had this issue before, but seems to be happening for me on v2.0.
-
View User Profile
-
Send Message
Posted Jan 31, 2013@Dragon252525
I don't have any WorldGuard regions setup. When I just place gravel/sand myself it just falls down. This is definitely related to either the plugin or my setup of the plugin.
-
View User Profile
-
Send Message
Posted Jan 31, 2013@jesse131
perhaps you have a plugin that disables blockphysics like worldguard
-
View User Profile
-
Send Message
Posted Jan 30, 2013Somehow whenever I place a block at the trow in-bar, the sand or gravel doesnt fall down. What am I doing wrong?
-
View User Profile
-
Send Message
Posted Jan 19, 2013@CJHacker
sorry it's my fault
the command's named /cfour setecoreward (without s)
but I'm not sure if it works (for me it doesn't)
-
View User Profile
-
Send Message
Posted Jan 14, 2013@Dragon252525
Using the:
/cfour setEcoRewards 1(my game name) 100
command just returns:
ConnectFour 2.0 by Dragon252525
/cfour help
Am I entering it incorrectly?
-
View User Profile
-
Send Message
Posted Jan 13, 2013think this it i hope so
http://pastebin.com/9cZEnZsq
-
View User Profile
-
Send Message
Posted Jan 13, 2013@as0m3
could you please poste your server.log on pastebin?, so I can see what's wrong
@CJHacker
;)
-
View User Profile
-
Send Message
Posted Jan 12, 2013everytime i put the plugin in my server its not starting up like the plugin isnt working on my server. whats wrong? iv reload,restarted, redownloaded, etc. what do i do?
-
View User Profile
-
Send Message
Posted Jan 8, 2013@Dragon252525
Hey Dragon, just curious, how do we go about adding economy rewards? Thanks!
-
View User Profile
-
Send Message
Posted Dec 31, 2012Wow. That was a lot less complicated than I thought. For some reason cfour.user.* wasn't working. I just removed .* and it worked. Sorry for insinuating there was a problem with the plugin.
I'm having a problem with the rewards though, I've set the reward to give 1 emerald. I used the command /set rewards c1 388:1 I figured that would give the winner an emerald but when someone wins they aren't given anything. Am I doing it right? I dont think I am :P
-
View User Profile
-
Send Message
Posted Dec 31, 2012@ARavinMadMonkey
1. It checks if the user has the permission -> when a user is in a group that has the permission, the user has it too.
2. I'm using PermissionsEx 1.19.5 on a Craftbukkit 1.4.6 R-0.3 [#2568] server and it works fine...
@I'd also like to suggest that you add a "top ten" feature to this, or some kind of leader board so people can see how good they are compared to the rest of the server. ok I'll add this feature
-
View User Profile
-
Send Message
Posted Dec 29, 2012I'm having problems with permissions using PermissionsEX. Could you fix ASAP please? No errors or anything, the permissions just dont work. When someone who as permissions given to them by PEX tries a command they get the message "ConnectFour 2.0 by Draon252525 /cfour help" and that is the only thing they get. They cannot even do /cfour help.
I'd also like to suggest that you add a "top ten" feature to this, or some kind of leader board so people can see how good they are compared to the rest of the server.
EDIT: After talking to my friend, apparently this plugin checks for players permissions, not groups, could you please fix it so it works with groups.
-
View User Profile
-
Send Message
Posted Dec 29, 2012@Dragon252525
Installing v2.0 now! Thanks Dragon!
-
View User Profile
-
Send Message
Posted Dec 25, 2012@CJHacker
Ok i'll add those features :D
-
View User Profile
-
Send Message
Posted Dec 25, 2012@Dragon252525
I think vault would be just fine for most people that would be interested in the Eco rewards and might be easiest to code? That would be great! Great fun little plugin! A teleport back to where they enter the /c4 join command would also be handy if that's possible.
-
View User Profile
-
Send Message
Posted Dec 25, 2012@CJHacker
economy rewards usign vault? or how should I do that?
-
View User Profile
-
Send Message
Posted Dec 25, 2012@xTRU3xTOXICITY
version 1.8 should work with 1.4.6 too but there will be an update soon
-
View User Profile
-
Send Message
Posted Dec 24, 2012When Will this Be out for 1.4.6? This is a great plugin!