| Blockland Forums > Modification Help |
| "Unable to Find Object" AGAIN |
| << < (2/3) > >> |
| brickybob:
Too many letters so no edit, also I'm using BL 0002 because I was trying to remakes spider's RPG. Anyone remember that? Another edit: I'll port it to retail when I get it done, maybe... |
| Slicksilver:
I.. I don't know if this is just a huge oversight or what, but you're not providing a client for the %client variable. Of course it's not going to be able to find the object %client, you didn't give it an object to operate on. |
| Chrono:
http://forum.blockland.us/index.php?topic=183311.msg4851529#msg4851529 |
| brickybob:
--- Quote from: Slicksilver on February 06, 2012, 08:28:18 PM ---I.. I don't know if this is just a huge oversight or what, but you're not providing a client for the %client variable. Of course it's not going to be able to find the object %client, you didn't give it an object to operate on. --- End quote --- I was under the assumption that it would automatically use the client that sent the command. |
| Scout31:
Parent:: is missing in package --- Code: ---package asdf { function GameConnection::autoAdminCheck(%client) { %client.gold = 20; return parent::autoAdminCheck(%client); } }; ActivatePackage(asdf); function getGold(%client) { if(isobject(%client)) { commandToClient(%client, 'bottomPrint', "Gold: " @ %client.gold); } else { error("no client"); } } --- End code --- Untested, typed on phone. To send the gold count, type: getGold(findclientbyname(Name)); |
| Navigation |
| Message Index |
| Next page |
| Previous page |