Custom Message Over Time Help

Topic created · 6 Posts · 75 Views
  • Hi guys, like the title says, did anyone know a code, o the function for send messages over time?, i mean, something like over 5 minutes or 15 the server send a message giving the discord link, or the rules, and stuff like that, im just starting my own server a few days ago and idk how to put that kind of message. Thanks a lot 🐶

  • @P1P0P1
    I use a function to scroll message on top of the screen. I prefer this the normal printing on bottom left. Change the string inside the " " and ut what you want.
    call in the init level thread message_area_manager(); and thats it

    affectElement(type, time, value){
       if(type == "x" || type == "y")
           self moveOverTime(time);
       else
           self fadeOverTime(time);
       if(type == "x")
           self.x = value;
       if(type == "y")
           self.y = value;
       if(type == "alpha")
           self.alpha = value;
       if(type == "color")
           self.color = value;
    }
    
    message_area_manager(){ // Developed by DoktorSAS
       level endon("game_ended");
       level.message_area = createServerFontString("hudsmall" , 1.2);
       level.message_area setPoint("CENTER", "CENTER", -1000, 220);
       level.message_area setText("");
       msg = []; 
       i = 0;
       msg[0] = "^5Discord ^7-> ^7Discord.gg/^5nCP2y4J";
       msg[1] = "Donate to support the server -> ^5paypal.me/SorexProject";
       msg[2] = "Invite friends in the ^5discord ^7-> ^7Discord.gg/^5nCP2y4J";
       msg[3] = "Invite friends to play on the server";
       msg[4] = "^5Discord ^7-> ^7Discord.gg/^5nCP2y4J";
       msg[5] = "Support the ^5project";
       msg[6] = "Invite friends in the ^5discord ^7-> ^7Discord.gg/^5nCP2y4J";
       for(;;){
       	level.message_area setText(msg[i]);
       	level.message_area affectElement("x", 0.5, 0);
       	wait 15.5; // Change this wait to change the time to go to the next message
       	level.message_area affectElement("x", 0.5, 1000);
       	wait 0.5;
       	level.message_area setPoint("CENTER", "CENTER", -1000, 220);
       	i++;
       	if(i >= msg.size)
       		i = 0;
       }
       
    }
    
  • @P1P0P1 Using IW4MAdmin you can setup automated messages super easily.

    link text

  • @chese there also auto message of iw4m xD

  • @Sorex 😮 now i see, thanks a lot Sorex, you code its fantastic for aesthetic applications and a huge amount of partial messages ❤ .

  • @P1P0P1 No problems, is just an aniamted text xD

Log in to reply