HooThaFuck
Active member
- Joined
- Apr 18, 2015
- Messages
- 51
- Reaction score
- 0
First off, I'm using this. The updated code is this:
	
	
	
		
When the message is received nothing happens, I'm not sure if it's being detected or not. If it is then the problem might be negative numbers. Using the code above I check the second and third to last line. It might also be the random wait time, can wait be used like that?
			
			
		Code:
	
	{$CLEO}
thread "QUIZ" 
wait 5000 
while true
wait 0
end 
:QUIZ_25
wait 0 
if 
   SAMP.Available
then
0AC8: 1@ = 256
0AC8: 2@ = 256
0AC8: 3@ = 256
0AC8: 4@ = 256     
SAMP.GetChatString(97, 1@, 2@, 3@, 4@)                                           
if                
    0C18: 9@ = strstr string1 1@ string2 "Solve this question for money:"
then 
    jump @QUIZ_26  
else    
    //Multiply
    IF
        0AD4: 33@ = scan_string 1@ format "Solve this question for money: %d * %d * %d ?" 5@ 6@ 7@
    THEN
        006A:5@ *= 6@
        006A:5@ *= 7@ 
    END
    
    IF
        0AD4: 33@ = scan_string 1@ format "Solve this question for money: %d * %d ?" 5@ 6@
    THEN
        006A:5@ *= 6@  
    END
    
    //Divide
    IF
        0AD4: 33@ = scan_string 1@ format "Solve this question for money: %d / %d / %d ?" 5@ 6@ 7@
    THEN
        0072:5@ /= 6@
        0072:5@ /= 7@ 
    END
    
    IF
        0AD4: 33@ = scan_string 1@ format "Solve this question for money: %d / %d ?" 5@ 6@
    THEN
        0072:5@ /= 6@  
    END
           
    //Add
    IF
        0AD4: 33@ = scan_string 1@ format "Solve this question for money: %d + %d + %d ?" 5@ 6@ 7@
    THEN
        005A: 5@ += 6@
        005A: 5@ += 7@
    END   
    
    IF
        0AD4: 33@ = scan_string 1@ format "Solve this question for money: %d + %d ?" 5@ 6@
    THEN
        005A: 5@ += 6@  
    END    
           
    //Subtract
    IF
        0AD4: 33@ = scan_string 1@ format "Solve this question for money: %d - %d - %d ?" 5@ 6@ 7@
    THEN
        0062: 5@ -= 6@
        0062: 5@ -= 7@
    END   
    
    IF
        0AD4: 33@ = scan_string 1@ format "Solve this question for money: %d - %d ?" 5@ 6@
    THEN
        0062: 5@ -= 6@  
    END     
    
    0209: 15@ = random_int_in_ranges 500 2500
  
    wait 15@
    0AD3: 30@v = format "/answer %d" 5@
    say 30@v 
    wait 50   
     
    0AC9: 1@
    0AC9: 2@
    0AC9: 3@
    0AC9: 4@      
end
end
:QUIZ_26
wait 0 
if 
   SAMP.Available
then
0AC8: 1@ = 256
0AC8: 2@ = 256
0AC8: 3@ = 256
0AC8: 4@ = 256     
SAMP.GetChatString(98, 1@, 2@, 3@, 4@)                                           
if                
    0C18: 9@ = strstr string1 1@ string2 "Solve this question for money:"
then 
    jump @QUIZ_25  
else    
    //Multiply
    IF
        0AD4: 33@ = scan_string 1@ format "Solve this question for money: %d * %d * %d ?" 5@ 6@ 7@
    THEN
        006A:5@ *= 6@
        006A:5@ *= 7@ 
    END
    
    IF
        0AD4: 33@ = scan_string 1@ format "Solve this question for money: %d * %d ?" 5@ 6@
    THEN
        006A:5@ *= 6@  
    END
    
    //Divide
    IF
        0AD4: 33@ = scan_string 1@ format "Solve this question for money: %d / %d / %d ?" 5@ 6@ 7@
    THEN
        0072:5@ /= 6@
        0072:5@ /= 7@ 
    END
    
    IF
        0AD4: 33@ = scan_string 1@ format "Solve this question for money: %d / %d ?" 5@ 6@
    THEN
        0072:5@ /= 6@  
    END
           
    //Add
    IF
        0AD4: 33@ = scan_string 1@ format "Solve this question for money: %d + %d + %d ?" 5@ 6@ 7@
    THEN
        005A: 5@ += 6@
        005A: 5@ += 7@
    END   
    
    IF
        0AD4: 33@ = scan_string 1@ format "Solve this question for money: %d + %d ?" 5@ 6@
    THEN
        005A: 5@ += 6@  
    END    
           
    //Subtract
    IF
        0AD4: 33@ = scan_string 1@ format "Solve this question for money: %d - %d - %d ?" 5@ 6@ 7@
    THEN
        0062: 5@ -= 6@
        0062: 5@ -= 7@
    END   
    
    IF
        0AD4: 33@ = scan_string 1@ format "Solve this question for money: %d - %d ?" 5@ 6@
    THEN
        0062: 5@ -= 6@  
    END     
    
    0209: 15@ = random_int_in_ranges 500 2500
    wait 15@
    0AD3: 30@v = format "/answer %d" 5@
    say 30@v 
    wait 50   
     
    0AC9: 1@
    0AC9: 2@
    0AC9: 3@
    0AC9: 4@      
end
end 
				 
 
		