Cirkus Serveri Forum
    • CoD4xAdmin
    • Recent
    • Popular
    • Groups
    • Users
    • Register
    • Login

    Use cod4x http features to pull rules from cod4xwebadmin ?

    Scheduled Pinned Locked Moved
    Feature Requests
    3
    8
    727
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • J
      JFF-Vince
      last edited by

      I have been looking for a way to display rules in game periodically. B3 does a decent job with this but I have not found anything other than creating a custom script ( which really doesn't work all that great for me. )

      What I have now:
      Custom gsc with hard coded rules.

      What would be awesome:
      Julia pull rules from web4xadmin and display them every x minutes... Maybe don't even need julia for this ... idk

      1 Reply Last reply Reply Quote 0
      • NeHoN
        NeHo Administrators
        last edited by

        The best way is to do it in gsc

        I keep hitting the 'Escape' key - but I'm still here. ...

        1 Reply Last reply Reply Quote 0
        • J
          JFF-Vince
          last edited by

          ok, will stick with that... thanks 🙂

          NeHoN 1 Reply Last reply Reply Quote 0
          • NeHoN
            NeHo Administrators @JFF-Vince
            last edited by

            @jff-vince this is what I use on my server for server messages every X seconds

            #include maps\mp\gametypes\_hud_util;
            init()
            {
            	level.delay_serv_messages = getDvarInt("server_messages_delay");
            	level thread server_messages();
            }
            
            server_messages()
            {	
            
            	self endon("disconnect");
            
            	svrmsg = [];
            
            	if (getDvar("serv_message_1")!=""){
            		svrmsg[0]=getDvar("serv_message_1");
            	}
            	if (getDvar("serv_message_2")!=""){
            		svrmsg[1]=getDvar("serv_message_2");
            	}
            	if (getDvar("serv_message_3")!=""){
            		svrmsg[2]=getDvar("serv_message_3");
            	}
            	if (getDvar("serv_message_4")!=""){
            		svrmsg[3]=getDvar("serv_message_4");
            	}
            	if (getDvar("serv_message_5")!=""){
            		svrmsg[4]=getDvar("serv_message_5");
            	}
            	if (getDvar("serv_message_6")!=""){
            		svrmsg[5]=getDvar("serv_message_6");
            	}
            	if (getDvar("serv_message_7")!=""){
            		svrmsg[6]=getDvar("serv_message_7");
            	}
            	if (getDvar("serv_message_8")!=""){
            		svrmsg[7]=getDvar("serv_message_8");
            	}
            	if (getDvar("serv_message_9")!=""){
            		svrmsg[8]=getDvar("serv_message_9");
            	}
            	if (getDvar("serv_message_10")!=""){
            		svrmsg[9]=getDvar("serv_message_10");
            	}
            
            	while(1)
            	{
            		for(i = 0; i < svrmsg.size; i++) {
            			wait level.delay_serv_messages;
            			sayClient(svrmsg[i]);
            		};
            	}
            }
            
            sayClient(str) {
            	exec( "say "+ str );
            }
            

            In server cfg

            //Time interval between messages if they are enabled
            set server_messages_delay 45
            
            set serv_message_1 "Register on Our website and create ^3Screenshots ^7from any Player on the server"
            set serv_message_2 "For available commands type ^3!help"
            set serv_message_3 ""
            set serv_message_4 ""
            set serv_message_5 ""
            set serv_message_6 ""
            set serv_message_7 ""
            set serv_message_8 ""
            set serv_message_9 ""
            set serv_message_10 ""
            

            I keep hitting the 'Escape' key - but I'm still here. ...

            1 Reply Last reply Reply Quote 1
            • SMiLeYS
              SMiLeY
              last edited by

              I would like to try this out also. I am using OW MoD and instead of having a main_shared folder I have the extras in a server side IWD file withing the MoD Folder. _spawnprotection.gsc for example when I wanted a minute spawn countdown on Sniper Server. That's proper Sniper not quick scope PromoD Sniping 🙂

              Anyway what would the name of the file be please if i tried the script above and put in my server side IWD? _hud_util.gsc or something? If it works great..if not it was worth the try 🙂

              In OW you can already have server messages and banner messages but not in 'the chat' location which IMO would be much better. B3 does this but I dont use it anymore since I am using the WebAdmin.

              Thanks
              Smiley

              1 Reply Last reply Reply Quote 0
              • SMiLeYS
                SMiLeY
                last edited by

                What have you named your file @NeHo ? Does it matter?

                1 Reply Last reply Reply Quote 0
                • NeHoN
                  NeHo Administrators
                  last edited by

                  it doesn't matter

                  I keep hitting the 'Escape' key - but I'm still here. ...

                  1 Reply Last reply Reply Quote 0
                  • SMiLeYS
                    SMiLeY
                    last edited by

                    Works a treat - Thank you 🙂

                    1 Reply Last reply Reply Quote 0
                    • First post
                      Last post

                    0

                    Online

                    191

                    Users

                    268

                    Topics

                    1.2k

                    Posts
                    Powered & Designed by NeHo