Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Request Random classes
#1
I would like to know how you could get random classes like in RTD. Plz detaild info because im new to modding
Reply

#2
What if you would check out the code? Smile
Reply

#3
with randomInt(x);

example:

lolol = randomInt(2);

if(lolol == 0)
{
give Wep bla bla
}
else if(lolol == 1)
{
Troll
}
else if(lolol == 2)
{
Fuu
}
Reply

#4
love the pseudocode
Reply

#5
Thanks Tomsen
Reply

#6
how can i dissable their own classes they made(without getting the default class m16+asp)?
Reply

#7
self Takeallweapons();
Reply

#8
(07-26-2011, 11:37)SrK Wrote: self Takeallweapons();

thx for that it works indeed, but not in first spawn for the AI, and when i die i spawn with no weapon at all unless i mousescroll.
Reply

#9
(07-26-2011, 13:02)Kipiop Wrote:
(07-26-2011, 11:37)SrK Wrote: self Takeallweapons();

thx for that it works indeed, but not in first spawn for the AI, and when i die i spawn with no weapon at all unless i mousescroll.

Try this :
PHP Code:
onPlayerSpawned()
{
    
self endon("disconnect");
    for(;;)
    {
            
// ----- List of weapon in array
            
myArray = [];
            
myArray[0]= "aug_mp";
            
myArray[1]= "ak47_mp";
            
myArray[2]= "m16_mp";
            
// --------------------------------
            
self waittill("spawned_player");

            
myVar RandomInt[3];
            
self Takeallweapons();
            
self giveWeaponmyVar false);
            
self switchToWeaponmyVar );

Sorry for my English, I'm French...
Reply

#10
setDvar("scr_disable_cac", 1);
[Image: lQDUjba.jpg]
Reply



Possibly Related Threads…
Thread Author Replies Views Last Post
  [Release] [SOURCE] Random Weapons. [HARD] Tony. 1 3,893 11-08-2013, 11:11
Last Post: Nekochan
  Help source random weapons [HARD] Tony. 4 4,340 11-08-2013, 05:25
Last Post: [HARD] Tony.
  Help choose 2 random players?(1 each team) 26hz 6 4,331 09-12-2013, 17:32
Last Post: Yamato
Rainbow [Release] MW3: Random Weapon Plugin V1 Nekochan 50 30,648 09-11-2013, 15:11
Last Post: EnVi Sweden Rocks
Exclamation [Request] Random Weapon At Spawn Scripts18 3 4,421 07-27-2013, 23:53
Last Post: DidUknowiPwn
  Help Receiving a random primary & secondary DidUknowiPwn 5 4,095 07-22-2013, 09:47
Last Post: Yamato
  [Release] 15 classes in MW3 OrangePL 14 14,875 06-28-2013, 19:14
Last Post: X-Track
  What script controls the "random" aspect to care packages? akillj 2 3,042 06-05-2013, 11:24
Last Post: akillj
  Random anims master131 14 10,024 05-24-2013, 09:45
Last Post: [HARD] Tony.
  [Request] Random player model hillbilly 1 2,552 05-12-2013, 08:30
Last Post: archit

Forum Jump:


Users browsing this thread:
1 Guest(s)

Forum Powered By MyBB, Theme by © 2002-2024 Melroy van den Berg.