if(M.level < 100)
world.SetMedal("Splendid Warrior", M, hub=Xorbah.BleachTheFinalStand, hub_password=Xorbah.mypassword)
Problem description:
It keeps saying Bad Argument Definition. Help, people?
ID:140633
Oct 26 2009, 5:25 pm (Edited by moderator on Oct 26 2009, 5:45 pm)
|
|
Code:
if(M.level < 100) Problem description: It keeps saying Bad Argument Definition. Help, people? |
SetMedal(medal, player, hub=world.hub, hub_password=world.hub_password)
I'm fairly sure I've seen a lot of others around here tell you to read the guide, I too, am going to do the same thing.
The error here is obvious, the parameters hub and hub_password are auto-set to world.hub_password and world.hub by default, if you have these set (which you obviously do), you don't need to supply them under SetMedal().
So, in your case:
For the record, the more times you ask for help with simple and basic things like this, the less people are going to be willing to help you.
Simply reading the reference entry would have been enough to get your answer.
(Also, the hub_password is sensitive information, don't post it on the forums...)
[edit] -- I suppose I should explain a bit more.
BYOND supports what is known as named arguments in procs, which means if you specify the argument name in a proc call.
Note that not all inbuilt procedures take named arguments (according to the reference entry on Named Arguments). Consult the reference if you're unsure whether a proc does or does not take named arguments.
Your exact error was the fact you didn't supply your hub or hub_password as strings.