Hello! So I've been failing to figure out how to go about coding this for days now. I'd like to have a script where it will read the users 'Coins' value from an '.ini' file. And if they hit a certain value like 10,20,30,etc.. The bot will automatically post in chat that they have attained that appropriate rank for the amount of 'Coins' they have. for example if they just hit 20 'Coins' the bot will say something like.
"Usernamehere > Just attained Rank 2 with 20 Coins!"
Hopefully this isn't to tall of an order.. But I really can't wrap my head around how to script this.

The code for my ranking system is this. Credit to 'TabbyCakes'
Code:
///Coins///
on $*:text:/!Coins (spend)/Si:#: {
  if ($0 < 3) { msg # Insufficient parameters: Use !Coins spend <user> [number] | return }
  writeini -n Coins.ini $+(#,.,$3) Coins $calc($readini(Coins.ini,$+(#,.,$3),Coins) $iif($2 == add,+,-) $iif($4 isnum,$4,1))
  { msg $chan $3 now has $readini(Coins.ini,$+(#,.,$3),Coins) total Coins. }
}

alias -l addCoins {
  if ($1 !isnum) { echo 2 -st $1 is not a number. It needs to be a number. | halt }
  var %topic $+($chan,.,$nick)
  var %Coins $calc($readini(Coins.ini,%topic,Coins) + $1)
  writeini -n Coins.ini %topic Coins %Coins
  return %Coins
}

alias -l lookUpCoins {
  var %topic $+($chan,.,$nick)
  var %Coins $readini(Coins.ini,%topic,Coins)
  return %Coins
}
alias doaddCoins {
  if ($3 !isnum) { echo 2 -st $3 is not a number. It needs to be a number. | halt }
  var %topic $+($1,.,$2)
  var %Coins $calc($readini(Coins.ini,%topic,Coins) + $3)
  writeini -n Coins.ini %topic Coins %Coins
  echo -a Added Coins for %topic
}

alias doremCoins {
  var %topic $+($1,.,$2)
  if (%Coins !0) { echo 2-st You do not have that many Coins }
  remini -n Coins.ini %topic Coins
  echo -a Removed Coins for %topic
}

on *:text:!Coins:#:{
  if ((%floodCoins) || ($($+(%,floodCoins.,$nick),2))) { return }
  set -u10 %floodCoins On
  set -u30 %floodCoins. $+ $nick On
  msg # $nick has $readini(Coins.ini,$+(#,.,$nick),Coins) total Coins.
}

on $*:text:/!Coins (add|remove)/Si:#:{
  if ($nick isop #) {
    if ($0 < 3) { msg # Insufficient parameters: Use !Coins <add|remove> <user> [number] | return }
    writeini -n Coins.ini $+(#,.,$3) Coins $calc($readini(Coins.ini,$+(#,.,$3),Coins) $iif($2 == add,+,-) $iif($4 isnum,$4,1))
    { msg $chan $3 now has $readini(Coins.ini,$+(#,.,$3),Coins) total Coins. }
  }
  else { msg $chan This command is only available to moderators. }
}
on !*:join:#:{
  $+(.timerCoins.,#,.,$nick) 0 300 add.pts $+(#,.,$nick)
  add.pts $+(#,.,$nick)
  msg $chan Welcome $nick to the stream! Your now earning Coins, to learn more type "!help".
}
on !*:part:#:$+(.timerCoins.,#,.,$nick) off
alias -l add.pts {
  writeini -n Coins.ini $1 Coins $calc($readini(Coins.ini,$1,Coins) + 1)
}

on *:text:!level:#:{
  if ($readini(Coins.ini,$+(#,.,$nick),Coins) <= 9) { msg # $nick > 'Rank 0' with $readini(Coins.ini,$+(#,.,$nick),Coins) Coins. Gain $calc(10 - $readini(Coins.ini,$+(#,.,$nick),Coins)) more Coins to Rank up to 'Rank 1' }
  if ($readini(Coins.ini,$+(#,.,$nick),Coins) > 9) && ($readini(Coins.ini,$+(#,.,$nick),Coins) <= 19) { msg # $nick > 'Rank 1' with $readini(Coins.ini,$+(#,.,$nick),Coins) Coins. Gain $calc( 20 - $readini(Coins.ini,$+(#,.,$nick),Coins)) more Coins to Rank up to 'Rank 2' }
  if ($readini(Coins.ini,$+(#,.,$nick),Coins) > 19) && ($readini(Coins.ini,$+(#,.,$nick),Coins) <= 29) { msg # $nick > 'Rank 2' with $readini(Coins.ini,$+(#,.,$nick),Coins) Coins. Gain $calc( 30 - $readini(Coins.ini,$+(#,.,$nick),Coins)) more Coins to Rank up to 'Rank 3' }
  if ($readini(Coins.ini,$+(#,.,$nick),Coins) > 29) && ($readini(Coins.ini,$+(#,.,$nick),Coins) <= 39) { msg # $nick > 'Rank 3' with $readini(Coins.ini,$+(#,.,$nick),Coins) Coins. Gain $calc( 40 - $readini(Coins.ini,$+(#,.,$nick),Coins)) more Coins to Rank up to 'Rank 4' }
  if ($readini(Coins.ini,$+(#,.,$nick),Coins) > 39) && ($readini(Coins.ini,$+(#,.,$nick),Coins) <= 49) { msg # $nick > 'Rank 4' with $readini(Coins.ini,$+(#,.,$nick),Coins) Coins. Gain $calc( 50 - $readini(Coins.ini,$+(#,.,$nick),Coins)) more Coins to Rank up to 'Rank 5' }
  if ($readini(Coins.ini,$+(#,.,$nick),Coins) > 49) && ($readini(Coins.ini,$+(#,.,$nick),Coins) <= 59) { msg # $nick > 'Rank 5' with $readini(Coins.ini,$+(#,.,$nick),Coins) Coins. Gain $calc( 60 - $readini(Coins.ini,$+(#,.,$nick),Coins)) more Coins to Rank up to 'Rank 6' }
  if ($readini(Coins.ini,$+(#,.,$nick),Coins) > 59) && ($readini(Coins.ini,$+(#,.,$nick),Coins) <= 69) { msg # $nick > 'Rank 6' with $readini(Coins.ini,$+(#,.,$nick),Coins) Coins. Gain $calc( 70 - $readini(Coins.ini,$+(#,.,$nick),Coins)) more Coins to Rank up to 'Rank 7' }
  if ($readini(Coins.ini,$+(#,.,$nick),Coins) > 69) && ($readini(Coins.ini,$+(#,.,$nick),Coins) <= 79) { msg # $nick > 'Rank 7' with $readini(Coins.ini,$+(#,.,$nick),Coins) Coins. Gain $calc( 80 - $readini(Coins.ini,$+(#,.,$nick),Coins)) more Coins to Rank up to 'Rank 8' }
  if ($readini(Coins.ini,$+(#,.,$nick),Coins) > 79) && ($readini(Coins.ini,$+(#,.,$nick),Coins) <= 89) { msg # $nick > 'Rank 8' with $readini(Coins.ini,$+(#,.,$nick),Coins) Coins. Gain $calc( 90 - $readini(Coins.ini,$+(#,.,$nick),Coins)) more Coins to Rank up to 'Rank 9' }
  if ($readini(Coins.ini,$+(#,.,$nick),Coins) > 89) && ($readini(Coins.ini,$+(#,.,$nick),Coins) >= 100) { msg # $nick > 'Rank 9' with $readini(Coins.ini,$+(#,.,$nick),Coins) Coins. }
}