Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 11 additions & 1 deletion programs/survival/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,11 @@ Various scripts that modify various game elements, often replicating popular mod
you have a 1/50 chance of getting a wet sponge.
Can be used to make renewable sponge without the use of lightning RNG manipulation,
which in 1.14+ is impossible, hence the name easier_renweable_sponge.


### [elytra_swap.sc](https://github.com/gnembon/scarpet/blob/master/programs/survival/elytra_swap.sc):
#### By IceWolf23
By right-clicking with an elytra or any chestplate this script will swap the items

### [enchanting_table_bottling.sc](https://github.com/gnembon/scarpet/blob/master/programs/survival/enchanting_table_bottling.sc):
#### By Firigion
Shift right clicking on an enchanting table with an empty glass bottle consumes it and generates a
Expand Down Expand Up @@ -180,6 +184,11 @@ Various scripts that modify various game elements, often replicating popular mod
#### By Gnottero
Allows the player to milk sheeps using a bucket.

### [mob_display_health.sc](https://github.com/gnembon/scarpet/blob/master/programs/survival/mob_display_health.sc):
#### By IceWolf23
When a player hits any entity, the Mob Type is displayed with the remaining life (in HP) in the actionbar


### [nether_poi.sc](https://github.com/gnembon/scarpet/blob/master/programs/survival/nether_poi.sc):
#### By Firigion
When holding an ender eye, all nether portal points of interest will be shown with a marker.
Expand Down Expand Up @@ -443,4 +452,5 @@ Various scripts that modify various game elements, often replicating popular mod
Xendergo
ch-yx
Crec0
IceWolf23
(Many more hopefully!)
15 changes: 15 additions & 0 deletions programs/survival/elytra_swap.sc
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
// By right-clicking with an elytra or any chestplate this script will swap the items
// By: IceWolf23

global_swappable_items = {'netherite_chestplate','diamond_chestplate','iron_chestplate','golden_chestplate','chainmail_chestplate','leather_chestplate','elytra'};


__on_player_uses_item(player, item_tuple, hand) -> (
if ( hand == 'mainhand' && inventory_get(player, 38) != null && has(global_swappable_items, item_tuple:0),
playerArmorDressed = inventory_get(player, 38);
handSlot = query(player, 'selected_slot');

inventory_set(player, handSlot, 1, playerArmorDressed:0, playerArmorDressed:2);
inventory_set(player, 38, 1, item_tuple:0, item_tuple:2);
)
);
10 changes: 10 additions & 0 deletions programs/survival/mob_display_health.sc
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
// When a player hits any entity, the Mob Type is displayed with the remaining life (in HP) in the actionbar
// By: IceWolf23

__on_player_deals_damage(player, amount, entity) -> (
entity_hp = entity ~ 'health';
_entityHealth = max(0, entity_hp-floor(amount));

text_string = (format('w '+entity)+format('g » ')+format('r '+_entityHealth+' ❤'));
display_title(player, 'actionbar', text_string);
);