[script] n0=on *:TEXT:!*:#: { n1= if ($1 == !duel) { n2= if (%duelstatus == on) { n3= /msg $chan There is a duel in progress, please wait untill it is over before starting another duel. n4= } n5= if (%duelstatus != on) { n6= /set %duelstatus on n7= /set %id1_stats unset n8= /set %id2_stats unset n9= /set %idduel1 $nick n10= /set %idduel2 $2- n11= /msg $chan  $+ $nick challenges $2- to a duel! n12= /msg $chan Both players, type in your attack, strength, defence, and hitpoints levels. n13= /msg $chan they must add up and be less than or equal to 355. n14= /msg $chan to do this type !setstats (attack) (strength) (defence) (hitpoints) n15= } n16= } n17= if ($1 == !setstats) { n18= if (($nick == %idduel1) || ($nick == %idduel2)) { n19= if (($nick == %idduel1) && ( %id1_stats != set )) { n20= /set %id1_total $calc( $2 + $3 + $4 + $5 ) n21= if ( %id1_total < 356 ) { n22= if (( $2 < 100 ) && ( $3 < 100 ) && ( $4 < 100 ) && ( $5 < 100 )) { n23= /set %id1_attack $2 n24= /set %id1_strength $3 n25= /set %id1_defence $4 n26= /set %id1_hitpoints $5 n27= /set %id1_stats set n28= /set %id1_ddsspecs 4 n29= /set %id1_sharks 20 n30= /set %turn $rand(1,2) n31= if (%turn == 1) { n32= /set %idturn %idduel1 n33= } n34= if (%turn == 2) { n35= /set %idturn %idduel2 n36= } n37= /msg $chan  $+ %idduel1 $+ 's stats are: Attack: %id1_attack Strength: %id1_strength Defence: %id1_defence Hitpoints: %id1_hitpoints  n38= if ((%id1_stats == set) && (%id2_stats == set)) { n39= /msg $chan The duel has begun! %idturn $+ 's turn first. n40= /msg $chan You each get 20 sharks, 4 DDS special attacks/D mace special attacks. n41= /msg $chan The options are, !whip, !dds, !mace, and !eat. n42= /msg $chan Type !endduel anytime to end the duel. n43= } n44= } n45= } n46= } n47= if (($nick == %idduel2) && ( %id2_stats != set )) { n48= /set %id2_total $calc( $2 + $3 + $4 + $5 ) n49= if ( %id2_total < 356 ) { n50= if (( $2 < 100 ) && ( $3 < 100 ) && ( $4 < 100 ) && ( $5 < 100 )) { n51= /set %id2_attack $2 n52= /set %id2_strength $3 n53= /set %id2_defence $4 n54= /set %id2_hitpoints $5 n55= /set %id2_stats set n56= /set %id2_ddsspecs 4 n57= /set %id2_sharks 20 n58= /msg $chan  $+ %idduel2 $+ 's stats are: Attack: %id2_attack Strength: %id2_strength Defence: %id2_defence Hitpoints: %id2_hitpoints  n59= if ((%id1_stats == set) && (%id2_stats == set)) { n60= /msg $chan The duel has begun! %idturn $+ 's turn first. n61= /msg $chan You each get 20 sharks, 4 DDS special attacks/D mace special attacks. n62= /msg $chan The options are, !whip, !dds, !mace, and !eat. n63= /msg $chan Type !endduel anytime to end the duel. n64= } n65= } n66= } n67= } n68= } n69= } n70= if ($1 == !whip) { n71= if ($nick == %idturn) { n72= if (%turn == 1) { n73= /set %attkminusdef $calc( %id1_attack - %id2_defence + 100 ) n74= } n75= if (%turn == 2) { n76= /set %attkminusdef $calc( %id2_attack - %id1_defence + 100 ) n77= } n78= /set %randhitnum $rand(0,200) n79= if (%attkminusdef > %randhitnum) { n80= /set %attkworks true n81= } n82= if (%attkminusdef <= %randhitnum) { n83= /set %attkworks false n84= } n85= if (%attkworks == false) { n86= if (%turn == 1) { n87= /msg $chan  $+ %idduel1 whips %idduel2 and hits: 0 n88= } n89= if (%turn == 2) { n90= /msg $chan  $+ %idduel2 whips %idduel1 and hits: 0 n91= } n92= } n93= if (%attkworks == true) { n94= if (%turn == 1) { n95= /set %maxhit $floor($calc( %id1_strength * .42 )) n96= /set %damagehit $rand(0,%maxhit) n97= /set %id2_hitpoints $calc( %id2_hitpoints - %damagehit ) n98= /msg $chan  $+ %idduel1 whips %idduel2 and hits: %damagehit  n99= if ( %id2_hitpoints < 1 ) { n100= /msg $chan  $+ %idduel1 wins with %id1_hitpoints hitpoints left. n101= /set %win true n102= } n103= if ( %win != true ) { n104= /msg $chan  $+ %idduel2 has %id2_hitpoints hitpoints left. n105= } n106= } n107= if (%turn == 2) { n108= /set %maxhit $floor($calc( %id2_strength * .42 )) n109= /set %damagehit $rand(0,%maxhit) n110= /set %id1_hitpoints $calc( %id1_hitpoints - %damagehit ) n111= /msg $chan  $+ %idduel2 whips %idduel1 and hits: %damagehit  n112= if ( %id1_hitpoints < 1 ) { n113= /msg $chan  $+ %idduel2 wins with %id2_hitpoints hitpoints left. n114= /set %win true n115= } n116= if ( %win != true ) { n117= /msg $chan  $+ %idduel1 has %id1_hitpoints hitpoints left. n118= } n119= } n120= } n121= if ( %turn == 1 ) { n122= /set %turn 2 n123= /set %idturn %idduel2 n124= } n125= else { n126= /set %turn 1 n127= /set %idturn %idduel1 n128= } n129= } n130= } n131= if ($1 == !dds) { n132= if ($nick == %idturn) { n133= if (%turn == 1) { n134= if ( %id1_ddsspecs < 1 ) { /set %id1_outofddsspecs true } n135= /set %attkminusdef $calc( %id1_attack - %id2_defence + 100 ) n136= } n137= if (%turn == 2) { n138= if ( %id2_ddsspecs < 1 ) { /set %id2_outofddsspecs true } n139= /set %attkminusdef $calc( %id2_attack - %id1_defence + 100 ) n140= } n141= /set %randhitnum $rand(0,250) n142= /set %randhitnum2 $rand(0,250) n143= if ( %attkminusdef > %randhitnum ) { n144= /set %attkworks1 true n145= } n146= if ( %attkminusdef > %randhitnum2 ) { n147= /set %attkworks2 true n148= } n149= if ( %attkminusdef <= %randhitnum ) { n150= /set %attkworks1 false n151= } n152= if ( %attkminusdef <= %randhitnum2 ) { n153= /set %attkworks2 false n154= } n155= if (( %turn == 1 ) && ( %id1_outofddsspecs != true )) { n156= /set %maxhit $floor($calc( %id1_strength * .365 )) n157= /set %damagehit $rand(0,%maxhit) n158= /set %damagehit2 $rand(0,%maxhit) n159= if ( %attkworks1 == false ) { /set %damagehit 0 } n160= if ( %attkworks2 == false ) { /set %damagehit2 0 } n161= /set %id2_hitpoints $calc( %id2_hitpoints - %damagehit - %damagehit2 ) n162= /set %id1_ddsspecs $calc( %id1_ddsspecs - 1 ) n163= /msg $chan  $+ %idduel1 DDS specs %idduel2 and hits: %damagehit $+ - $+ %damagehit2  n164= if ( %id2_hitpoints < 1 ) { n165= /msg $chan  $+ %idduel1 wins with %id1_hitpoints hitpoints left. n166= /set %win true n167= } n168= if ( %win != true ) { n169= /msg $chan  $+ %idduel2 has %id2_hitpoints hitpoints left. n170= } n171= } n172= if ((%turn == 2 ) && ( %id2_outofddsspecs != true )) { n173= /set %maxhit $floor($calc( %id2_strength * .365 )) n174= /set %damagehit $rand(0,%maxhit) n175= /set %damagehit2 $rand(0,%maxhit) n176= if ( %attkworks1 == false ) { /set %damagehit 0 } n177= if ( %attkworks2 == false ) { /set %damagehit2 0 } n178= /set %id1_hitpoints $calc( %id1_hitpoints - %damagehit - %damagehit2 ) n179= /set %id2_ddsspecs $calc( %id2_ddsspecs - 1 ) n180= /msg $chan  $+ %idduel2 DDS specs %idduel1 and hits: %damagehit $+ - $+ %damagehit2  n181= if ( %id1_hitpoints < 1 ) { n182= /msg $chan  $+ %idduel2 wins with %id2_hitpoints hitpoints left. n183= /set %win true n184= } n185= if ( %win != true) { n186= /msg $chan  $+ %idduel1 has %id1_hitpoints hitpoints left. n187= } n188= } n189= if ( %turn == 1 ) { n190= /set %turn 2 n191= /set %idturn %idduel2 n192= } n193= else { n194= /set %turn 1 n195= /set %idturn %idduel1 n196= } n197= } n198= } n199= if ($1 == !mace) { n200= if ($nick == %idturn) { n201= if (%turn == 1) { n202= if ( %id1_ddsspecs < 1 ) { /set %id1_outofddsspecs true } n203= /set %attkminusdef $calc( %id1_attack - %id2_defence + 100 ) n204= } n205= if (%turn == 2) { n206= if ( %id2_ddsspecs < 1 ) { /set %id2_outofddsspecs true } n207= /set %attkminusdef $calc( %id2_attack - %id1_defence + 100 ) n208= } n209= /set %randhitnum $rand(0,250) n210= if (%attkminusdef > %randhitnum) { n211= /set %attkworks true n212= } n213= if (%attkminusdef <= %randhitnum) { n214= /set %attkworks false n215= } n216= if (%attkworks == false) { n217= if (%turn == 1) { n218= /msg $chan  $+ %idduel1 mace specs %idduel2 and hits: 0 n219= } n220= if (%turn == 2) { n221= /msg $chan  $+ %idduel2 mace specs %idduel1 and hits: 0 n222= } n223= } n224= if (%attkworks == true) { n225= if ((%turn == 1) && ( %id1_outofddsspecs != true )) { n226= /set %maxhit $floor($calc( %id1_strength * .61 )) n227= /set %damagehit $rand(0,%maxhit) n228= /set %id2_hitpoints $calc( %id2_hitpoints - %damagehit ) n229= /set %id1_ddsspecs $calc( %id1_ddsspecs - 1 ) n230= /msg $chan  $+ %idduel1 mace specs %idduel2 and hits: %damagehit  n231= if ( %id2_hitpoints < 1 ) { n232= /msg $chan  $+ %idduel1 wins with %id1_hitpoints hitpoints left. n233= /set %win true n234= } n235= if ( %win != true ) { n236= /msg $chan  $+ %idduel2 has %id2_hitpoints hitpoints left. n237= } n238= } n239= if ((%turn == 2) && ( %id2_outofddsspecs != true)) { n240= /set %maxhit $floor($calc( %id2_strength * .61 )) n241= /set %damagehit $rand(0,%maxhit) n242= /set %id1_hitpoints $calc( %id1_hitpoints - %damagehit ) n243= /set %id2_ddsspecs $calc( %id2_ddsspecs - 1 ) n244= /msg $chan  $+ %idduel2 mace specs %idduel1 and hits: %damagehit  n245= if ( %id1_hitpoints < 1 ) { n246= /msg $chan  $+ %idduel2 wins with %id2_hitpoints hitpoints left. n247= /set %win true n248= } n249= if ( %win != true ) { n250= /msg $chan  $+ %idduel1 has %id1_hitpoints hitpoints left. n251= } n252= } n253= } n254= if ( %turn == 1 ) { n255= /set %turn 2 n256= /set %idturn %idduel2 n257= } n258= else { n259= /set %turn 1 n260= /set %idturn %idduel1 n261= } n262= } n263= } n264= if ($1 == !eat) { n265= if ( $nick == %idturn ) { n266= if ( %turn == 1 ) { n267= /set %sharkseaten $rand(1,3) n268= if ( %sharkseaten == 2) { n269= /set %sharkseaten 1 n270= } n271= if ( %sharkseaten == 3) { n272= /set %sharkseaten 2 n273= } n274= if ( %id1_sharks == 1) { n275= /set %sharkseaten 1 n276= } n277= if (( %sharkseaten == 1) && ( %id1_sharks > 0 )) { n278= /set %id1_hitpoints $calc( %id1_hitpoints + 20 ) n279= /set %id1_sharks $calc( %id1_sharks - 1 ) n280= /msg $chan  $+ %idduel1 eats a shark. n281= } n282= if ( %sharkseaten == 2) { n283= /set %id1_hitpoints $calc( %id1_hitpoints + 40 ) n284= /set %id1_sharks $calc( %id1_sharks - 2 ) n285= /msg $chan  $+ %idduel1 eats two sharks. n286= } n287= } n288= if ( %turn == 2 ) { n289= /set %sharkseaten $rand(1,3) n290= if ( %sharkseaten == 2) { n291= /set %sharkseaten 1 n292= } n293= if ( %sharkseaten == 3) { n294= /set %sharkseaten 2 n295= } n296= if ( %id1_sharks == 1) { n297= /set %sharkseaten 1 n298= } n299= if (( %sharkseaten == 1) && ( %id2_sharks > 0 )) { n300= /set %id2_hitpoints $calc( %id2_hitpoints + 20 ) n301= /set %id2_sharks $calc( %id2_sharks - 1 ) n302= /msg $chan  $+ %idduel2 eats a shark. n303= } n304= if ( %sharkseaten == 2) { n305= /set %id2_hitpoints $calc( %id2_hitpoints + 40 ) n306= /set %id2_sharks $calc( %id2_sharks - 2 ) n307= /msg $chan  $+ %idduel2 eats two sharks. n308= } n309= } n310= if ( %turn == 1 ) { n311= /set %turn 2 n312= /set %idturn %idduel2 n313= } n314= else { n315= /set %turn 1 n316= /set %idturn %idduel1 n317= } n318= } n319= } n320= if (($1 == !endduel) || ( %win == true )) { n321= if (($nick == %idduel1) || ($nick == %idduel2) || ($nick == Compgeek1210)) { n322= /unset %duelstatus n323= /unset %id1_stats n324= /unset %id2_stats n325= /unset %idduel1 n326= /unset %idduel2 n327= /unset %id1_attack n328= /unset %id1_strength n329= /unset %id1_defence n330= /unset %id1_hitpoints n331= /unset %id1_stats n332= /unset %id1_ddsspecs n333= /unset %id1_sharks n334= /unset %turn n335= /unset %id1_total n336= /unset %id2_attack n337= /unset %id2_strength n338= /unset %id2_defence n339= /unset %id2_hitpoints n340= /unset %id2_stats n341= /unset %id2_ddsspecs n342= /unset %id2_sharks n343= /unset %id2_total n344= /unset %attkminusdef n345= /unset %randhitnum n346= /unset %attkworks n347= /unset %maxhit n348= /unset %damagehit n349= /unset %damagehit2 n350= /unset %win n351= /unset %id1_outofddsspecs n352= /unset %id2_outofddsspecs n353= /unset %sharkseaten n354= /unset %randhitnum2 n355= /unset %attkworks1 n356= /unset %attkworks2 n357= /unset %idturn n358= /msg $chan Duel Ended n359= } n360= } n361=} n362=; Written by Compgeek1210