@best_quality = 0
@level_set = [10, 0, ""]
@level_set.each {|i|@best_quality += i[0]} #请教这句要怎么理解?
n_el = 6
new_element = new_element|[n_el] #请教这个“|”用在这起什么作用?
#为什么我写成“new_element = n_el”又没有效果
equipment = $data_weapons[id] if type == "weapon" #这样的写法和下面的写法哪种好些?
if type == "weapon" #和上面的写法区别在哪里?(是运算快还是什么?)
equipment = $data_weapons[id]
end
100.times do #是循环100次的意思吗?
end
@best_quality = 0
@level_set = [10, 0, ""]
@level_set.each {|i|@best_quality += i[0]} #请教这句要怎么理解?
n_el = 6
new_element = new_element|[n_el] #请教这个“|”用在这起什么作用?
#为什么我写成“new_element = n_el”又没有效果
equipment = $data_weapons[id] if type == "weapon" #这样的写法和下面的写法哪种好些?
if type == "weapon" #和上面的写法区别在哪里?(是运算快还是什么?)
equipment = $data_weapons[id]
end
100.times do #是循环100次的意思吗?
end