Results 1 to 10 of 22

Thread: Sound when the player connect and log in to server script.

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Private Wesleyw3zep's Avatar
    Join Date
    Feb 2016
    Posts
    38
    Thanks
    1
    Thanked 4 Times in 4 Posts
    well i did this,

    Callback_PlayerConnect()
    {
    thread dummy();

    self.statusicon = "hud_status_connecting";
    self waittill("begin");
    self.statusicon = "";

    level notify("connected", self);
    if(!level.splitscreen)
    iprintln(&"MP_CONNECTED", self.name);

    self iprintlnbold("^5w^6w^7w^3.^1unionsqd-gaming^3.^7c^6o^5m"); //put your message here
    self playlocalsound("us_welcome.mp3"); //put your sound here
    //self setclientcvar("hud_enable", 1);

    if(!isdefined(self.pers["team"]) && !level.splitscreen)
    iprintln(&"MP_CONNECTED", self.name);

    lpselfnum = self getEntityNumber();
    lpselfguid = self getGuid();
    logPrint("J;" + lpselfguid + ";" + lpselfnum + ";" + self.name + "\n");


    but i hear no sound only see the text

  2. #2
    Private Lonsofore's Avatar
    Join Date
    Oct 2016
    Posts
    86
    Thanks
    82
    Thanked 38 Times in 25 Posts
    Quote Originally Posted by Wesleyw3zep View Post
    self playlocalsound("us_welcome.mp3"); //put your sound here
    Here is your mistake - you should use soundaliases (.csv) files for sounds. You can find an example in iw_06.iwd. So, make your own .csv file in "soundaliases" folder, add there your sounds and then use them in your code with given name.

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

    kung foo man (18th March 2017)

  4. #3
    Private Wesleyw3zep's Avatar
    Join Date
    Feb 2016
    Posts
    38
    Thanks
    1
    Thanked 4 Times in 4 Posts
    Quote Originally Posted by Lonsofore View Post
    Here is your mistake - you should use soundaliases (.csv) files for sounds. You can find an example in iw_06.iwd. So, make your own .csv file in "soundaliases" folder, add there your sounds and then use them in your code with given name.
    ok so in the map sound i made a map called ''Gomsound'' inside that map are the 2 mp3's called ''playercon & playerdiscon.mp3

    #Gomannouncer,,,,,,,,,,,,
    gomplayersleft,,,gomsound/playerdiscon.mp3,1,1,,,,1000000,,auto,streamed
    gomplayersjoined,,,gomsound/playercon.mp3,1,1,,,,1000000,,auto,streamed

    does not work
    Last edited by Wesleyw3zep; 19th March 2017 at 00:39.

Posting Permissions

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