public virtual bool MoveNext() { if (index++ < (group.MemberCount - 1)) { Current = index < 0 ? group.Leader : group.GetMember(index); if (Entity.Exists(Current)) { return(true); } return(MoveNext()); } return(false); }
public static void AddExplosion(Vector3 position, ExplosionType type, float radius, float cameraShake, Ped owner = null, bool aubidble = true, bool invisible = false) { if (!Entity.Exists(owner)) { InputArgument[] arguments = new InputArgument[] { position.X, position.Y, position.Z, type, radius, aubidble, invisible, cameraShake }; Function.Call(Hash.ADD_EXPLOSION, arguments); } else { InputArgument[] arguments = new InputArgument[9]; arguments[0] = owner.Handle; arguments[1] = position.X; arguments[2] = position.Y; arguments[3] = position.Z; arguments[4] = type; arguments[5] = radius; arguments[6] = aubidble; arguments[7] = invisible; arguments[8] = cameraShake; Function.Call(Hash.ADD_OWNED_EXPLOSION, arguments); } }