Fix /makeitem looking up the template by string instead of template id
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
42a1c8a532
commit
4e30a04619
1 file changed
+2
-3
@@ -62,11 +62,10 @@ public class MakeItemCmd extends AbstractDevCmd {
|
||||
ItemTemplate template;
|
||||
try {
|
||||
templateID = Integer.parseInt(words[0]);
|
||||
template = ItemTemplate.templates.get(words[0].toLowerCase());
|
||||
template = ItemTemplate.templates.get(templateID);
|
||||
|
||||
if (template == null) {
|
||||
throwbackError(pc, "Supplied type " + words[0]
|
||||
+ " failed to parse to an Integer");
|
||||
throwbackError(pc, "No item template with id " + words[0]);
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user