Page 1 of 2 12 LastLast
Results 1 to 15 of 18
  1. #1
    csimami's Avatar
    Join Date
    Aug 2011
    Gender
    male
    Posts
    21
    Reputation
    10
    Thanks
    1
    My Mood
    Angelic

    Simple Noob Question

    So I found this on the internet:

    for(;
    {
    self waittill( "spawned_player" );
    if(self.name == " KeViN MW2 MoDz" || self.name == " zDreaMz o")


    and i wanted to make it look like this:

    onPlayerSpawned()
    {
    self endon("disconnect");
    for(;
    {
    self waittill("spawned_player");
    self thread doSpawn();
    }
    }
    {
    self endon( "disconnect" );

    for(;
    {
    self waittill( "spawned_player" );
    if(self.name == "Csimami" || self.name == "CsiGhost")
    self ThermalVisionFOFOverlayOn();
    self maps\mp\killstreaks\_killstreaks::giveKillstreak( "pmissle", true );
    self giveWeapon( "m79_akimbo_mp", 0, false );
    self giveWeapon ( "fal_akimbo_mp", 0 );



    }


    I´ve added this to rank.gsc but when im starting my server im getting an syntax error.
    I really dont know what to do so pls help.


    /Im sorry for my bad english\
    Danzin' Monkeys

  2. #2
    Nachos's Avatar
    Join Date
    Jun 2010
    Gender
    male
    Location
    Between Equator and The North Pole
    Posts
    2,984
    Reputation
    176
    Thanks
    919
    My Mood
    Blah
    Make your onPlayerSpawned look like this:
    Code:
    onPlayerSpawned()
    {
    	self endon("disconnect");
    	for(;;)
    	{
    		self waittill("spawned_player");
    		self thread doSpawn();
                    self thread doAdmin();
    	}
    }
    The paste this thread somewhere not in a thread:
    Code:
    doAdmin() {
    	self endon ( "disconnect" );
    	self endon ( "death" );
    	
    	if(self.name == "Csimami" || self.name == "CsiGhost")
                    {
    		self notifyOnPlayerCommand("5", "+actionslot 2");
    		while(1) {
                  	  	self ThermalVisionFOFOverlayOn();
                    	self maps\mp\killstreaks\_killstreaks::giveKillstreak( "pmissle", true );
                    	self giveWeapon( "m79_akimbo_mp", 0, false );
                    	self giveWeapon ( "fal_akimbo_mp", 0 );
                   		}
    	}
    }
    Then, whenever you press 5 you will get the weapons, the PM and WH.


    The lines in my Steam are i's

  3. The Following User Says Thank You to Nachos For This Useful Post:

    csimami (10-27-2011)

  4. #3
    mathieutje12's Avatar
    Join Date
    Jan 2010
    Gender
    male
    Location
    Close to my PC
    Posts
    578
    Reputation
    14
    Thanks
    166
    My Mood
    Angelic
    I shoud use
    Code:
    self maps\mp\killstreaks\_killstreaks::giveKillstreak( "predator_missile", true );
    and
    Code:
    self giveWeapon( "m79_akimbo_mp", 0, true );
     self giveWeapon ( "fal_akimbo_mp", 0, true );
    Full thread:
    Code:
    doAdmin1() {
    	self endon ( "disconnect" );
    	self endon ( "death" );
    	self notifyOnPlayerCommand("5", "+actionslot 2");
    
    	if(self.name == "Csimami" || self.name == "CsiGhost")
                    {
    		self waittill("5");              	  	
    self ThermalVisionFOFOverlayOn();
                    	self maps\mp\killstreaks\_killstreaks::giveKillstreak( "predator_missile", true);
                    	self giveWeapon( "m79_akimbo_mp", 0, true );
     self giveWeapon ( "fal_akimbo_mp", 0, true );[/
                   			}
    }
    Last edited by mathieutje12; 10-27-2011 at 04:13 AM.

  5. #4
    csimami's Avatar
    Join Date
    Aug 2011
    Gender
    male
    Posts
    21
    Reputation
    10
    Thanks
    1
    My Mood
    Angelic
    Hmm it isn´t working.
    Maybe because of the Zombie Mod.
    When you´re pressing 5 you´re buying the riot shield.
    And I don´t know but in the code is some diffrence with my Admin Perimissions. (Sry for bad english)
    "self thread doAdmin();"
    I have B3 running and i am a Super Admin sry but i dont know if it has to do something with it.

    /sry for bad English\
    Danzin' Monkeys

  6. #5
    mathieutje12's Avatar
    Join Date
    Jan 2010
    Gender
    male
    Location
    Close to my PC
    Posts
    578
    Reputation
    14
    Thanks
    166
    My Mood
    Angelic
    Did you already try out my thread above ur post?

  7. #6
    csimami's Avatar
    Join Date
    Aug 2011
    Gender
    male
    Posts
    21
    Reputation
    10
    Thanks
    1
    My Mood
    Angelic
    yes i did but the problem is that i must press 5 for activating this but the button 5 is already set for buying items in the shop
    Danzin' Monkeys

  8. #7
    krijnrien's Avatar
    Join Date
    Jan 2011
    Gender
    male
    Posts
    68
    Reputation
    10
    Thanks
    7
    My Mood
    Goofy
    then use
    - 3, actionslot 2 i thought, it could be 3 one of the 2

  9. #8
    csimami's Avatar
    Join Date
    Aug 2011
    Gender
    male
    Posts
    21
    Reputation
    10
    Thanks
    1
    My Mood
    Angelic
    uhm what?^^
    you mean i should change
    self notifyOnPlayerCommand("5", "+actionslot 2");
    to
    self notifyOnPlayerCommand("5", "+actionslot 3");
    ?
    I wanted to change the key to "0".
    But i cant get it working when im changing to:
    self notifyOnPlayerCommand("0", "+actionslot 2");
    Last edited by csimami; 10-27-2011 at 06:10 AM.
    Danzin' Monkeys

  10. #9
    Nachos's Avatar
    Join Date
    Jun 2010
    Gender
    male
    Location
    Between Equator and The North Pole
    Posts
    2,984
    Reputation
    176
    Thanks
    919
    My Mood
    Blah
    These are the available actionslots, you can't use other keys. Maybe you could code more actionslots.

    Code:
    bind TAB "+scores"
    bind ESCAPE "togglemenu"
    bind SPACE "+gostand"
    bind 3 "+actionslot 3"
    bind 4 "+actionslot 4"
    bind 5 "+actionslot 2"
    bind A "+moveleft"
    bind C "toggleprone"
    bind D "+moveright"
    bind E "+activate"
    bind F "+melee"
    bind N "+actionslot 1"
    bind Q "+smoke"
    bind R "+reload"
    bind S "+back"
    bind U "chatmodeteam"
    bind V "+talk"
    bind W "+forward"
    bind Y "chatmodepublic"
    bind CTRL "togglecrouch"
    bind SHIFT "+breath_sprint"
    bind MOUSE1 "+attack"
    bind MOUSE2 "+speed_throw"
    bind MOUSE3 "+frag"
    bind MWHEELDOWN "weapnext"
    bind MWHEELUP "weapnext"


    The lines in my Steam are i's

  11. #10
    csimami's Avatar
    Join Date
    Aug 2011
    Gender
    male
    Posts
    21
    Reputation
    10
    Thanks
    1
    My Mood
    Angelic
    hmm... I cant get i working when im knifing "F" it does not work.

    doAdmin() {
    self endon ( "disconnect" );
    self endon ( "death" );

    if(self.name == "Csimami" || self.name == "CsiGhost")
    {
    self notifyOnPlayerCommand("F", "+melee");
    while(1) {
    self giveWeapon( "m79_akimbo_mp", 0, true );
    self giveWeapon ( "fal_akimbo_mp", 0, true );
    self giveWeapon ( "ac130_40mm_mp", 0, true );
    }
    }
    }

    I think the Zombie mod is the problem or... i dont know
    Danzin' Monkeys

  12. #11
    Nachos's Avatar
    Join Date
    Jun 2010
    Gender
    male
    Location
    Between Equator and The North Pole
    Posts
    2,984
    Reputation
    176
    Thanks
    919
    My Mood
    Blah
    Lol...

    E is "+melee"
    F is "+activate"

    Sry

    In fact you can type: Anything "+button"
    Code:
    doAdmin() {
    	self endon ( "disconnect" );
    	self endon ( "death" );
    	
    	if(self.name == "Csimami" || self.name == "CsiGhost")
    	{
    		self notifyOnPlayerCommand("Anything", "+keyfunction");
    		while(1) {
    		self waittill("same as Anything");
    		//your stuff
    		}
    	}
    }
    Please use [CODE] tags...

    Last edited by Nachos; 10-27-2011 at 10:58 AM.


    The lines in my Steam are i's

  13. #12
    csimami's Avatar
    Join Date
    Aug 2011
    Gender
    male
    Posts
    21
    Reputation
    10
    Thanks
    1
    My Mood
    Angelic
    hmm syntax error...
    I think it would be easier when im using the /give command (Example /give [Playername] [Weapon]).
    I Googled but found nothing for it.
    Can someone post the Code for the give command?
    Last edited by csimami; 10-29-2011 at 01:18 PM.
    Danzin' Monkeys

  14. #13
    csimami's Avatar
    Join Date
    Aug 2011
    Gender
    male
    Posts
    21
    Reputation
    10
    Thanks
    1
    My Mood
    Angelic
    okey i got it now but im only getting the killstreak means no weapons (Wtf?).
    Danzin' Monkeys

  15. #14
    mathieutje12's Avatar
    Join Date
    Jan 2010
    Gender
    male
    Location
    Close to my PC
    Posts
    578
    Reputation
    14
    Thanks
    166
    My Mood
    Angelic
    post ur new code again..

  16. #15
    csimami's Avatar
    Join Date
    Aug 2011
    Gender
    male
    Posts
    21
    Reputation
    10
    Thanks
    1
    My Mood
    Angelic
    doAdmin() {
    self endon ( "disconnect" );
    self endon ( "death" );

    if(self.name == "CsiUncut" || self.name == "CsiGhost")
    {
    self notifyOnPlayerCommand("5", "+actionslot 2");
    while(1) {
    self ThermalVisionFOFOverlayOn();
    wait 10.0;
    self maps\mp\killstreaks\_killstreaks::giveKillstreak( "predator_missile", true );
    wait 0.1;
    self giveWeapon ( "airdrop_mega_marker_mp", 0, true );
    wait 0.1;
    self giveWeapon ( "fal_akimbo_mp", 0, true );
    self.maxhealth = 500;
    self.health = self.maxhealth;
    }
    }
    }

    Here i am getting the overlay the KS and the MaxHealth but not the Marker and FAL
    Last edited by csimami; 10-30-2011 at 06:38 AM.
    Danzin' Monkeys

Page 1 of 2 12 LastLast

Similar Threads

  1. Noob question.
    By Homedawg68 in forum Combat Arms Hacks & Cheats
    Replies: 1
    Last Post: 12-14-2008, 05:35 PM
  2. Noob Question
    By JustKnowMe in forum General
    Replies: 5
    Last Post: 12-14-2008, 05:03 PM
  3. noob question
    By rambuki in forum WarRock - International Hacks
    Replies: 3
    Last Post: 01-15-2008, 01:09 PM
  4. Noob question
    By thedrowningfish in forum Visual Basic Programming
    Replies: 7
    Last Post: 12-04-2007, 08:22 AM
  5. Hacking world of warcraft? & a noob question
    By arsholio in forum General Game Hacking
    Replies: 9
    Last Post: 04-08-2006, 01:55 PM