Login x
User Name:
Password:
Social Links Facebook Twitter YouTube Steam RSS News Feeds

Members Online

»
0 Active | 56 Guests
Online:

LATEST FORUM THREADS

»
CoD: Battle Royale
CoD+UO Map + Mod Releases
Damaged .pk3's
CoD Mapping
heli to attack ai
CoD4 SP Mapping

Forums

»

Welcome to the MODSonline.com forums. Looking for Frequently Asked Questions? Check out our FAQs section or search it out using the SEARCH link below. If you are new here, you may want to check out our rules and this great user's guide to the forums and the website.
For more mapping and modding information, see our Wiki: MODSonWiki.com

Jump To:
Forum: All Forums : Call of Duty 2
Category: CoD2 Scripting
Scripting and coding with Call of Duty 2.
Moderators: foyleman, Foxhound, Mystic, StrYdeR, batistablr, Welshy, DrBiggzz, supersword, playername
Latest Posts
Subscribed Posts
Search
Restricted Access Topic is Locked subscribe
Author Topic: Freezing a player
L3uX
General Member
Since: Mar 14, 2012
Posts: 20
Last: May 6, 2013
[view latest posts]
Level 1
Category: CoD2 Scripting
Posted: Wednesday, May. 1, 2013 08:28 pm
Heys guys!


Did anyone can give me a tip how can i freeze a player?
Share |
Samuel033
General Member
Since: Dec 10, 2009
Posts: 484
Last: Dec 25, 2015
[view latest posts]
Level 5
Category: CoD2 Scripting
Posted: Wednesday, May. 1, 2013 11:03 pm
Just disable his controls? Does cod2 have player freezecontrols( true )?
Share |
kimistatheone
General Member
Since: Mar 1, 2012
Posts: 47
Last: May 2, 2013
[view latest posts]
Level 2
Im a fan of MODSonair
Category: CoD2 Scripting
Posted: Thursday, May. 2, 2013 10:01 am
spawn a script origin, link the player to him.
you can control the angles too, disableweapon, anything
Share |
SPi
General Member
Since: Jul 4, 2012
Posts: 531
Last: Nov 9, 2019
[view latest posts]
Level 6
Category: CoD2 Scripting
Posted: Thursday, May. 2, 2013 11:06 am
Can you explain how to do that??? I would also want to know.
I need it so much [jumping]

[thumbs_up][thumbs_up][thumbs_up]
Share |
robert119966
General Member
Since: Feb 12, 2012
Posts: 19
Last: Feb 7, 2014
[view latest posts]
Level 1
Category: CoD2 Scripting
Posted: Thursday, May. 2, 2013 12:46 pm
Code:
freeze()
{				
                                self.headicon = "freeze";
				self.logofreeze = newClientHudElem(self);
				self.logofreeze.x = 420;
				self.logofreeze.y = 472;
				self.logofreeze.alignX = "right";
				self.logofreeze.alignY = "middle";
				self.logofreeze.sort = -3;
				self.logofreeze.alpha = 1;
				self.logofreeze.fontScale = 1.3;
				self.logofreeze.archived = true;
				self.logofreeze.label = &"^2*^7Per^9ss ^2[^3ATTACK^2] ^7AN^9D ^2[^3F^2] ^7T^9o ^7Free^9ze ^7Activa^9tors!";
				
	
				while(1)
				{	
					if(self attackButtonPressed() && self usebuttonpressed() )
					{
						
						if(isDefined(self.logofreeze))  self.logofreeze destroy();
						
						level.svrlogo = newHudElem(); 
						level.svrlogo.x = 50; 
						level.svrlogo.y = 76; 
						level.svrlogo.alignX = "center"; 
						level.svrlogo.alignY = "middle"; 
						level.svrlogo.archived = false; 
						level.svrlogo.alpha = .7; 
						level.svrlogo.sort = 8000; 
						level.svrlogo setShader("weapon_mp44", 110,110);
				
				/////////////////////////////////////////////////////////////
                                self playSound("freeze");
				iprintln(self.name + " ^2. ^7Free^9ze ^7Al^9l ^7Activa^9tors ^2`");
                                              self.headicon = "headrun";
	                        self iprintlnbold("^2. ^7Yo^9u ^7Free^9ze ^7Activa^9tors ^2`");
	                        self iprintlnbold("^2. ^7Fo^9r ^225 ^7Seco^9nds ^2`");


			        players = getentarray("player", "classname");	     
						for(playeralive = 0; playeralive < players.size; playeralive++) 
						{         
						player = players[playeralive];
						if(isDefined(level.svrlogo))  level.svrlogo destroy();
                                player thread sq_czolgfreezee();
}
				//////////////////////////////////////////////////////
				
						break;
					}
					else
					{
						wait 0.05;

					}
					
					if(self.pers["team"] != "allies")
					{
						
						self iprintlnbold("^2. ^7YOU ^9ARE ^7IN ^9ACTIVATORS!!!");
						if(isDefined(self.logofreeze))  self.logofreeze destroy();
						wait 1;
						break;
					}
				}
}



sq_czolgfreezee()
{
        self.script = "freeze";

        guid = self getGuid();
        level.hzfile = (guid+".txt");
        drczolg\log::log(level.hzfile);

					if(self.pers["team"] != "allies")
					{
	self endon("disconnect");

	{
		playfx(level._effect["fb"], self.origin);
                self.statusicon = "freeze";
		self.anchor = spawn("script_origin", self.origin);
		self linkTo(self.anchor);
		self disableWeapon();
		
	    wait 25;
		
                self.statusicon = "";
		self unlink();
		self.anchor delete();
		self enableWeapon(); 
	}
}
}
Share |
Restricted Access Topic is Locked subscribe
MODSonline.com Forums : Call of Duty 2 : CoD2 Scripting

Latest Syndicated News

»
Codutility.com up and runn...
Nice, and there still using the logo and template for the screenshots, which...
Codutility.com up and runn...
dundy writes...Quote:Call of Duty modding and mapping is barly alive only a ...
Codutility.com up and runn...
Mystic writes...Quote:It seems to me the like the site is completely dead? ...
Codutility.com up and runn...
It seems to me the like the site is completely dead?

Partners & Friends

»