rendered paste bodyon *:TEXT:!dh*:#:{
if (%dmrun) {
if ($nick != %dmp1) && ($nick != %dmp2) {
.notice $nick 2You are not fighting in this Dm.
}
else {
if ($nick != %turn) {
.notice $nick 2It is not your turn.
}
else {
if ($nick == %dmp1) {
.timerdmlimit off
.timerdmlimit 1 60 switchturn %dmp2 %dmp1
if (%froze [ $+ [ %dmp1 ] ]) {
dec %froze [ $+ [ %dmp1 ] ]
$iif(%froze [ $+ [ %dmp1 ] ] <= 0, unset %froze [ $+ [ %dmp1 ] ])
msg $chan 2It is now %dmp2 $+ 's turn.
.notice $nick 2You have been frozen and may not attack with your dharoks.
set %turn %dmp2
halt
}
else {
if (%dhu [ $+ [ %dmp1 ] ]) {
msg $chan 2It is now %dmp2 $+ 's turn.
.notice $nick 2You have used your dharoks before, and may not fight in fully degraded armour.
set %turn %dmp2
halt
}
else {
set %dhp2 $rand(0,$floor($calc($calc(100 - %hp [ $+ [ %dmp1 ] ] ) / 3 * $rand(.5,3))))
if (%dhp2 < %hp [ $+ [ %dmp2 ] ]) {
dec %hp [ $+ [ %dmp2 ] ] %dhp2
msg $chan 2 %dmp1 has hit %dmp2 with their dharoks and has done4 %dhp2 2damage. %dmp2 has3 %hp [ $+ [ %dmp2 ] ] 2hp left.
if (%spec [ $+ [ %dmp1 ] ] < 100) {
inc %spec [ $+ [ %dmp1 ] ] 5
}
msg $chan 2It is now %dmp2 $+ 's turn.
set %turn %dmp2
set %dhu [ $+ [ %dmp1 ] ]
unset %dhp2
halt
}
if (%dhp2 >= %hp [ $+ [ %dmp2 ] ]) {
set %dhp2 %hp [ $+ [ %dmp2 ] ]
dec %hp [ $+ [ %dmp2 ] ] %dhp2
msg $chan 2 %dmp1 has hit a4 %dhp2 2with their dharoks leaving %dmp2 with3 %hp [ $+ [ %dmp2 ] ] 2hp. Congratulations %dmp1 $+ , you won the Dm!
dmwinner %dmp2 %dmp1
stopdm
Halt
}
}
}
}
if ($nick == %dmp2) {
.timerdmlimit off
.timerdmlimit 1 60 switchturn %dmp1 %dmp2
if (%froze [ $+ [ %dmp2 ] ]) {
dec %froze [ $+ [ %dmp2 ] ]
$iif(%froze [ $+ [ %dmp2 ] ] <= 0, unset %froze [ $+ [ %dmp2 ] ])
.notice $nick 2You have been frozen and may not attack with your dharoks.
msg $chan 2It is now %dmp1 $+ 's turn.
set %turn %dmp1
}
else {
if (%dhu [ $+ [ %dmp2 ] ]) {
msg $chan 2It is now %dmp1 $+ 's turn.
.notice $nick 2You have used your dharoks before, and may not fight in fully degraded armour.
set %turn %dmp1
halt
}
set %dhp1 $rand(0,$floor($calc($calc(100 - %hp [ $+ [ %dmp2 ] ] ) / 3 * $rand(.5,3))))
if (%dhp1 < %hp [ $+ [ %dmp1 ] ]) {
dec %hp [ $+ [ %dmp1 ] ] %dhp1
msg $chan 2 %dmp2 has hit %dmp1 with their dharoks and has done 4 $+ %dhp1 2damage. %dmp1 has 3 $+ %hp [ $+ [ %dmp1 ] ] 2hp left.
if (%spec [ $+ [ %dmp2 ] ] < 100) {
inc %spec [ $+ [ %dmp2 ] ] 5
}
msg $chan 2 It is now %dmp1 $+ 's turn.
set %turn %dmp1
set %dhu [ $+ [ %dmp2 ] ]
unset %dhp1
halt
}
if (%dhp1 >= %hp [ $+ [ %dmp1 ] ]) {
set %dhp1 %hp [ $+ [ %dmp1 ] ]
dec %hp [ $+ [ %dmp1 ] ] %dhp1
msg $chan 2 %dmp2 has hit a4 %dhp1 2with their dharoks leaving %dmp1 with3 %hp [ $+ [ %dmp1 ] ] 2hp. Congratulations %dmp2 $+ , you won the Dm!
dmwinner %dmp1 %dmp2
stopdm
Halt
}
}
}
}
}
}
}