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

Members Online

»
0 Active | 69 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
Page
Next Page
subscribe
Author Topic: Turn into other skins
stealthcod2
General Member
Since: Dec 23, 2008
Posts: 108
Last: Jul 13, 2009
[view latest posts]
Level 4
Category: CoD2 Scripting
Posted: Friday, May. 15, 2009 02:47 am
Ok, this is sorta like my other thread but this time Im wondering how do I turn into german skin etc. I know how to turn into a models but not german. I tried doing self setmodel("xmodel/character_german_winter_light"); but I think i probably gotta do like a character not aan xmodel eh?
Share |
stealthcod2
General Member
Since: Dec 23, 2008
Posts: 108
Last: Jul 13, 2009
[view latest posts]
Level 4
Category: CoD2 Scripting
Posted: Wednesday, May. 20, 2009 03:48 am
wow anyone know?
Share |
liltc64
General Member
Since: Feb 12, 2007
Posts: 906
Last: Oct 22, 2012
[view latest posts]
Level 7
Im a fan of MODSonair
Category: CoD2 Scripting
Posted: Wednesday, May. 20, 2009 10:40 am
pretty str8 forward... this is wont be that long of a list.

1. If u still have the playercontrols.menu i gave u then add

Code:
itemDef
		{
			name			"window"
			group			ingamebox
			visible			1
			rect			16 42 0 0
			origin			ORIGIN_QUICKMESSAGEWINDOW
			forecolor		1 1 1 1
			textfont		UI_FONT_NORMAL
			textscale		.24
			textaligny		8
			text			"3. German"
			decoration
		}
		execKey "3" { scriptMenuResponse "german"; close playercontrols; }


2. Now in _quickmessages.gsc add

Code:
case "german":
         self thread maps\mp\gametypes\_teams::model();
         break;


Right under the case called FirstPerson --- And there u have it but the question is what if ur on a map that has German Normandy... well ur gona end up turning into a German Normandy player so u could toy around with the maps .gsc and change them to winterlight instead of normandy and u have it give that a go

Anyone That See's This Post Watch This Vid

http://www.collegehumor.com/video:1911525

[pimp]

edited on May. 20, 2009 06:44 am by liltc64
Share |
DemonSeed
General Member
Since: Apr 30, 2009
Posts: 1362
Last: Feb 19, 2018
[view latest posts]
Level 8
Im a fan of MODSonair
Category: CoD2 Scripting
Posted: Wednesday, May. 20, 2009 10:51 am
stealthcod2 writes...
Quote:
Ok, this is sorta like my other thread but this time Im wondering how do I turn into german skin etc. I know how to turn into a models but not german. I tried doing self setmodel("xmodel/character_german_winter_light"); but I think i probably gotta do like a character not aan xmodel eh?


Basically, anywhere in your script (calling it on SpawnPlayer(), or whatever), you simply do the callback for axis models:

Quote:
[[ game["axis_model"] ]]();


I don't know if its any good to you, but here is a script I made for a COD2 mod which had a class system:

