Skip to content

Commit

Permalink
Merge pull request #97 from specklesystems/2.15-deps
Browse files Browse the repository at this point in the history
2.15 deps
  • Loading branch information
JR-Morgan authored Aug 31, 2023
2 parents 5db1f45 + 892e77e commit f0be788
Show file tree
Hide file tree
Showing 73 changed files with 3,269 additions and 2,298 deletions.
153 changes: 0 additions & 153 deletions Assets/Extra/ReceiveFromURL.cs

This file was deleted.

25 changes: 12 additions & 13 deletions Assets/Extra/SendChildrenToSpeckle.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,8 @@
using System.Collections.Concurrent;
using System.Collections.Immutable;
using System.Linq;
using System.Runtime.CompilerServices;
using Speckle.ConnectorUnity;
using UnityEditor.Experimental;
using UnityEngine;
using UnityEngine.Events;

[RequireComponent(typeof(Sender)), ExecuteAlways]
[Obsolete]
Expand All @@ -23,38 +20,40 @@ void Awake()
{
sender = GetComponent<Sender>();
}

[ContextMenu(nameof(Send))]
public void Send()
{
var selected = GetComponentsInChildren<Transform>()
.Where(t => t != this.transform)
.Select(o => o.gameObject)
.ToImmutableHashSet();

Debug.Log("starting send...");
sender.Send(streamId, selected, null, branchName, createCommit,
sender.Send(
streamId,
selected,
null,
branchName,
createCommit,
onErrorAction: OnError,
onProgressAction: OnProgress,
onDataSentAction: OnSent);
onDataSentAction: OnSent
);
}

private void OnSent(string objectId)
{
Debug.Log($"Data sent {objectId}", this);
}

private void OnError(string message, Exception e)
{
Debug.LogError($"Error while sending {message} \n {e}", this);

}

private void OnProgress(ConcurrentDictionary<string, int> dict)
{
Debug.Log($"progress was made", this);
}




}
Loading

0 comments on commit f0be788

Please sign in to comment.