Newbie here, need a little Java help

Hello, I am trying to set up a Minecraft server for me and my friends using the following mods:

-iChuns Portal gun

-iChuns Gravity Gun

-Lambdacraft

 

The server is a Forge Modloader 1.6.4 server, and I have a problem. There are 5 different portal gun types (I have the max players set to 5) and I need each player that joins to be given a different portal gun (otherwise one can change the other's portals). I have more than 5 friends that play, and they're not all tech-savvy, so I was trying to come up with an automated system to give out the portal guns based on the order of who joins when. For example:

Bob joins 1st, he gets portal gun type 1

Bill joins later, he gets the next type

Sam joins next, he gets the third type

But the guns should also stay in the players inventory after they respawn(along with a set of the lambdacraft weapons), and if they join in a different order later, the player might get a new gun. Just as long as every player has a different gun from the others.

This server will run Bukkit plugins (written in Java) and I know nothing of Java. Can anyone point me to a plugin I can use for this, or perhaps help me cobble together an unofficial solution?

Thanks

try this: http://dev.bukkit.org/bukkit-plugins/starterkit/

"But the guns should also stay in the players inventory after they respawn":  this is a feature of vanilla minecraft, just type: " /gamerule keepInventory true"

Thanks, I forgot about the /gamerule thing. :D I'll see if I can get it working, thanks a lot

Thank you for the tips, I got 90% of it worked out. I couldn't get the keepinventory rule to work, but there's an option to re-give the startkit every time someone respawns, so it worked out. However, I still have no way of giving each player a different type of Portal gun. Any ideas?