Skip to content

Releases: latticexyz/mud

@latticexyz/[email protected]

12 Sep 22:09
1efccab
Compare
Choose a tag to compare
Pre-release

Major Changes

  • #1458 b9e562d8 Thanks @alvrs! - The World now performs ERC165 interface checks to ensure that the StoreHook, SystemHook, System, DelegationControl and Module contracts to actually implement their respective interfaces before registering them in the World.

    The required supportsInterface methods are implemented on the respective base contracts.
    When creating one of these contracts, the recommended approach is to extend the base contract rather than the interface.

    - import { IStoreHook } from "@latticexyz/store/src/IStore.sol";
    + import { StoreHook } from "@latticexyz/store/src/StoreHook.sol";
    
    - contract MyStoreHook is IStoreHook {}
    + contract MyStoreHook is StoreHook {}
    - import { ISystemHook } from "@latticexyz/world/src/interfaces/ISystemHook.sol";
    + import { SystemHook } from "@latticexyz/world/src/SystemHook.sol";
    
    - contract MySystemHook is ISystemHook {}
    + contract MySystemHook is SystemHook {}
    - import { IDelegationControl } from "@latticexyz/world/src/interfaces/IDelegationControl.sol";
    + import { DelegationControl } from "@latticexyz/world/src/DelegationControl.sol";
    
    - contract MyDelegationControl is IDelegationControl {}
    + contract MyDelegationControl is DelegationControl {}
    - import { IModule } from "@latticexyz/world/src/interfaces/IModule.sol";
    + import { Module } from "@latticexyz/world/src/Module.sol";
    
    - contract MyModule is IModule {}
    + contract MyModule is Module {}

Minor Changes

  • #1422 1d60930d Thanks @alvrs! - It is now possible to unregister Store hooks and System hooks.

    interface IStore {
      function unregisterStoreHook(bytes32 table, IStoreHook hookAddress) external;
      // ...
    }
    
    interface IWorld {
      function unregisterSystemHook(bytes32 resourceSelector, ISystemHook hookAddress) external;
      // ...
    }
  • #1443 5e71e1cb Thanks @holic! - Moved KeySchema, ValueSchema, SchemaToPrimitives and TableRecord types into @latticexyz/protocol-parser

Patch Changes

@latticexyz/[email protected]

12 Sep 22:10
1efccab
Compare
Choose a tag to compare
Pre-release

Patch Changes

@latticexyz/[email protected]

12 Sep 22:09
1efccab
Compare
Choose a tag to compare
Pre-release

Patch Changes

@latticexyz/[email protected]

12 Sep 22:09
1efccab
Compare
Choose a tag to compare
Pre-release
@latticexyz/[email protected]

@latticexyz/[email protected]

12 Sep 22:09
1efccab
Compare
Choose a tag to compare
Pre-release
@latticexyz/[email protected]

@latticexyz/[email protected]

12 Sep 22:09
1efccab
Compare
Choose a tag to compare
Pre-release

Patch Changes

@latticexyz/[email protected]

12 Sep 22:09
1efccab
Compare
Choose a tag to compare
Pre-release

Patch Changes

@latticexyz/[email protected]

12 Sep 22:09
1efccab
Compare
Choose a tag to compare
Pre-release

Minor Changes

  • #1443 5e71e1cb Thanks @holic! - Adds decodeKey, decodeValue, encodeKey, and encodeValue helpers to decode/encode from key/value schemas. Deprecates previous methods that use a schema object with static/dynamic field arrays, originally attempting to model our on-chain behavior but ended up not very ergonomic when working with table configs.

Patch Changes

@latticexyz/[email protected]

12 Sep 22:09
1efccab
Compare
Choose a tag to compare
Pre-release

Patch Changes

@latticexyz/[email protected]

12 Sep 22:09
1efccab
Compare
Choose a tag to compare
Pre-release
@latticexyz/[email protected]