How make a branching from drag and drop like this?
up vote
0
down vote
favorite
what should I fix or add from the following code, so that I can check true or false when it's done dragging both ?
Drag and drop check tru or false
#region IDropHandler implementation
public void OnDrop(PointerEventData eventData)
{
if (!item)
{
DragHandeler.itemBeingDragged.transform.SetParent(transform);
//ExecuteEvents.ExecuteHierarchy<IHasChanged>(gameObject, null, (x, y) => x.HasChanged());
}
if (DragHandeler.itemBeingDragged != null)
{
if (DragHandeler.itemBeingDragged == CorrectAnswer)
{
Debug.Log("benar");
StartCoroutine(LoadLevelAfterDelay(delay));
}
else
{
Debug.Log("salah");
}
}
}
#endregion
drag-and-drop
New contributor
add a comment |
up vote
0
down vote
favorite
what should I fix or add from the following code, so that I can check true or false when it's done dragging both ?
Drag and drop check tru or false
#region IDropHandler implementation
public void OnDrop(PointerEventData eventData)
{
if (!item)
{
DragHandeler.itemBeingDragged.transform.SetParent(transform);
//ExecuteEvents.ExecuteHierarchy<IHasChanged>(gameObject, null, (x, y) => x.HasChanged());
}
if (DragHandeler.itemBeingDragged != null)
{
if (DragHandeler.itemBeingDragged == CorrectAnswer)
{
Debug.Log("benar");
StartCoroutine(LoadLevelAfterDelay(delay));
}
else
{
Debug.Log("salah");
}
}
}
#endregion
drag-and-drop
New contributor
add a comment |
up vote
0
down vote
favorite
up vote
0
down vote
favorite
what should I fix or add from the following code, so that I can check true or false when it's done dragging both ?
Drag and drop check tru or false
#region IDropHandler implementation
public void OnDrop(PointerEventData eventData)
{
if (!item)
{
DragHandeler.itemBeingDragged.transform.SetParent(transform);
//ExecuteEvents.ExecuteHierarchy<IHasChanged>(gameObject, null, (x, y) => x.HasChanged());
}
if (DragHandeler.itemBeingDragged != null)
{
if (DragHandeler.itemBeingDragged == CorrectAnswer)
{
Debug.Log("benar");
StartCoroutine(LoadLevelAfterDelay(delay));
}
else
{
Debug.Log("salah");
}
}
}
#endregion
drag-and-drop
New contributor
what should I fix or add from the following code, so that I can check true or false when it's done dragging both ?
Drag and drop check tru or false
#region IDropHandler implementation
public void OnDrop(PointerEventData eventData)
{
if (!item)
{
DragHandeler.itemBeingDragged.transform.SetParent(transform);
//ExecuteEvents.ExecuteHierarchy<IHasChanged>(gameObject, null, (x, y) => x.HasChanged());
}
if (DragHandeler.itemBeingDragged != null)
{
if (DragHandeler.itemBeingDragged == CorrectAnswer)
{
Debug.Log("benar");
StartCoroutine(LoadLevelAfterDelay(delay));
}
else
{
Debug.Log("salah");
}
}
}
#endregion
drag-and-drop
drag-and-drop
New contributor
New contributor
New contributor
asked Nov 5 at 1:59
Riska Anisah
1
1
New contributor
New contributor
add a comment |
add a comment |
active
oldest
votes
active
oldest
votes
active
oldest
votes
active
oldest
votes
active
oldest
votes
Riska Anisah is a new contributor. Be nice, and check out our Code of Conduct.
draft saved
draft discarded
Riska Anisah is a new contributor. Be nice, and check out our Code of Conduct.
Riska Anisah is a new contributor. Be nice, and check out our Code of Conduct.
Riska Anisah is a new contributor. Be nice, and check out our Code of Conduct.
draft saved
draft discarded
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53147369%2fhow-make-a-branching-from-drag-and-drop-like-this%23new-answer', 'question_page');
}
);
Post as a guest
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password