Renegade Public Forums
C&C: Renegade --> Dying since 2003™, resurrected in 2024!
Home » Renegade Discussions » Mod Forum » Server Side Hunt The Player
Re: Server Side Hunt The Player [message #314593 is a reply to message #313512] Wed, 30 January 2008 05:06 Go to previous messageGo to previous message
reborn is currently offline  reborn
Messages: 3231
Registered: September 2004
Location: uk - london
Karma:
General (3 Stars)
I was so tempted to quote all that Razz
Thankyou for sharing, I personally know what a pain in the ass it was to copy that shit from dm.ini. I will update the source and release it so everyone can host more maps Smile

Use this instead:
Change_Character(obj,RandomSpawnCharacter[Index][0]);

Change_Character is not a script command class...


Your array will work, but it will only work properly if you update:

/////////////////////////////////////////////////////////////////////////////
// This code here ensures a random number is drawn between 1 and 100
//int Rnd = Commands->Get_Random_Int(1,100);

to:

/////////////////////////////////////////////////////////////////////////////
// This code here ensures a random number is drawn between 1 and 100
//int Rnd = Commands->Get_Random_Int(1,270);

and then change:

// if (Rnd <= 10) Index = 2;
// else if (Rnd<=20) Index = 1;
// else if (Rnd<=30) Index = 0;

To allow for all the extra Index possibilities...


The DNA goes away because essentially the preset has been destroyed, and the object has a MDB script on it that destroys the object when this happens.
You would have to re-attach the DNA strand to the person after you have set there preset to the new version.
Check out how it is attached in void hunted_player::Created(GameObject *obj){, and apply it to your chat hook after the point that you have set there new preset.
Something like this:
GameObject *Icon = Commands->Create_Object_At_Bone(obj,"Invisible_Object","c HEAD");
Commands->Set_Model(Icon,"p_tnanites");
Commands->Attach_To_Object_Bone(Icon,obj,"c HEAD");
Commands->Attach_Script(Icon,"MDB_SSGM_Destroy_When_Object_Destroyed",ToString(Commands- >Get_ID(obj)).c_str());




 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Boning in 3ds max
Next Topic: Invinceable buildings
Goto Forum:
  


Current Time: Wed Feb 05 02:54:22 MST 2025

Total time taken to generate the page: 0.01291 seconds