AgentSkillsCN

wurst-community

WurstScript 社区资源:包括示例地图、库文件、框架,以及 Warcraft 3 模组开发的项目展示。

SKILL.md
--- frontmatter
name: wurst-community
description: WurstScript community resources including example maps, libraries, frameworks, and project showcases for Warcraft 3 modding

WurstScript Community Resources

Discover community projects, libraries, and example maps built with WurstScript.

Official Resources

Documentation

Source Repositories

Community

Popular Libraries

Frentity

Lightweight entity framework for game objects.

yaml
dependencies:
  - https://github.com/Frotty/Frentity

Features:

  • Entity lifecycle management
  • Component-based architecture
  • Automatic cleanup

Wurst Lodash

Functional programming utilities inspired by Lodash.

yaml
dependencies:
  - https://github.com/theQuazz/wurst-lodash

Features:

  • Map, filter, reduce
  • Collection utilities
  • Functional helpers

Wurst Table Layout

Frame-based UI system without the complexity.

yaml
dependencies:
  - https://github.com/Frotty/wurst-table-layout

Features:

  • Grid-based layouts
  • Easy positioning
  • Responsive design

Wurst Item Shop

Complete item shop system.

yaml
dependencies:
  - https://github.com/Frotty/wurst-item-shop

Features:

  • Category-based shops
  • Custom UI
  • Transaction handling

Bounty Controller

Control bounty rewards and behavior.

yaml
dependencies:
  - https://github.com/HerlySQR/Bounty_Controller

Example Maps (Open Source)

Zombie Defense

PvE survival base building with randomized terrain.

The Last Stand

Multiplayer post-apocalyptic survival game.

Island Troll Tribes

Classic survival PvP game.

Forest Defense

Cooperative tower defense with survival elements.

Escape Builder Reloaded

In-game maze builder and escape game.

Snowball Fight

Team-based winter skirmish game.

Escape the Crab

Escape game set in ancient Japan.

Microrunner TD

Tower defense with micro-controlled runner.

Battle Planes (The Gorge)

Battleships-style AoS game.

Gold Rush

Tag-style FFA collection game.

Hunter's Hall

Team-oriented objective-based PvP.

Sheep Tag Relapse

Modern Sheep Tag implementation.

Gods' Arena

PvE hero survival against gods.

Twilight's Eve Final Fixxed

Reworked classic map.

Code Patterns from Community

Entity System (Frentity style)

wurst
import Entity

class Missile extends Entity
    angle direction
    real speed
    
    construct(vec3 pos, angle dir, real spd)
        super(pos)
        direction = dir
        speed = spd
    
    override function update()
        pos += direction.toVec(speed * ANIMATION_PERIOD).withZ(0)
        if outOfBounds()
            terminate()

Event-Driven Architecture

wurst
import ClosureEvents

// Centralized event handling
init
    EventListener.add(EVENT_PLAYER_UNIT_DEATH) ->
        onUnitDeath(GetTriggerUnit(), GetKillingUnit())
    
    EventListener.add(EVENT_PLAYER_UNIT_PICKUP_ITEM) ->
        onItemPickup(GetTriggerUnit(), GetManipulatedItem())

function onUnitDeath(unit dying, unit killer)
    // Handle death globally
    
function onItemPickup(unit picker, item itm)
    // Handle item pickup

Configuration Pattern

wurst
package SpellConfig

// Configurable values
@configurable public constant DAMAGE = 100.
@configurable public constant COOLDOWN = 10.
@configurable public constant RANGE = 600.

// Config package
package SpellConfig_config
@config public constant DAMAGE = 150.  // Override default

Unit Indexing

wurst
import HashMap

let unitData = new HashMap<unit, UnitData>()

class UnitData
    unit u
    int customValue
    
    construct(unit u)
        this.u = u
        unitData.put(u, this)
    
    ondestroy
        unitData.remove(u)

function getUnitData(unit u) returns UnitData
    return unitData.get(u)

Contributing to Community

Create a Library

  1. Create GitHub repository
  2. Add wurst.build with no dependencies (or minimal)
  3. Document API with hotdoc comments
  4. Share on Discord

Share Your Map

  1. Make repository public
  2. Include clear README
  3. Post on Discord or Hive Workshop
  4. Submit to wurstscript.github.io

Report Issues

Help Others

  • Answer questions on Discord
  • Review pull requests
  • Write tutorials
  • Create example code

Getting Help

Discord (Recommended)

https://discord.gg/mSHZpWcadz

  • #help channel for questions
  • #showcase for sharing work
  • #development for advanced topics

Hive Workshop

https://www.hiveworkshop.com/

  • Map hosting
  • Community forums
  • Resource sharing

GitHub Discussions

https://github.com/wurstscript/WurstScript/discussions

  • Long-form questions
  • Feature requests
  • General discussion

Learning Path

  1. Start: Complete beginner guide
  2. Learn: Read manual sections as needed
  3. Practice: Modify example maps
  4. Build: Create simple spells/systems
  5. Study: Read stdlib source code
  6. Share: Post work on Discord
  7. Contribute: Help others, submit PRs