Jump to content

Power Bracelet (Liftable)

Overview
Creator: Emily Updated: 17 Feb 2022 Tags: 2.55, Weapon, Item Downloads: 116
Rating[?]: Rating: 4.33/5 (2 ratings)
Download Example
(6 MB)
Information

Description Setup Reviews Comments

Only std.zh is required.

CONSTANTS:
CB_LIFT - the button to use to lift stuff (default CB_A)
CB_THROW - the button to use to throw stuff (default same as CB_LIFT)
HELD_DRAW_LAYER - the layer to draw the held object to (default 3)
WEAPON_DRAW_LAYER - the layer to draw the thrown weapon to (default 3)
TILE_INVIS - An invisible tile (default 20)
LW_THROWN - the LW_ type to use for the weapon (default LW_SCRIPT1)
SHADOW_SPRITE - the Weapons/Misc sprite to use for the shadow (default 50)
TOP_GRABBABLE_LAYER - the highest layer that combos can be grabbed from
USE_PTM - Whether or not to include the Player Tile Modifier in custom player sprites.

ITEM:
  • Set the flag "Constant Script" (Flag 15)
  • Assign the script to the "Action" slot
  • Set up parameters:
  • d0 - the Step of the thrown lweapon (movement speed)
  • d1 - the initial Jump of the thrown lweapon (vertical movement)
  • d2 - Lift Delay (the number of frames it takes to lift an object)
  • d3 - Custom animation:
  • To use no custom animation, set this to 0
  • To set up a custom animation:
  • Create 16 combos in a row.
  • First 4: Up,Down,Left,Right - standing still
  • Second 4: Up,Down,Left,Right - walking
  • Third 4: Up,Down,Left,Right - swimming
  • Fourth 4: Up,Down,Left,Right - Lifting
  • Set d3 to the upper-left combo (up-facing, standing still), and this will be used.
  • UseSound: The value set as the sound will be used for the 'Lift' SFX. The next sound after this (n+1) will be used for the 'Throw' SFX.
  • Flags
  • Flag 0: Can carry while swimming
  • Flag 1: Will drop held object if hit
  • Flag 2: Can carry across screens
No setup is required for the lweapon script, though make sure it is assigned to a slot!
For EACH COMBO:
  • Set up type/flag
    • EITHER set the type to 'Bush->Next', OR set the inherent flag to 'Pot, Liftable (Scripted)', 'Pot, Slash or Lift (Scripted)', or 'Rock, Lift Normal (Scripted) to have the combo be liftable.
    • If you instead set the inherent flag to 'Rock, Lift Heavy (Scripted)', it will only be liftable if the bracelet item has a 'Power' higher than '1'.
  • Set up Attributes
    • Attributes[0] - Weapons/Misc sprite to use on breaking the object
    • Attributes[1] - Damage done by the thrown object
    • Attributes[2] - If positive, the item ID to drop when broken. If negative, the item dropset to drop an item from when broken.
    • Attributes[3] - SFX to play when broken
  • Set up Misc Flags
    • Flags[5] - If this is checked, the next combo in the list will be used instead of the undercombo. (Bush->Next combotypes always do this)
    • Flags[6] - If this is checked, the item will only be dropped once (as the screen's Special Item).
    • Flags[7] - If this is checked, the item will drop when the object breaks, instead of when you lift it