--these are jack's badass global scripts -- **FUNCTION 1**------------------------------------------------------------------------------ -- this special function returns a table that can you can iterate through so -- for example you can get all the pod members in a volume and iterate through killing them function get_pod_members_in_area( pod, area ) local members = {} local index = 1; nomad = pod:get_first() while (nomad:is_valid()) do if (is_in_area( nomad, area )) then members[index] = nomad; end nomad = pod:get_next(); end return members; end --*** Here is a an example of how to use the iterate through a table *** -- local dudes = get_pod_members_in_area( A1_PlayerPod, C1_area_Kill_Ratchet ); -- for key,value in pairs(dudes) do -- damage( dude, 99999 ); -- prt( "Lava Death!" ); -- end -- **FUNCTION 2**----------------------------------------------------------------------------- -- this special function returns the number of pod members function get_num_pod_in_area( pod, area ) local count = 0; --iterate through pod nomad = pod:get_first() while (nomad:is_valid()) do if (is_in_area( nomad, area )) then count = count+1; end nomad = pod:get_next(); end return count; end --*** Here is a an example of how you check this one *** -- while (get_num_pod_in_area( A1_PlayerPod, C1_area_Kill_Ratchet ) > 0 do