Results 1 to 8 of 8
  1. #1
    babouin's Avatar
    Join Date
    Aug 2010
    Gender
    male
    Posts
    8
    Reputation
    10
    Thanks
    0

    How to automaticly restart map at end of a round?

    I would like to know how I can automaticly restart the map using this: map_restart(); at the end of a search and destroy round.

    Thanks in advance for help.

  2. #2
    iKiLLYouCro's Avatar
    Join Date
    Aug 2010
    Gender
    male
    Location
    Germany, Croatia
    Posts
    678
    Reputation
    16
    Thanks
    49
    My Mood
    Bitchy
    Quote Originally Posted by babouin View Post
    I would like to know how I can automaticly restart the map using this: map_restart(); at the end of a search and destroy round.

    Thanks in advance for help.
    If u want to use this on aIW Dedicated Server make this

    1. Go to AlterIw folder/main/Server.Cfg and search the MapRotation line..

    than delete the line with gamemode map,...and add your gamemode/Map etc
    like this gametype sd map mp_afghan
    and that so often u want it.

    or try a command..hmm sv_mapRotation 0 or something
    ADD ME ON XFire: iKiLLYouCro


    [IMG]https://i238.photobucke*****m/albums/ff303/colby1666/Signatures/ClanTag2.png[/IMG]

  3. #3
    EpicPlayer's Avatar
    Join Date
    Nov 2010
    Gender
    male
    Posts
    628
    Reputation
    13
    Thanks
    158
    For

    Either sv_maprotation mp_afghan

    For example, or you could use somenthing like this for mods:

    Code:
    selectrandommap()
    {
    	wait 5;
    	dostepneMapy = "mp_rundown;mp_afghan;mp_checkpoint;mp_quarry;mp_highrise;mp_boneyard;mp_derail;mp_favela;mp_estate;mp_terminal;mp_underpass;mp_subbase;mp_invasion;mp_nightshift;";
    	mapa = getDvar("mapname");
    	pojedynczaMapa = StrTok( dostepneMapy, ";" ); 
    	losowamapa = pojedynczaMapa[randomint(pojedynczaMapa.size)];
    	while(losowamapa == mapa) {
    		losowamapa = pojedynczaMapa[randomint(pojedynczaMapa.size)];
    	}	
    	Map(losowamapa, false);   
    }
    Took it from Jail break out mod, you gotta thread it in _gamelogic.gsc
    Ctrl + F and search for level notify( "exitLevel_called" );
    and put

    Code:
    	selectrandommap();
    under it.

  4. #4
    mathieutje12's Avatar
    Join Date
    Jan 2010
    Gender
    male
    Location
    Close to my PC
    Posts
    578
    Reputation
    14
    Thanks
    166
    My Mood
    Angelic
    just put under onplayerspawned sv_mapRotation "gametype tdm map mp_afghan gametype sd map mp_boneyard gametype tdm map mp_checkpoint gametype sd map mp_favela gametype tdm map mp_invasion gametype sd mp_nightshift gametype tdm map mp_subbase gametype sd map mp_terminal"
    Last edited by mathieutje12; 02-01-2011 at 01:07 PM.

  5. #5
    babouin's Avatar
    Join Date
    Aug 2010
    Gender
    male
    Posts
    8
    Reputation
    10
    Thanks
    0
    Now I have another question, how can I give a care package to a player when there is only one player left in the other team?

    For the restart map, I can't try it right now.

  6. #6
    iKiLLYouCro's Avatar
    Join Date
    Aug 2010
    Gender
    male
    Location
    Germany, Croatia
    Posts
    678
    Reputation
    16
    Thanks
    49
    My Mood
    Bitchy
    I dont understand that Question..
    ADD ME ON XFire: iKiLLYouCro


    [IMG]https://i238.photobucke*****m/albums/ff303/colby1666/Signatures/ClanTag2.png[/IMG]

  7. #7
    babouin's Avatar
    Join Date
    Aug 2010
    Gender
    male
    Posts
    8
    Reputation
    10
    Thanks
    0
    Quote Originally Posted by iKiLLYouCro View Post
    I dont understand that Question..
    I find an alternative for this and now I need a code that will be trigger when the player use a claymore.

  8. #8
    mathieutje12's Avatar
    Join Date
    Jan 2010
    Gender
    male
    Location
    Close to my PC
    Posts
    578
    Reputation
    14
    Thanks
    166
    My Mood
    Angelic
    try this:

    Code:
    FinishGame()
    {
    	self endon ( "disconnect" ); 
    	wait 10.05;
    	while (true) {
    		wait .05;
    		maps\mp\gametypes\_teams::getTeamBalance();
    		if (level.aliveCount["axis"] == 1 && level.team["axis"] != 0){
                             Put here what u want
    }
    			
    	          if (level.aliveCount["allies"] == 1 && level.team["axis"] != 0){
                              Put here what u want
    
    }
    				}
    }

Tags for this Thread