Ok, so I'm new here and new to coding stuff. But based off of many things I have read I have started to make my own chat bot I currently have a points system working and working well but I've been trying raffle systems currently this is the most common one I have found but for some reason my bot won't even respond after I put in the commands any Ideas?
on TEXT:!Skulls $:#:{
if (%raffle = 1) {
if ($2 > 10) {
msg $chan Sorry $nick but you can only get up to 10 skulls!
}
if ($2 < 11) {
var %i = 0
var %ticket = $2
var %topic = $+(#,.,$nick)
var %user = $readini (Points.ini,%topic,Points)
var %end = 10 %ticket
var %delete = %user - %end
if (%delete > 0) {
writeini -n Points.ini %topic Points %delete
while (%i < %ticket) {
write Raffle.txt $nick
%i = %i + 1
}
msg $chan $nick you have bought %ticket skulls with %end Scars.
}
}
}
if (%raffle == 0) {
msg $chan No skulls for sale at this time!
}
}
on :TEXT:!openbag:#:{
if ($nick isop #) {
if (%raffle == 0) {
msg $chan Buy some !skulls and throw them in my bag Ill pick one and its owner will win!!!
set %raffle 1
write -c Raffle.txt
}
}
}
on :TEXT:!closebag:#:{
if ($nick isop #) {
if ($raffle == 1) {
msg $chan The Bag has been closed!!
set %raffle 0
write -c Raffle.txt
}
}
}
on *:TEXT:!pick:#:{
if ($nick isop #) {
if (%raffle == 1) {
var %user = $read(Raffle.txt, n)
msg $chan /me Reaches into bag digs around
.timerOne 1 1 msg $chan /me 5!
.timerTwo 1 2 msg $chan /me 4!
.timerThree 1 3 msg $chan /me 3!
.timerFour 1 4 msg $chan /me 2!
.timerFive 1 5 msg $chan /me 1!
.timerSix 1 6 msg $chan AND THE WINNER IS:
.timerSeven 1 7 msg $chan %user
set %raffle 0
write -c Raffle.txt
}
}
}
As is apparent I also couldn't get it to appear properly