mIRC Homepage
Posted By: bloupx identifier - 12/04/03 09:57 PM
hello,
i'd like to write an identifier but i'm cant think of how to do it.
here's what it should do

alias identifier {
if ($1 == 200) return 8
if ($1 == 100) return 16
if ($1 == 50) return 32
if ($1 == 25) return 64
}
that is basically it , except i want it to work for all numbers from 1-500.
if needed i'll $round the result.
ty for anyone's affort into this smile
Posted By: theRat Re: identifier - 13/04/03 01:52 AM
Code:
  
alias identifier {
if (( $isid ) && ( $1 isnum 1-500 )) {
return $calc( 200 / $1 * 8 )
}
}
Posted By: hatch Re: identifier - 13/04/03 01:54 AM
You are probably after this function: y = 1600 / x.
This should do it (for all numbers):
Code:
alias 1600_by_x {
  return $calc( 1600 / ( $1 ) )
}


hf,
--hatch
© mIRC Discussion Forums