Renegade Public Forums
C&C: Renegade --> Dying since 2003™, resurrected in 2024!
Home » Renegade Discussions » Mod Forum » :S Hostage Script help..
:S Hostage Script help.. [message #349332] Thu, 04 September 2008 16:46 Go to next message
halo2pac is currently offline  halo2pac
Messages: 659
Registered: December 2006
Location: Near Cleveland, Ohio
Karma: 0
Colonel
On level load (islands)
	Vector3 host1pos;
	host1pos.X = -41.0f;
	host1pos.Y = -175.0f;
	host1pos.Z = 4.0f;
	Commands->Attach_Script(Commands->Create_Object("Civ_Resist_Male_v2a",host1pos),"z_Hostage","PokerTeam=1,Hostage_Team=1,Hostage_Health=100,Hostage_Shield=100,Health_Regen_Ammount=2,Rescue_Message=1000,Controller_ID=1010,HostageDead_Message=2020");


and i walk upto him as a gds and as a nod hes just a dude ...
No hp, and if u shoot him nothing happens...


http://img339.imageshack.us/img339/1991/nefobbygenyunoreleasere.jpg
Rene-Buddy | Renegade X
Join the fight against Obsessive-Compulsive Posting Disorder. Cancel is ur friend.
*Renegade X Dev Team Member*
Re: :S Hostage Script help.. [message #349338 is a reply to message #349332] Thu, 04 September 2008 17:28 Go to previous messageGo to next message
zunnie is currently offline  zunnie
Messages: 2959
Registered: September 2003
Location: Netherlands
Karma: 0
General (2 Stars)

http://www.multiplayerforums.com/index.php?showtopic=5040&st=0

You should use the scripts in leveledit.

Use this dll in leveledit: http://www.game-maps.net/staff/zunnie/hostagemode/scripts344/

Use this dll on the server: http://www.game-maps.net/staff/zunnie/hostagemode/ssgm202/


If you insist on using the scripts.dll to create the hostages you should also have it create the hostage controller and get the ID of that controller object.

You should use it like this then:
Commands->Attach_Script(Commands->Create_Object("Civ_Resist_Male_v2a",host1pos), "z_Hostage","1,0,100,100,2,1000,1010,2020");

Note though that the ControllerID is 1010 in the above script attached, this should be the ID of the object that has the z_Hostage_Controller script attached to it.


https://multiplayerforums.com/uploads/monthly_2018_03/TCW2_Signature.png.6236a0dbc6e1e53472a18fe8cd15e47b.png

[Updated on: Thu, 04 September 2008 17:29]

Report message to a moderator

Re: :S Hostage Script help.. [message #349351 is a reply to message #349338] Thu, 04 September 2008 18:45 Go to previous messageGo to next message
halo2pac is currently offline  halo2pac
Messages: 659
Registered: December 2006
Location: Near Cleveland, Ohio
Karma: 0
Colonel
zunnie wrote on Thu, 04 September 2008 19:28

Note though that the ControllerID is 1010 in the above script attached, this should be the ID of the object that has the z_Hostage_Controller script attached to it.

How would I do that?


http://img339.imageshack.us/img339/1991/nefobbygenyunoreleasere.jpg
Rene-Buddy | Renegade X
Join the fight against Obsessive-Compulsive Posting Disorder. Cancel is ur friend.
*Renegade X Dev Team Member*
Re: :S Hostage Script help.. [message #349745 is a reply to message #349332] Sun, 07 September 2008 11:05 Go to previous messageGo to next message
halo2pac is currently offline  halo2pac
Messages: 659
Registered: December 2006
Location: Near Cleveland, Ohio
Karma: 0
Colonel
Ok i tried....
	if (stricmp(Data->CurrMap,"C&C_Islands.mix") == 0) {
		//Controller Hover Craft
		Vector3 hov;
		hov.X = -167.77f;
		hov.Y = 28.30f;
		hov.Z = -2.36f;

		Commands->Attach_Script(Commands->Create_Object("GDI_Hovercraft",hov),"z_Hostage_Controller","1000,2020,4,4,1");

		//Rescue Zone
		Vector3 rescueboxplace;
		rescueboxplace.X = -156.66f;
		rescueboxplace.Y = 28.24f;
		rescueboxplace.Z = 0.46f;

		Vector3 rescuezoneposSizes;
		rescuezoneposSizes.X = 5.0f;
		rescuezoneposSizes.Y = 5.0f;
		rescuezoneposSizes.Z = 5.0f;

		OBBoxClass Box;
		Box.Center = rescueboxplace;
		Box.Extent = rescuezoneposSizes;
		GameObject *Zone = Create_Zone("Script_Zone_All",Box);
		Commands->Attach_Script(Zone,"z_Hostage_Rescue_Zone","1,civ_lab_tech_01,Farmer,civ_lab_tech_03,Nun,Priest,1000");

		//Hostages
		Vector3 host1pos;
		//host1pos.X = -55.36f;
		//host1pos.Y = -203.13f;
		//host1pos.Z = 0.0f;
		host1pos.X = -153.00f;
		host1pos.Y = 45.f;
		host1pos.Z = 0.0f;
		GameObject *hosty1 = Commands->Create_Object("civ_lab_tech_01",host1pos);
		char *params = new char[128];
		sprintf(params,"1,1,100,10,2,1000,%d,2020",Commands->Get_ID(hosty1));
		Commands->Attach_Script(hosty1,"z_Hostage",params);
	}



Level loads, displays how many rescues.. but when u take the hostage to the zone .. CRASH!


http://img339.imageshack.us/img339/1991/nefobbygenyunoreleasere.jpg
Rene-Buddy | Renegade X
Join the fight against Obsessive-Compulsive Posting Disorder. Cancel is ur friend.
*Renegade X Dev Team Member*
Re: :S Hostage Script help.. [message #349758 is a reply to message #349332] Sun, 07 September 2008 12:19 Go to previous messageGo to next message
mrãçķz is currently offline  mrãçķz
Messages: 3069
Registered: August 2007
Karma: 0
General (3 Stars)
Permabanned for trying and failing DDoS
Its Halo2Pac !
Re: :S Hostage Script help.. [message #350652 is a reply to message #349332] Fri, 12 September 2008 17:23 Go to previous messageGo to next message
samous is currently offline  samous
Messages: 616
Registered: August 2008
Karma: 0
Colonel
whats so specail about halo2pac (no offense)?

Samous Ind. modding group website:
http://samous.webs.com/img/Capture.PNG

and Facebook Page: here
Re: :S Hostage Script help.. [message #350669 is a reply to message #350652] Fri, 12 September 2008 20:50 Go to previous messageGo to next message
Ethenal is currently offline  Ethenal
Messages: 2532
Registered: January 2007
Location: US of A
Karma: 0
General (2 Stars)

samous wrote on Fri, 12 September 2008 19:23

whats so specail about halo2pac (no offense)?

Not much. Very Happy
(just kidding halo Razz)


-TLS-DJ-EYE-K wrote on Mon, 18 March 2013 07:29

Instead of showing us that u aren't more inteligent than a Toast, maybe you should start becomming good in renegade Thumbs Up

Re: :S Hostage Script help.. [message #350715 is a reply to message #349332] Sat, 13 September 2008 09:33 Go to previous messageGo to next message
halo2pac is currently offline  halo2pac
Messages: 659
Registered: December 2006
Location: Near Cleveland, Ohio
Karma: 0
Colonel
lol Ethenal.
I just wish someone would help me figure this out..
the fds just crashes when I bring the hostages into the zone.
its been a week.... and im trying to get my new server up.


http://img339.imageshack.us/img339/1991/nefobbygenyunoreleasere.jpg
Rene-Buddy | Renegade X
Join the fight against Obsessive-Compulsive Posting Disorder. Cancel is ur friend.
*Renegade X Dev Team Member*
Re: :S Hostage Script help.. [message #350724 is a reply to message #349332] Sat, 13 September 2008 12:09 Go to previous message
danpaul88 is currently offline  danpaul88
Messages: 5795
Registered: June 2004
Location: England
Karma: 0
General (5 Stars)
I would assume it crashes because you set the controller ID to the ID of the hostage, instead of the controller.

		sprintf(params,"1,1,100,10,2,1000,%d,2020",Commands->Get_ID(hosty1));


Should be using Get_ID on the hovercraft controller object, which requires you to change the code that creates the hovercraft controller object so that you have the GameObject* for that object stored in a variable.

But, since I didn't make, and have never used, these scripts, I couldn't say for sure, I am just guessing based on the comment about using the ID of the controller.


http://steamsignature.com/card/1/76561197975867233.png
Previous Topic: MP-SP? CO-OP?
Next Topic: melee attacks
Goto Forum:
  


Current Time: Thu Dec 12 05:15:38 MST 2024

Total time taken to generate the page: 0.00922 seconds