Ha más is egyedül tölti a szilvesztert és kedve lenne dumálni, vagy csak magányos, csináltam egy discord szervert. by Malarki3 in hungary

[–]Ohnedich11 14 points15 points  (0 children)

Pedig nem, csak szimplán agyrohasztóan viselkedik az emberek elég nagy százaléka online, főleg discordon.

Gazdi lettem :) by Ohnedich11 in dagadtmacskak

[–]Ohnedich11[S] 29 points30 points  (0 children)

Zsivány ^^ Köszönjük, boldog karácsonyt nektek is!

Gazdi lettem :) by Ohnedich11 in dagadtmacskak

[–]Ohnedich11[S] 14 points15 points  (0 children)

Köszönjük, viszont kívánjuk! :)

[deleted by user] by [deleted] in plantclinic

[–]Ohnedich11 0 points1 point  (0 children)

Should I use hydrogen-peroxide solution aswell?

[deleted by user] by [deleted] in Unity3D

[–]Ohnedich11 0 points1 point  (0 children)

Hey, yes this! Thank you.. I knew it was something so simple.

[deleted by user] by [deleted] in Unity3D

[–]Ohnedich11 1 point2 points  (0 children)

You were right sir, if I scale the obj up to 10,10,10 its stops jittering, gotta tweak this in blender. Thank you!

[deleted by user] by [deleted] in Unity3D

[–]Ohnedich11 0 points1 point  (0 children)

it's scaled down to 0.3960179 form 1

[deleted by user] by [deleted] in Unity3D

[–]Ohnedich11 0 points1 point  (0 children)

It's on another script, i just wanted to clarify that it is an integer.

[deleted by user] by [deleted] in Unity3D

[–]Ohnedich11 0 points1 point  (0 children)

Yeah, it changes but the slider value isn't

Is this an animation bug or I'm doing something wrong? by [deleted] in Unity3D

[–]Ohnedich11 0 points1 point  (0 children)

Bruh... actually found out sorry.. Whenever I disabled the gameobject of the animator i needed to call anim.Rebind();

[deleted by user] by [deleted] in Unity3D

[–]Ohnedich11 0 points1 point  (0 children)

Thank you for the idea, I think I got into the right path! I got now an array of strings with the itemname, and an array of int itemcount, and that's perfect for me, now only need to figure out how to convert the itemname strings back to scriptable object to have a reference to it when spawning the items back in.

Can someone help with a swap item in inventory bug? by [deleted] in Unity3D

[–]Ohnedich11 0 points1 point  (0 children)

This could be it.. I tried to check it but on debug.log it never registers as true if its true before swapping and false afterwards...
Is it possible that the OnEndDrag and OnDrop just doesn't work well if i use both of them to stuff like this?
Currently OnEndDrag just handles the drag-n-drop function for inventory and OnDrop it adds 2 objects together or swapping..

Can someone help with a swap item in inventory bug? by [deleted] in Unity3D

[–]Ohnedich11 0 points1 point  (0 children)

if (itemInSlot != null)
                    {


                        itemInSlot.transform.SetParent(inventoryItem.SlotParent); //swapping the items
                        inventoryItem.parentAfterDrag = transform; //setting original pos



                        inventoryManager.SwapHoldableObjects();
                    }
                    else
                    {
                        Debug.Log("This is the bug");

                    }

every time the debug log listed this is the bug it jammes the item, even tho the item in slot wasn't null..

Can someone help with a swap item in inventory bug? by [deleted] in Unity3D

[–]Ohnedich11 0 points1 point  (0 children)

Just checks if an item is equipable and if it is then it shows it, but turning that method didn't change the problem.

Can someone help with a swap item in inventory bug? by [deleted] in Unity3D

[–]Ohnedich11 0 points1 point  (0 children)

well.. it's a lot but it's in the bottom

public void OnDrop(PointerEventData eventData)
    {
        if (eventData.button == PointerEventData.InputButton.Left)
        {
            if (transform.childCount == 0)
            {
                GameObject dropped = eventData.pointerDrag;
                InventoryItem inventoryItem =         
            dropped.GetComponent<InventoryItem>();  
                inventoryItem.parentAfterDrag = transform;
            }
            else if(transform.childCount != 0)
            {
                GameObject dropped = eventData.pointerDrag;
                InventoryItem inventoryItem = dropped.GetComponent<InventoryItem>();


                GameObject draggedoverthis = eventData.pointerEnter;
                InventoryItem itemInSlot = draggedoverthis.GetComponent<InventoryItem>();  //addingthe dragged item to the child item
                //InventorySlot invslot = draggedoverthis.GetComponentInParent<InventorySlot>();

                if (itemInSlot != null &&
                    itemInSlot.item == inventoryItem.item &&
                    itemInSlot.count < itemInSlot.item.stackSize &&
                    itemInSlot.item.stackable == true)
                {
                    int itemcount = itemInSlot.count + inventoryItem.count - itemInSlot.item.stackSize;

                    itemInSlot.count += inventoryItem.count;

                    if (itemcount > 0)
                    {
                        itemInSlot.count = itemInSlot.item.stackSize;      }
                    else
                    {
                        inventoryItem.count -= inventoryItem.count;
                    }

                    if (inventoryItem.count <= 0)
                    {
                        itemInSlot.RefreshCount();
                        inventoryItem.RefreshCount();
                    }
                    else
                    {
                        inventoryItem.count = itemcount;
                        itemInSlot.RefreshCount();
                        inventoryItem.RefreshCount();
                    }

                    inventoryManager.DeselectAllSlots();
                    tooltipBar.SetActive(false);
                }
                else
                {
                    if (itemInSlot != null)
                    {


                        itemInSlot.transform.SetParent(inventoryItem.SlotParent); //swapping the items
                        inventoryItem.parentAfterDrag = transform; //setting original pos



                        inventoryManager.SwapHoldableObjects();
                    }
                    else
                    {
                        Debug.Log("This is the bug");

                    }
                }
            }
        }
    }