diff --git a/debian/client/common/usr/bin/minecraft-pi b/debian/client/common/usr/bin/minecraft-pi index 9b379520f..285525761 100755 --- a/debian/client/common/usr/bin/minecraft-pi +++ b/debian/client/common/usr/bin/minecraft-pi @@ -4,7 +4,7 @@ set -e # Ensure Features Are Selected if [ -z "${MCPI_SUBSHELL}" ]; then - MCPI_FEATURES="$(zenity --class 'Minecraft - Pi edition' --list --checklist --column 'Enabled' --column 'Feature' TRUE 'Touch GUI' FALSE 'Survival Mode' TRUE 'Fix Bow & Arrow' TRUE 'Fix Attacking' TRUE 'Mob Spawning' TRUE 'Fancy Graphics' TRUE 'Disable Autojump By Default' TRUE 'Fix Sign Placement' TRUE 'Show Block Outlines' FALSE 'Expand Creative Inventory' FALSE 'Peaceful Mode' TRUE 'Animated Water')" + MCPI_FEATURES="$(zenity --class 'Minecraft - Pi edition' --list --checklist --column 'Enabled' --column 'Feature' TRUE 'Touch GUI' FALSE 'Survival Mode' TRUE 'Fix Bow & Arrow' TRUE 'Fix Attacking' TRUE 'Mob Spawning' TRUE 'Fancy Graphics' TRUE 'Disable Autojump By Default' TRUE 'Fix Sign Placement' TRUE 'Show Block Outlines' FALSE 'Expand Creative Inventory' FALSE 'Peaceful Mode' TRUE 'Animated Water' TRUE 'Remove Invalid Item Background')" MCPI_USERNAME="$(zenity --class 'Minecraft - Pi edition' --entry --text 'Minecraft Username:' --entry-text 'StevePi')" fi export MCPI_FEATURES diff --git a/mods/src/extra.c b/mods/src/extra.c index 5038bd655..4dbf8d3bf 100644 --- a/mods/src/extra.c +++ b/mods/src/extra.c @@ -280,4 +280,10 @@ __attribute__((constructor)) static void init() { int block_outlines = extra_has_feature("Show Block Outlines"); unsigned char outline_patch[4] = {block_outlines ? !touch_gui : touch_gui, 0x00, 0x50, 0xe3}; patch((void *) 0x4a210, outline_patch); + + if (extra_has_feature("Remove Invalid Item Background")) { + // Remove Invalid Item Background (A Red Background That Appears For Items That Are Not Obtainable Without Modding/Inventory Editing) + unsigned char invalid_item_background_patch[4] = {0x00, 0xf0, 0x20, 0xe3}; + patch((void *) 0x63c98, invalid_item_background_patch); + } }