on *:TEXT:!vd *:#:{
if (%vd == 1) { if (%vdplay == 0 || !%vdplay)
if (!$4) { notice $nick Specify the troops please. | halt }
if ($calc($2 + ($3*2) + ($4*4)) >= 20000) { notice $nick You have spent too many points. Please see !vdrules to see how much you can spend. | halt }
if (%play == 1) { notice $nick A game is already being played. | halt }
if (%vd == 0) { notice $nick Violent Diplomacy is not currently on. Please contact Jcfc so he can turn it on. | halt }
if ($calc($2 + ($3*2) + ($4*4)) <= 20000) {
msg $chan $nick wants to play Violent Diplomacy! Type !vd [INFANTRY] [DRAGOONS] [CAVALRY] to play with him.
set %vdplay 1
set %p1inf $2
set %p1drag $3
set %p1cav $4
set %player1 $nick
}
{ if (%vdplay == 1)
if (!$4) { notice $nick Specify the troops please. | halt }
if ($calc($2 + ($3*2) + ($4*4)) >= 20000) { notice $nick You have spent too many points. Please see !vdrules to see how much you can spend. | halt }
if (%play == 1) { notice $nick A game is already being played. | halt }
if (%vd == 0) { notice $nick Violent Diplomacy is not currently on. Please contact Jcfc so he can turn it on. | halt }
if ($calc($2 + ($3*2) + ($4*4)) <= 20000) {
msg $chan The game is on! %player1 vs. %player2 $+ .
set %vdplay 1
set %p2inf $2
set %p2drag $3
set %p2cav $4
set %player2 $nick
}
}
}
else { notice $nick Violent Diplomacy is not currently on. Please contact Jcfc so he can turn it on. | halt }
}
on *:TEXT:!vd:#:{ notice $nick Please specify troop numbers. }