public void add(Particle particle, IParticleForceGenerator forceGenerator) { ParticleForceRegistration registration = new ParticleForceRegistration(); registration.particle = particle; registration.forceGenerator = forceGenerator; registrations.Add(registration); }
public void remove(Particle particle, IParticleForceGenerator forceGenerator) { foreach (ParticleForceRegistration i in registrations) { if (i.particle == particle && i.forceGenerator == forceGenerator) { registrations.Remove(i); return; } } }
public void Remove(Particle particle, IParticleForceGenerator fg) { PhysicsEngineForFunPINVOKE.ParticleForceRegistry_Remove(swigCPtr, Particle.getCPtr(particle), IParticleForceGenerator.getCPtr(fg)); }
internal static global::System.Runtime.InteropServices.HandleRef getCPtr(IParticleForceGenerator obj) { return((obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr); }
public void Add(Particle particle, IParticleForceGenerator fg) { registrations.Add(new ParticleForceRegistration(particle, fg)); }
internal ParticleForceRegistration(Particle particle, IParticleForceGenerator fg) { this.particle = particle; this.fg = fg; }