Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

API: cBlockArea:DoWithBlockEntityAt and DoWithBlockEntityRelAt are not accepting Vector3i #4415

Open
Seadragon91 opened this issue Oct 6, 2019 · 1 comment

Comments

@Seadragon91
Copy link
Contributor

@Seadragon91 Seadragon91 commented Oct 6, 2019

Actual behavior

This two functions DoWithBlockEntityAt and DoWithBlockEntityRelAt don't accept a Vector3i, but they should be.

Steps to reproduce the behavior

local blockArea = cBlockArea()
blockArea:Create(10, 10, 10, 35)
blockArea:SetBlockTypeMeta(2, 2, 2, E_BLOCK_CHEST, 2)
blockArea:DoWithBlockEntityAt(Vector3i(2, 2, 2), -- Should work, but fails
	function(a_BlockEntity)
		print("found")
	end)

In the code I see that this two functions are passed to a DoWithXYZ function. There is only checked for the x, y and z coord.

Not sure what the best way would be to correct that.

@Seadragon91

This comment has been minimized.

Copy link
Contributor Author

@Seadragon91 Seadragon91 commented Oct 6, 2019

Would it be the best to move it into two methods and use readVector3iOverloadParams to check them?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
1 participant
You can’t perform that action at this time.