Code:
set_Normandy_Models( team )
{
	
	bod = undefined;
	view = undefined;
	helmet = undefined;
	head = undefined;
	
	if( team == "allies" )
	{
		switch( game["allies"] )
		{
			case "american":
				switch( self.pers["class"] )
				{
					case "medic":
						bod = "xmodel/playerbody_american_normandy_medic";
						view = "xmodel/viewmodel_hands_cloth";
						helmet = "xmodel/helmet_us_ranger_medic_wells";
						head = "xmodel/head_us_ranger_medic_wells";
						break;
			
					case "officer":
						bod = "xmodel/playerbody_american_normandy03";
						view = "xmodel/viewmodel_hands_cloth";
						helmet = "xmodel/helmet_ranger_officer_cap";
						head = "xmodel/head_russian_winter_volsky";
						break;
						
					case "assault":
						[[ game["allies_model"] ]]();
						break;
						
					case "support":
						[[ game["allies_model"] ]]();
						break;
				}
				break;
			
			case "british":
				switch( self.pers["class"] )
				{
					case "medic":
						bod = "xmodel/playerbody_american_normandy_medic";
						view = "xmodel/viewmodel_hands_cloth";
						helmet = "xmodel/helmet_us_ranger_medic_wells";
						head = "xmodel/head_us_ranger_medic_wells";
						break;
			
					case "officer":
						bod = "xmodel/playerbody_american_normandy03";
						view = "xmodel/viewmodel_hands_cloth";
						helmet = "xmodel/helmet_ranger_officer_cap";
						head = "xmodel/head_russian_winter_volsky";
						break;
						
					case "assault":
						[[ game["allies_model"] ]]();
						break;
						
					case "support":
						[[ game["allies_model"] ]]();
						break;
				}
				break;
		}
	
	}
	else
	{
		switch( self.pers["class"] )
		{
			case "medic":
				bod = "xmodel/playerbody_german_normandy_medic";
				view = "xmodel/viewmodel_hands_german";
				helmet = "xmodel/helmet_german_normandy_medic";
				head = randomizeAxisHead();
				break;
			
			case "officer":
				bod = "xmodel/playerbody_german_normandy_officer";
				view = "xmodel/viewmodel_hands_german";
				helmet = "xmodel/helmet_german_normandy_officer_hat";
				head = randomize_AxisofficerHead();
				break;
				
			case "assault":
				[[ game["axis_model"] ]]();
				break;
						
			case "support":
				[[ game["axis_model"] ]]();
				break;
		}	
	}

	if( isdefined( bod ) ) self setModel( bod );

	if( isdefined( head ) ) self attach( head );

	if( isdefined( helmet ) ) 
	{
		self.hatModel = helmet;
		self attach( self.hatModel );
	}

	if( isdefined( view ) ) self setViewmodel( view );
	
	if( !isDefined( self.pers["savedmodel"] ) )
		self.pers["savedmodel"] = maps\mp\_utility::saveModel();
	else
		maps\mp\_utility::loadModel( self.pers["savedmodel"] );
}
Share |
[ATB]
General Member
Since: Feb 10, 2007
Posts: 135
Last: Apr 29, 2020
[view latest posts]
Level 4
Im a fan of MODSonair
Category: CoD2 Scripting
Posted: Friday, May. 22, 2009 11:40 am
What mod is the script from, DemonSeed? (just curious)
Share |
DemonSeed
General Member
Since: Apr 30, 2009
Posts: 1362
Last: Feb 19, 2018
[view latest posts]
Level 8
Im a fan of MODSonair
Category: CoD2 Scripting
Posted: Friday, May. 22, 2009 11:59 am
AnythingButt writes...
Quote:
What mod is the script from, DemonSeed? (just curious)


Demon mod for COD2. It was a mod I made for my clan (Demon), but I never released it to the public. Im thinking of doing that now, but I dont know whether there is an audience for it. COD2 is pretty much dead now, so what would be the point?

Here are some shots of the class models. These are all taken from mp_burgundy, and all the models are on the server at the same time:

German Officer:



German Medic:



American Ranger Officer:



American Ranger Medic:



edited on May. 22, 2009 08:00 am by DemonSeed
Share |
[ATB]
General Member
Since: Feb 10, 2007
Posts: 135
Last: Apr 29, 2020
[view latest posts]
Level 4
Im a fan of MODSonair
Category: CoD2 Scripting
Posted: Friday, May. 22, 2009 12:50 pm
Nice...

Quote:
COD2 is pretty much dead now, so what would be the point?


Of CoD2/4/5, CoD2 is still the game I play the most, and there are many still playing it whether due to preference or rig, but I guess it's your call... If it's finished and bug free then it would do no harm to release it - it might not get used as is, but if nothing else it would act as a working tutorial of how to go about adding a class system... (That would be my interest, but then I love reading scripts and learning something new...).

I made a Uniform selection menu, but never got round to releasing it cos the file size was about 80 meg and I'd need permission from all the skin authors, so I didn't bother in the end... Not much scripting (just case statements really) but a lot images and material files...

This is what it looked like:




At least I still use it, so not a complete waste of time... :)
Share |
stealthcod2
General Member
Since: Dec 23, 2008
Posts: 108
Last: Jul 13, 2009
[view latest posts]
Level 4
Category: CoD2 Scripting
Posted: Friday, May. 22, 2009 01:27 pm
liltc64 writes...
Quote:
pretty str8 forward... this is wont be that long of a list.

1. If u still have the playercontrols.menu i gave u then add

Code:
itemDef
		{
			name			"window"
			group			ingamebox
			visible			1
			rect			16 42 0 0
			origin			ORIGIN_QUICKMESSAGEWINDOW
			forecolor		1 1 1 1
			textfont		UI_FONT_NORMAL
			textscale		.24
			textaligny		8
			text			"3. German"
			decoration
		}
		execKey "3" { scriptMenuResponse "german"; close playercontrols; }


2. Now in _quickmessages.gsc add

Code:
case "german":
         self thread maps\mp\gametypes\_teams::model();
         break;


Right under the case called FirstPerson --- And there u have it but the question is what if ur on a map that has German Normandy... well ur gona end up turning into a German Normandy player so u could toy around with the maps .gsc and change them to winterlight instead of normandy and u have it give that a go

Anyone That See's This Post Watch This Vid

http://www.collegehumor.com/video:1911525

[pimp]

edited on May. 20, 2009 06:44 am by liltc64


