Renegade Public Forums
C&C: Renegade --> Dying since 2003™, resurrected in 2024!
Home » Renegade Discussions » Mod Forum » Find_Object only inside a Zone
Re: Find_Object only inside a Zone [message #408097 is a reply to message #407989] Fri, 23 October 2009 08:36 Go to previous message
E! is currently offline  E!
Messages: 70
Registered: February 2004
Karma:
Recruit
why not just writing your own function?

GameObject *Find_Object_In_Zone(int Team, GameObject *zone, GameObject *obj)
{
	GenericSLNode *x = BaseGameObjList->HeadNode;
	while (x)
	{
		GameObject *o = (GameObject *)x->NodeData;
		if (o && As_ScriptableGameObj(o))
		{
			if (IsInsideZone(zone,o) && Commands->Get_ID(o)==Commands->Get_ID(obj))
			{
				if ((Get_Object_Type(o) == Team) || (Team == 2))
				{
					return o;
				}
			}
		}
		x = x->NodeNext;
	}
	return 0;
}


<<SCUD-Storm Origin Creator>>
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Key hooks
Next Topic: CO-OP maps
Goto Forum:
  


Current Time: Wed Aug 28 01:38:57 MST 2024

Total time taken to generate the page: 0.00697 seconds