- 0
This community uses essential cookies to function properly. Non-essential cookies and third-party services are used only with your consent. Read our Privacy Policy and We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue..
AdBlock Extension Detected!
Our website is made possible by displaying online advertisements to our members.
Please disable AdBlock browser extension first, to be able to use our community.
Question
BBanHammer
hello!
i am trying to give item via l2j telnet.. the problem is that sometime it works, but other times it doesnt (allways same command)
i never actually worked with l2j before so i really don't see where the problem is, if some1 does, please tell me
function giveItem($player) { global $CONFIG; $usetelnet = fsockopen($CONFIG['telnet_ip'],$CONFIG['telnet_port'], $errno, $errstr, 30); if($usetelnet) { $command = 'give '.$player.' '.$CONFIG['reward_item_id'].' '.$CONFIG['reward_item_count']; echo "<".$command."><br />"; fputs($usetelnet, $CONFIG['telnet_pass']); fputs($usetelnet, "\r\n"); fputs($usetelnet, $command); fputs($usetelnet, "\r\n"); fputs($usetelnet, "exit\r\n"); fclose($usetelnet); return true; } return false; }the code gives sometime SocketException.. from what i have read it's caused by misformed command line, anyone?
0 answers to this question
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now