Results 1 to 10 of 28

Thread: Kicking bots

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Private First Class
    Join Date
    Oct 2013
    Posts
    219
    Thanks
    56
    Thanked 105 Times in 66 Posts
    Before I attempt to implement the method into my libcod, I have a quick question;

    Why is it
    Code:
    void PlayerCmd_renamebot(int a1) {
    instead of
    Code:
    void PlayerCmd_renamebot(string newname) {
    since you do
    Code:
    players[i] renamebot(newname);

  2. #2
    Global Mossaderator Mitch's Avatar
    Join Date
    Nov 2012
    Posts
    654
    Thanks
    204
    Thanked 450 Times in 305 Posts
    Quote Originally Posted by filthy_freak_ View Post
    Before I attempt to implement the method into my libcod, I have a quick question;

    Why is it
    Code:
    void PlayerCmd_renamebot(int a1) {
    instead of
    Code:
    void PlayerCmd_renamebot(string newname) {
    since you do
    Code:
    players[i] renamebot(newname);
    a1 is like he said the entity number. The parameters you use are stored in the stack of cod script. They get retrieved by Script_GetString(0). (different function in libcod)

  3. The Following User Says Thank You to Mitch For This Useful Post:

    filthy_freak_ (24th May 2014)

  4. #3
    Private First Class
    Join Date
    Oct 2013
    Posts
    219
    Thanks
    56
    Thanked 105 Times in 66 Posts
    Quote Originally Posted by Mitch View Post
    a1 is like he said the entity number. The parameters you use are stored in the stack of cod script. They get retrieved by Script_GetString(0). (different function in libcod)
    Ahh that makes sense, thanks the explanation.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •