Files
wsmud/world/obj/sp/tool/er2.js
2026-05-26 16:41:20 +08:00

27 lines
577 B
JavaScript
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
this.inherits(OBJ);
this.set({
unit: "包",
name: "鱼饵",
desc: "一些钓鱼用到的鱼饵可能有50-100个同品质鱼饵",
value: 100
});
this.transable = true;
this.on_create = function (path, par) {
if (!par) return;
par = par.substr(1);
var lv = parseInt(par);
if (!(lv > 0 && lv < 6)) return;
this.grade = lv;
this.value = lv * 10000;
}
this.on_open = function (me) {
var result = [
{
obj: 'sp/tool/er#' + this.grade, min: 50, max: 100
}
];
return OBJ.create_by_odds(result);
}