mirror of
https://github.com/2006-Scape/apollo.git
synced 2026-07-07 00:38:46 +00:00
Fix ::item and ::remove commands.
This commit is contained in:
@@ -10,7 +10,8 @@ on :command, :item, RIGHTS_ADMIN do |player, command|
|
|||||||
next
|
next
|
||||||
end
|
end
|
||||||
|
|
||||||
id = args[0].to_i, amount = args.length == 2 ? args[1].to_i : 1
|
id = args[0].to_i
|
||||||
|
amount = args.length == 2 ? args[1].to_i : 1
|
||||||
if (id < 0 || id >= ItemDefinition.count)
|
if (id < 0 || id >= ItemDefinition.count)
|
||||||
player.send_message('The item id you specified is out of bounds!')
|
player.send_message('The item id you specified is out of bounds!')
|
||||||
next
|
next
|
||||||
@@ -27,7 +28,8 @@ on :command, :remove, RIGHTS_MOD do |player, command|
|
|||||||
next
|
next
|
||||||
end
|
end
|
||||||
|
|
||||||
id = args[0].to_i, amount = args.length == 2 ? args[1].to_i : 1
|
id = args[0].to_i
|
||||||
|
amount = args.length == 2 ? args[1].to_i : 1
|
||||||
if (id < 0 || id >= ItemDefinition.count)
|
if (id < 0 || id >= ItemDefinition.count)
|
||||||
player.send_message('The item id you specified is out of bounds!')
|
player.send_message('The item id you specified is out of bounds!')
|
||||||
next
|
next
|
||||||
|
|||||||
Reference in New Issue
Block a user