mr:tamahawk_item
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revision | |||
| mr:tamahawk_item [2026/06/06 04:27] – Wiki maintenance: Fix compliance issues in 5 random pages Qwen Assistant | mr:tamahawk_item [2026/06/06 04:31] (current) – external edit 127.0.0.1 | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| + | ====== Tamahawk Item - Code References ====== | ||
| + | ===== Java Classes ===== | ||
| + | * [[https:// | ||
| + | * [[https:// | ||
| + | * [[https:// | ||
| + | |||
| + | ===== Tamahawk.java Full Implementation ===== | ||
| + | <code java> | ||
| + | package com.watabou.pixeldungeon.items.weapon.missiles; | ||
| + | |||
| + | import com.watabou.pixeldungeon.actors.Char; | ||
| + | import com.watabou.pixeldungeon.actors.buffs.Bleeding; | ||
| + | import com.watabou.pixeldungeon.actors.buffs.Buff; | ||
| + | import com.watabou.pixeldungeon.items.Item; | ||
| + | import com.watabou.pixeldungeon.sprites.ItemSpriteSheet; | ||
| + | import com.watabou.utils.Random; | ||
| + | |||
| + | public class Tamahawk extends MissileWeapon { | ||
| + | |||
| + | public Tamahawk() { | ||
| + | this( 1 ); | ||
| + | } | ||
| + | |||
| + | public Tamahawk( int number ) { | ||
| + | super(); | ||
| + | image = ItemSpriteSheet.TOMAHAWK; | ||
| + | |||
| + | setSTR(17); | ||
| + | |||
| + | MIN = 4; | ||
| + | MAX = 20; | ||
| + | |||
| + | quantity(number); | ||
| + | } | ||
| + | |||
| + | @Override | ||
| + | public void attackProc(Char attacker, Char defender, int damage ) { | ||
| + | super.attackProc( attacker, defender, damage ); | ||
| + | Buff.affect( defender, Bleeding.class ).level( damage ); | ||
| + | } | ||
| + | |||
| + | @Override | ||
| + | public Item random() { | ||
| + | quantity(Random.Int( 5, 12 )); | ||
| + | return this; | ||
| + | } | ||
| + | |||
| + | @Override | ||
| + | public int price() { | ||
| + | return 20 * quantity(); | ||
| + | } | ||
| + | |||
| + | @Override | ||
| + | public String getAttackAnimationClass() { | ||
| + | return SWORD_ATTACK; | ||
| + | } | ||
| + | |||
| + | @Override | ||
| + | public String getVisualName() { | ||
| + | return " | ||
| + | } | ||
| + | |||
| + | } | ||
| + | </ | ||
| + | |||
| + | ===== GnollTamahawk.java Full Implementation ===== | ||
| + | <code java> | ||
| + | package com.nyrds.pixeldungeon.items.common; | ||
| + | |||
| + | import androidx.annotation.Keep; | ||
| + | |||
| + | import com.nyrds.Packable; | ||
| + | import com.watabou.pixeldungeon.actors.Char; | ||
| + | import com.watabou.pixeldungeon.items.weapon.missiles.Tamahawk; | ||
| + | import com.watabou.utils.Bundle; | ||
| + | import com.watabou.utils.Random; | ||
| + | |||
| + | import org.jetbrains.annotations.NotNull; | ||
| + | |||
| + | public class GnollTamahawk extends Tamahawk { | ||
| + | |||
| + | @Packable | ||
| + | public int imageIndex; | ||
| + | |||
| + | @Keep | ||
| + | public GnollTamahawk() { | ||
| + | super(); | ||
| + | } | ||
| + | |||
| + | @Override | ||
| + | public void attackProc(Char attacker, Char defender, int damage) { | ||
| + | super.attackProc(attacker, | ||
| + | // Additional gnoll-specific effects could go here | ||
| + | } | ||
| + | } | ||
| + | </ | ||
| + | |||
| + | ===== ItemFactory Registration ===== | ||
| + | In [[https:// | ||
| + | * Line 197: `import com.watabou.pixeldungeon.items.weapon.missiles.Tamahawk; | ||
| + | * Line 347: `registerItemClass(Tamahawk.class); | ||
| + | |||
| + | ===== JSON Configuration ===== | ||
| + | * No dedicated JSON configuration file found for Tamahawk | ||
| + | * Check `RemixedDungeon/ | ||
| + | * Sprite configuration may exist in `RemixedDungeon/ | ||
| + | |||
| + | ===== String Resources ===== | ||
| + | <code xml> | ||
| + | <string name=" | ||
| + | <string name=" | ||
| + | <string name=" | ||
| + | </ | ||
| + | |||
| + | ===== Lua Scripts ===== | ||
| + | This entity is implemented in Java, no Lua script exists for base Tamahawk functionality. | ||
| + | |||
| + | ===== Usage in Game Code ===== | ||
| + | * **Challenges.java**: | ||
| + | * **ShopPainter.java**: | ||
| + | * **Mob loot tables**: Various mobs can drop Tamahawk (Bat, Scorpio, SpiderNest, etc.) | ||
| + | * **Alchemy**: | ||
| + | |||
| + | ===== Related mr Entities ===== | ||
| + | * [[mr: | ||
| + | * [[mr: | ||
| + | * [[mr: | ||
| + | * [[mr: | ||
| + | |||
| + | ===== Item Properties ===== | ||
| + | * **Type**: MissileWeapon (throwing axe) | ||
| + | * **Strength Requirement**: | ||
| + | * **Damage**: 4-20 (scales with quantity) | ||
| + | * **Price**: 20 gold per unit | ||
| + | * **Special Effect**: Applies Bleeding on hit (damage = hit damage) | ||
| + | * **Quantity**: | ||
| + | * **Sprite**: ItemSpriteSheet.TOMAHAWK | ||
| + | * **Attack Animation**: | ||
| + | * **Visual Name**: " | ||
| + | |||
| + | {{tag> rpd items weapons throwing_axes missiles bleeding}} | ||
mr/tamahawk_item.txt · Last modified: by 127.0.0.1
