fabricator77 Posted May 8, 2012 Share Posted May 8, 2012 I have some code with this line in it. int k = par1World.getTopSolidOrLiquidBlock(i, j) - 1; k is the height of the block involved. Problem is it lies, and returns to the top solid block completely ignoring water, ice etc. So what I want is the code to detect what blockID is above the dirt/sand/grass etc, and if its not air (water, ice etc) then use different code. I tried using getBlockIdAtCurrentPosition, but no matter what I've tried it just won't return any value except 0 (air). Anyone used this function and know how it works ? Is there a better way to code this ? Link to comment Share on other sites More sharing options...
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!Register a new account
Already have an account? Sign in here.Sign In Now