Interact Icon in Inventory

Started by metalmario991, Sun 08/03/2015 02:33:07

Previous topic - Next topic

metalmario991

I am trying to implement a Use/Interact Icon in the inventory box, but I am running into some problems. When you click on it changes to the walk icon and it doesn't interact with anything. Here's how I wrote it;

function bInteract_OnClick(GUIControl *control, MouseButton button)
{
mouse.Mode = eModeInteract;
mouse.UseModeGraphic(eModeInteract);
}

Slasher

#1
If I understand correctly you want the button to change cursor to interact.

you will need to, in the button properties, select: click action, SetCursorMode.

Change: NewModeNumber to 2 (interact).

Hope this fulfills what you wanted..



metalmario991

I got the cursor to change but it is just doing the same thing as the pointer icon. I need the player to be able to interact items within the inventory. How do I do this?

monkey0506

What code do you have for clicking on the inventory? Is "Handle inventory clicks in script" enabled in the General Settings?

metalmario991

In the Inventory section for General Settings I have this:

Display multiple icons for multiple items = false
Inventory item cursor hotspot marker = none
Override built-in inventory window click handling = false
Use selected inventory graphic for cursor

Will that help?

SMF spam blocked by CleanTalk