This line cannot exist. You have a bunch of lines all cobbled into one in no way that makes sense.

writeini -n Points.ini $1 Points $calc($readini(Points.ini,$1,Points /set %rand $rand(1,10) { if (%rand == 1) { /msg $chan You win 5 points }

Overall your code has a dozen glaring syntactic errors that makes it look like you just copied chunks of code from other people's scripts and pasted them in randomly.

But if you'd like to learn some logic, check this out:

Originally Posted By: Malko
/set %rand $rand(1,10)
if (%rand == 1) { /msg $chan You win 5 points }
elseif (%rand == 2) { /msg $chan You win 10 points }
elseif (%rand == 3) { /msg $chan You win 20 points }
elseif (%rand == 4) { /msg $chan You win 30 points }
elseif (%rand == 5) { /msg $chan You win 40 points }
elseif (%rand == 6) { /msg $chan You win 50 points }
elseif (%rand == 7) { /msg $chan You win 60 points }
elseif (%rand == 8) { /msg $chan You win 70 points }
elseif (%rand == 9) { /msg $chan You win 80 points }
elseif (%rand == 10) { /msg $chan You win 90 points }
else { /msg $chan You win 150 points }


becomes

Code:
var %rand = $rand(1,10)
var %pointlist = 5,10,20,30,40,50,60,70,80,150
var %points = $gettok(%pointlist,%rand,44)
msg $chan $nick wins %points points!


You might notice in your code that if %rand can be a number 1 through 10, there's no possible way for "else" to arrive at 150 points... so I replaced 90 with 150.

Anyway, good luck.

I highly recommend writing your own code from scratch and avoid any copy/pasting from other people's scripts you don't fully understand letter for letter.


Well. At least I won lunch.
Good philosophy, see good in bad, I like!