Skip to content

LAUFactory

Overview

LAUFactory is the factory contract for deploying new LAU user token instances. It manages the connection to VOID and handles ownership configuration during user token creation.

  • License: Sharia
  • Solidity: ^0.8.21

What This Means For Players

Plain English Summary: LAUFactory is the account creator - it makes new player accounts. When you first join Dysnomia, you call this factory to create your personal LAU token. It handles all the complex setup: creating your session, generating your Soul ID, setting up your keys, and making sure you own your account (not the factory).

Real-World Analogy: Think of LAUFactory like the sign-up page for a video game. You enter your desired name, click "Create Account," and the system does all the heavy lifting: setting up your profile, generating your player ID, and giving you access to the game. LAUFactory is that sign-up process for Dysnomia.

How It Affects Your Gameplay: - Account creation - This is where your journey begins - call New() to create your LAU - Full ownership - After creation, YOU own your LAU - the factory has no control - Automatic setup - Your Soul ID, Aura, SHIO, and all related tokens are created automatically

State Variables

Variable Type Visibility Description
Void VOID public Reference to VOID session manager

Read Functions

Void

VOID public Void
- Returns: Reference to the VOID contract

Write Functions

New

function New(string memory name, string memory symbol) public returns (LAU Mu)
- Access: public - Parameters: - name (string): Token name for the player account (e.g., "Alice's Token") - symbol (string): Token symbol for the player account (e.g., "ALICE") - Returns: - Mu (LAU): Newly deployed LAU player token contract - Description: Deploys a new LAU player token, which triggers full player setup via VOID.Enter(), then configures ownership. - Logic Flow: 1. Deploy new LAU: Mu = new LAU(name, symbol, address(Void)) 2. LAU constructor internally calls: Void.Enter(address(this)) 3. VOID.Enter triggers: SIU.Miu → ZHENG.Mau → ZHOU.React → complete token generation 4. LAU receives its Saat array (including Soul ID at index 1) 5. Add caller as LAU owner: Mu.addOwner(msg.sender) 6. Add transaction origin as LAU owner: Mu.addOwner(tx.origin) 7. Renounce factory ownership: Mu.renounceOwnership(address(this)) 8. Return new LAU contract - Side Effects: Deploys new LAU contract; triggers full VOID/SIU/ZHENG/ZHOU chain to generate Saat, Bao, and cryptographic components; modifies ownership - In Plain English: Create your Dysnomia player account! When called, the factory deploys a LAU contract that automatically registers you with VOID, generates your unique Soul ID and Aura, creates your cryptographic key pairs (SHIO), and sets up your Bao operation context. After creation, you fully own your account - the factory has no control over it.

Constructor

constructor(address VOIDAddress) {
    Void = VOID(VOIDAddress);
    Void.addOwner(address(this));
}

The constructor: 1. Stores reference to VOID 2. Adds factory as VOID owner (needed to create user sessions)

Ownership Pattern

1. Factory deploys LAU(name, symbol, Void)
2. LAU constructor calls Void.Enter() to create session
3. Factory adds msg.sender as LAU owner
4. Factory adds tx.origin as LAU owner
5. Factory renounces its own ownership

This ensures: - The calling contract becomes an owner (if applicable) - The human initiator becomes the primary owner - The factory retains no control over user tokens

Contract Interactions

Depends On

  • LAU - Contract being deployed
  • VOID - Session management

Depended On By

  • Any contract or UI that creates user accounts

Usage Example

// From a web3 frontend
LAUFactory factory = LAUFactory(factoryAddress);
LAU myToken = factory.New("Alice's Token", "ALICE");

// myToken is now owned by the caller
uint64 soul = myToken.Saat(1);
myToken.Username("Alice");

User Creation Flow

User calls factory.New("My Token", "MTK")
Factory deploys new LAU
LAU constructor calls VOID.Enter()
VOID creates session via SIU.Miu()
SIU creates tokens via ZHENG.Mau()
Complete installation through hierarchy
LAU receives Saat and Bao
Factory sets ownership to user
User receives LAU token address

Security Considerations

  • Factory must be VOID owner to create sessions
  • Factory renounces ownership after creation
  • Each LAU is independently owned by its creator
  • No central control over user tokens after creation

Contract Verification

Property Value
Keccak256 Hash 0xad03a2be6b28d8310331f5dff776ea9e686e6c1419468b5626aba6ccffcc55d7
Source URL https://raw.githubusercontent.com/busytoby/atropa_pulsechain/main/solidity/dysnomia/11c_laufactory.sol
Hash Generated 2026-02-08T00:29:57Z