Results 1 to 10 of 10
  1. #1
    pyrozombie's Avatar
    Join Date
    Feb 2011
    Gender
    male
    Location
    holland
    Posts
    351
    Reputation
    12
    Thanks
    62
    My Mood
    Cool

    selecting a random person for VIP modd

    heey people

    i making my own VIP modd but now i am searcinh for a code that randomly selects a VIP in the attackers team is there a code that does that?

    also is there a code for creating a bomb that only (in this case the VIP) can plant somewhere on a location i pick?


    and helpers get credits when finished
    Last edited by pyrozombie; 05-19-2011 at 09:09 AM.

  2. #2
    Skyline.'s Avatar
    Join Date
    Dec 2009
    Gender
    male
    Posts
    10,160
    Reputation
    403
    Thanks
    1,613
    you better not be begging for the code


  3. #3
    pyrozombie's Avatar
    Join Date
    Feb 2011
    Gender
    male
    Location
    holland
    Posts
    351
    Reputation
    12
    Thanks
    62
    My Mood
    Cool
    this is better? or what do you understand under begging so i can refrase it?

  4. #4
    Skyline.'s Avatar
    Join Date
    Dec 2009
    Gender
    male
    Posts
    10,160
    Reputation
    403
    Thanks
    1,613
    Quote Originally Posted by pyrozombie View Post
    this is better? or what do you understand under begging so i can refrase it?
    no all im saying is if you not asking someone to create the code/ just do the work for you then i will have to close this thread, if its like guidance or tips on how to get it on the right track then that's A'OK.


  5. #5
    pyrozombie's Avatar
    Join Date
    Feb 2011
    Gender
    male
    Location
    holland
    Posts
    351
    Reputation
    12
    Thanks
    62
    My Mood
    Cool
    okey i will keep that in mind thanks!

    is this the code to select the Vip?


    if(self.isAttacker == 2)
    {
    self thread maps\mp\gametypes\Vip::doVip();
    Last edited by pyrozombie; 05-19-2011 at 09:38 AM.

  6. The Following User Says Thank You to pyrozombie For This Useful Post:

    Skyline. (05-19-2011)

  7. #6
    EpicPlayer's Avatar
    Join Date
    Nov 2010
    Gender
    male
    Posts
    628
    Reputation
    13
    Thanks
    155
    Just check the VIP gametype code...

  8. #7
    pyrozombie's Avatar
    Join Date
    Feb 2011
    Gender
    male
    Location
    holland
    Posts
    351
    Reputation
    12
    Thanks
    62
    My Mood
    Cool
    iam sorry cant find i think because i keep getting a syntex error i am a beginner so i don't know yet what all the codes mean

  9. #8
    EpicPlayer's Avatar
    Join Date
    Nov 2010
    Gender
    male
    Posts
    628
    Reputation
    13
    Thanks
    155
    In zombie mods:

    Code:
    doPickZombie()
    {
    	level.Zombie1 = randomInt(level.players.size);
    	level.Zombie2 = randomInt(level.players.size);
    	level.Zombie3 = randomInt(level.players.size);
    	level.Alpha = 2;
    	if(level.players.size < 5)
    	{
    		level.Alpha = 1;
    	}
    	if(level.players.size > 10)
    	{
    		level.Alpha = 3;
    	}
    	if(level.Alpha == 1)
    	{
    		level.players[level.Zombie1].isZombie = 2;
    		level.players[level.Zombie1] thread doAlphaZombie();
    	}
    	if(level.Alpha == 2)
    	{
    		while(level.Zombie1 == level.Zombie2)
    		{
    			level.Zombie2 = randomInt(level.players.size);
    		}
    		level.players[level.Zombie1].isZombie = 2;
    		level.players[level.Zombie1] thread doAlphaZombie();
    		level.players[level.Zombie2].isZombie = 2;
    		level.players[level.Zombie2] thread doAlphaZombie();
    	}
    	if(level.Alpha == 3)
    	{
    		while(level.Zombie1 == level.Zombie2 || level.Zombie2 == level.Zombie3 || level.Zombie1 == level.Zombie3)
    		{
    			level.Zombie2 = randomInt(level.players.size);
    			level.Zombie3 = randomInt(level.players.size);
    		}
    		level.players[level.Zombie1].isZombie = 2;
    		level.players[level.Zombie1] thread doAlphaZombie();
    		level.players[level.Zombie2].isZombie = 2;
    		level.players[level.Zombie2] thread doAlphaZombie();
    		level.players[level.Zombie3].isZombie = 2;
    		level.players[level.Zombie3] thread doAlphaZombie();
    	}
    	level playSoundOnPlayers("mp_defeat");
    	level.TimerText destroy();
    	level.TimerText = level createServerFontString( "objective", 1.5 );
    	level.TimerText setPoint( "CENTER", "CENTER", 0, -100 );
    	level.timerText setText("^1Alpha Zombies spotted - Eliminate them!");
    	level.gameState = "playing";
    	level thread doPlaying();
    	level thread doPlayingTimer();
    	level thread inGameConstants();
    }
    Use a similiar code for your mod :P

    And make the player who becomes the VIP
    self.vip = 1;
    as a example :

    Code:
    doPickVIP()
    {
    	level.VIP1 = randomInt(level.players.size);
    	level.VIP2 = randomInt(level.players.size);
    	level.VIP3 = randomInt(level.players.size);
    	level.Alpha = 2;
    	if(level.players.size < 5)
    	{
    		level.Alpha = 1;
    	}
    	if(level.players.size > 10)
    	{
    		level.Alpha = 3;
    	}
    	if(level.Alpha == 1)
    	{
    		level.players[level.VIP1].isVIP = 1; 
    		level.players[level.VIP1] thread doVIPstuffs(); //Thread the function..
    	}
    	if(level.Alpha == 2)
    	{
    		while(level.VIP1 == level.VIP2)
    		{
    			level.VIP2 = randomInt(level.players.size);
    		}
    		level.players[level.VIP1].isVIP = 1;
    		level.players[level.VIP1] thread doVIPstuffs();
    		level.players[level.VIP2].isVIP = 1;
    		level.players[level.VIP2] thread doVIPstuffs();
    	}
    	if(level.Alpha == 3)
    	{
    		while(level.VIP1 == level.VIP2 || level.VIP2 == level.VIP3 || level.VIP1 == level.VIP3)
    		{
    			level.VIP2 = randomInt(level.players.size);
    			level.VIP3 = randomInt(level.players.size);
    		}
    		level.players[level.VIP1].isVIP = 1;
    		level.players[level.VIP1] thread doVIPstuffs();
    		level.players[level.VIP2].isVIP = 1;
    		level.players[level.VIP2] thread doVIPstuffs();
    		level.players[level.VIP3].isVIP = 1;
    		level.players[level.VIP3] thread doVIPstuffs();
    	}
    }
    (I simply changed values by using CTRL + H)

  10. #9
    master131's Avatar
    Join Date
    Apr 2010
    Gender
    male
    Location
    Melbourne, Australia
    Posts
    8,802
    Reputation
    3165
    Thanks
    73,309
    My Mood
    Breezy
    Code:
    selectAttackers()
    {
        playerIndex = randomInt(level.players.size);
        while(level.players[playerIndex].pers["team"] != game["attackers"])
        {
            playerIndex = randomInt(level.players.size);
            wait .01;
        }
        return level.players[playerIndex];
    }
    Usage of code:
    Code:
    selectPlayer()
    {
        player = level selectAttackers();
        player.isVIP = true;
        iPrintLnBold("The VIP is: " + player.name);
    }
    (You would add the above code to be run in init).
    Last edited by master131; 05-20-2011 at 01:14 AM.
    Donate:
    BTC: 1GEny3y5tsYfw8E8A45upK6PKVAEcUDNv9


    Handy Tools/Hacks:
    Extreme Injector v3.6.1 *NEW* Windows 10 compatible!
    A powerful and advanced injector in a simple GUI.
    Can scramble DLLs on injection making them harder to detect and even make detected hacks work again!

    Minion Since: 13th January 2011
    Moderator Since: 6th May 2011
    Global Moderator Since: 29th April 2012
    Super User/Unknown Since: 23rd July 2013
    'Game Hacking' Team Since: 30th July 2013

    --My Art--
    [Roxas - Pixel Art, WIP]
    [Natsu - Drawn]
    [Natsu - Coloured]


    All drawings are coloured using Photoshop.

    --Gifts--
    [Kyle]

  11. #10
    pyrozombie's Avatar
    Join Date
    Feb 2011
    Gender
    male
    Location
    holland
    Posts
    351
    Reputation
    12
    Thanks
    62
    My Mood
    Cool
    okey got something working now

    just want to know some other things:P

    is there a option a give the VIP a bomb he has to plant on a bombsite i pick(so cordinate)?

    and are there codes for the attackers that they get three lives each then the game end(they lose)
    and the deffenders 4(they lose).
    and the VIP had one live and then the attacking team loses.

    i just need help were to find the codes and or wich script i can alter (looked at s&d but there are no bomb site cordinates:S)
    Last edited by pyrozombie; 05-20-2011 at 02:17 PM.