GithubHelp home page GithubHelp logo

Comments (15)

Blueyescat avatar Blueyescat commented on June 23, 2024 1

Yeah. The code in the make gui section runs on inventory click event.

from tuske.

Blueyescat avatar Blueyescat commented on June 23, 2024

Just read the error message, you can't use gui outside of make gui.

make gui slot 1, 3, 10, 11, 12, 19, 28, 36, 37, 45, 46, 52 and 53 with black stained glass pane named "&0":
	if slot 1 of gui is dirt:
		make gui slot 1 with grass
	else:
		make gui slot 1 with diamond block

from tuske.

HYPExMon5ter avatar HYPExMon5ter commented on June 23, 2024

I did, I was asked by tuke to make an issue though

from tuske.

Blueyescat avatar Blueyescat commented on June 23, 2024

I can't see purpose on using gui in create gui section.

from tuske.

HYPExMon5ter avatar HYPExMon5ter commented on June 23, 2024

to get the inventory of the gui you're creating??

from tuske.

Blueyescat avatar Blueyescat commented on June 23, 2024

Why you would want that lol. But did you try to use gui "id" or last gui? If you aren't able to use them, then the same for gui. I needs to create the expression and edit it instantly before end of the create gui section.

from tuske.

HYPExMon5ter avatar HYPExMon5ter commented on June 23, 2024

making a slot stealable without having to have on on inventory open or conditionals, like i provided in the code above, etc., there are quite a few uses. and I'm not gonna create a gui with a id if it's not gonna stay the same or close to it, there's no point.

from tuske.

Blueyescat avatar Blueyescat commented on June 23, 2024

You can use last gui already. Also as i remember you can use

make gui ...:
    uncancel event

to get stealable items, also with actions.

from tuske.

HYPExMon5ter avatar HYPExMon5ter commented on June 23, 2024

that'd make all items stealable, i want specific items stealable.

from tuske.

Blueyescat avatar Blueyescat commented on June 23, 2024

No it shouldn't do that. The manager cancels inventory click event when you click on a gui item, this uncancels it.

last gui in create gui section works fine by the way, i tested it.

from tuske.

HYPExMon5ter avatar HYPExMon5ter commented on June 23, 2024

oh i see what you're saying. Like

make gui slot 1 with grass:
    uncancel event

? that way only the grass would be stealable?

from tuske.

HYPExMon5ter avatar HYPExMon5ter commented on June 23, 2024

Anyways, I only posted this cause I was asked by tuke to do so lol

from tuske.

Blueyescat avatar Blueyescat commented on June 23, 2024

[the] gui support may look better than last gui when used in create gui section. Since last gui in create gui works it is easy to do. But still i can't see advantages πŸ˜›

from tuske.

Tuke-Nuke avatar Tuke-Nuke commented on June 23, 2024

I tested it and I can't replicate your issue. The gui expression is used when you click in a gui slot, if it's outside of make gui effect like your example, the right one is last gui. It might be just a syntax mistake where the syntax last [created] gui represents the current gui that is being created/edited.
So your code will work fine as:

command /bug:
	trigger:
		create a gui with virtual chest with 2 rows named "TuSKe Bug":
			make gui slot 1, 3, 10, 11, 12, 19, 28, 36, 37, 45, 46, 52 and 53 with black stained glass pane named "&0"
			if slot 1 of last gui is dirt:
				make gui slot 1 with grass
			else:
				make gui slot 1 with diamond block
		open last created gui to player

from tuske.

HYPExMon5ter avatar HYPExMon5ter commented on June 23, 2024

Oh okay, thanks :)

from tuske.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.