Page 1 of 1

Voiced command ?

Posted: Mon Mar 03, 2014 11:54 am
by Shyn
If you want to receive support we need this info to help you properly.
» Find Revision
L2J Revision Number:6291
L2JDP Revision Number:9641

Hey guys (My first post here!)
I've started to code in l2j most likely for learning purposes. I tried to create a voiced command which you can change your name. (You get the value by html).
I coded but i thought it was faulty because i couldnt change the name, so i used the code from admin_changename and still cant get this working.
Problem is that i cant the value(name) which i give on variable on java. Any help would be much appreciated.

Here's the java code on handlers: http://pastebin.com/iD6uYfnb
and the HTML:

Code: Select all

<tr>New Name</tr><tr><edit var="val" width=100></tr><br><br><button action="bypass -h voice .changeName $val" value="Change my name!" width=140 height=25 back=L2UI_CT1.Button_DF fore=L2UI_CT1.Button_DF>
Thanks in advance :)

Re: Voiced command ?

Posted: Tue Mar 04, 2014 10:15 am
by Shyn
Nobody can help?

This thing is driving me crazy :(

Re: Voiced command ?

Posted: Tue Mar 04, 2014 12:33 pm
by Zoey76
Let me check.

Code: Select all

<html>    <body>        <center>            <table>                <td>                    <tr>                         New name:                    </tr>                    <tr>                        <edit var="newname" width=150>                    </tr>                </td>            </table>            <br>            <button value="Change Name" action="bypass -h voice .changename $newname" width="160" height="25" back="L2UI_ct1.button_df" fore="L2UI_ct1.button_df">        </center>    </body></html>
Gist by: Zoey76
Voiced commands are not expected to be used by GMs to change the players game-play, they are expected to extend the players game-play by adding new commands for those players to use.

Re: Voiced command ?

Posted: Tue Mar 04, 2014 3:21 pm
by Shyn
Thanks alot Zoey. Finally i fixed that!
I also understood my mistake and for sure its going to help me for other codes too :)

Re: Voiced command ?

Posted: Tue Mar 04, 2014 4:13 pm
by Zoey76
No problem, glad it helped.

By the way I'll be moving this to viewforum.php?f=46 where we provide support to users for this kind of questions :wink: