在游戏制作者中获取DoMul错误

时间:2015-09-30 19:25:51

标签: game-maker

基本上我要做的是将用户输入的数字乘以1到9之间生成的随机数。然后我想显示一条消息,说明他们得到的随机数(幸运数字)和他们的总分数收到它(用户输入*随机数)。每次我这样做,我都会收到错误DoMul。我错过了乘法方程中的某些内容吗?非常感谢任何帮助。

//inputs: Get number of points from user
var points, luckNum, ranNum, total;
points = get_string("Please enter the amount of points: ",1);

//processing: generate a random number(1-9)
ranNum = random(9);

//multply lucky number and the points entered
total = points*ranNum;


//output: a message to user stating lucky number and the total points to be 
added                 
message = "Your lucky number is: ." + string(ranNum)+ "The total points to  
be added is: ." + string(total);     
show_message(message);


//updated score

}

0 个答案:

没有答案