hey man, havnt seen yo in awhile.
Share |
stealthcod2
General Member
Since: Dec 23, 2008
Posts: 108
Last: Jul 13, 2009
[view latest posts]
Level 4
Category: CoD2 Scripting
Posted: Saturday, May. 23, 2009 05:03 pm
DemonSeed writes...
Quote:
stealthcod2 writes...
Quote:
Ok, this is sorta like my other thread but this time Im wondering how do I turn into german skin etc. I know how to turn into a models but not german. I tried doing self setmodel("xmodel/character_german_winter_light"); but I think i probably gotta do like a character not aan xmodel eh?


Basically, anywhere in your script (calling it on SpawnPlayer(), or whatever), you simply do the callback for axis models:

Quote:
[[ game["axis_model"] ]]();


I don't know if its any good to you, but here is a script I made for a COD2 mod which had a class system:

Code:
set_Normandy_Models( team )
{
	
	bod = undefined;
	view = undefined;
	helmet = undefined;
	head = undefined;
	
	if( team == "allies" )
	{
		switch( game["allies"] )
		{
			case "american":
				switch( self.pers["class"] )
				{
					case "medic":
						bod = "xmodel/playerbody_american_normandy_medic";
						view = "xmodel/viewmodel_hands_cloth";
						helmet = "xmodel/helmet_us_ranger_medic_wells";
						head = "xmodel/head_us_ranger_medic_wells";
						break;
			
					case "officer":
						bod = "xmodel/playerbody_american_normandy03";
						view = "xmodel/viewmodel_hands_cloth";
						helmet = "xmodel/helmet_ranger_officer_cap";
						head = "xmodel/head_russian_winter_volsky";
						break;
						
					case "assault":
						[[ game["allies_model"] ]]();
						break;
						
					case "support":
						[[ game["allies_model"] ]]();
						break;
				}
				break;
			
			case "british":
				switch( self.pers["class"] )
				{
					case "medic":
						bod = "xmodel/playerbody_american_normandy_medic";
						view = "xmodel/viewmodel_hands_cloth";
						helmet = "xmodel/helmet_us_ranger_medic_wells";
						head = "xmodel/head_us_ranger_medic_wells";
						break;
			
					case "officer":
						bod = "xmodel/playerbody_american_normandy03";
						view = "xmodel/viewmodel_hands_cloth";
						helmet = "xmodel/helmet_ranger_officer_cap";
						head = "xmodel/head_russian_winter_volsky";
						break;
						
					case "assault":
						[[ game["allies_model"] ]]();
						break;
						
					case "support":
						[[ game["allies_model"] ]]();
						break;
				}
				break;
		}
	
	}
	else
	{
		switch( self.pers["class"] )
		{
			case "medic":
				bod = "xmodel/playerbody_german_normandy_medic";
				view = "xmodel/viewmodel_hands_german";
				helmet = "xmodel/helmet_german_normandy_medic";
				head = randomizeAxisHead();
				break;
			
			case "officer":
				bod = "xmodel/playerbody_german_normandy_officer";
				view = "xmodel/viewmodel_hands_german";
				helmet = "xmodel/helmet_german_normandy_officer_hat";
				head = randomize_AxisofficerHead();
				break;
				
			case "assault":
				[[ game["axis_model"] ]]();
				break;
						
			case "support":
				[[ game["axis_model"] ]]();
				break;
		}	
	}

	if( isdefined( bod ) ) self setModel( bod );

	if( isdefined( head ) ) self attach( head );

	if( isdefined( helmet ) ) 
	{
		self.hatModel = helmet;
		self attach( self.hatModel );
	}

	if( isdefined( view ) ) self setViewmodel( view );
	
	if( !isDefined( self.pers["savedmodel"] ) )
		self.pers["savedmodel"] = maps\mp\_utility::saveModel();
	else
		maps\mp\_utility::loadModel( self.pers["savedmodel"] );
}


Thats sorta like I want demon but I want it to be able to turn into this model while im a different model, say im a american in the thirdperson then i push like quickchat 5 5 then i instantly turn to german.
Share |
DemonSeed
General Member
Since: Apr 30, 2009
Posts: 1362
Last: Feb 19, 2018
[view latest posts]
Level 8
Im a fan of MODSonair
Category: CoD2 Scripting
Posted: Saturday, May. 23, 2009 05:36 pm
Then you will have to edit _quickmessages.gsc, and insert that code:

[[ game["axis_model"] ]]();

Under the allies cases.

I'm always wary of threads like this, where it "seems" like a request for HELP with a mod, but ends up being a request to MAKE the mod. So, if you dont know how to edit _quickmessages.gsc and insert the code, I would suggest you come clean and ask for what you really want - for someone to do the mod for you.
Share |
Restricted Access Topic is Locked
Page
Next Page
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

»