public void Paint(PaintableSurfaceTexture surface) { surface.PaintSurface(new PaintSurfaceInfo { WorldPos = WorldPos2D, Radius = (int)(PaintingData.Radius * RadiusMult), Color = PaintingData.Color }); }
public void Update() { if (Surface == null) { var go = GameObject.FindGameObjectWithTag("MainSurface"); if (go == null) { return; } Surface = go.GetComponent <PaintableSurfaceTexture>(); } if (ReleasePaint || Surface != null) { Paint(Surface); } }