Skip to main content

High-performance life restart simulator core engine written in Rust

Project description

Life Restart Core

High-performance life restart simulator core engine written in Rust with Python bindings.

Features

  • 🚀 10-25x faster than pure Python implementation
  • 🐍 Python 3.14+ compatible via PyO3
  • 🔧 Drop-in replacement for existing Python code
  • 📦 Pre-built wheels for Linux, Windows, and macOS

Installation

pip install life-restart-core

Usage

from life_restart_core import simulate_full_life

result = simulate_full_life(
    talent_ids=[1001, 1002, 1003],
    properties={"CHR": 5, "INT": 5, "STR": 5, "MNY": 5},
    achieved_list=[],
    config={
        "talents": {...},
        "events": {...},
        "ages": {...},
        "achievements": {...},
        "judge": {...},
    }
)

# Result contains:
# - trajectory: List of year results
# - summary: Life summary with scores
# - new_achievements: Newly unlocked achievements
# - triggered_events: List of triggered event IDs
# - replacements: Talent replacement results

Development

Prerequisites

  • Rust 1.70+
  • Python 3.14+
  • maturin

Build

# Install maturin
pip install maturin

# Build and install in development mode
maturin develop

# Build release wheel
maturin build --release

Test

# Run Rust tests
cargo test

# Run Python tests
pytest tests/

Benchmark

cargo bench

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

life_restart_core-0.3.3.tar.gz (73.6 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

life_restart_core-0.3.3-cp312-cp312-win_amd64.whl (805.8 kB view details)

Uploaded CPython 3.12Windows x86-64

life_restart_core-0.3.3-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.0 MB view details)

Uploaded CPython 3.12manylinux: glibc 2.17+ x86-64

life_restart_core-0.3.3-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (1.0 MB view details)

Uploaded CPython 3.12manylinux: glibc 2.17+ ARM64

life_restart_core-0.3.3-cp312-cp312-macosx_11_0_arm64.whl (884.4 kB view details)

Uploaded CPython 3.12macOS 11.0+ ARM64

life_restart_core-0.3.3-cp312-cp312-macosx_10_12_x86_64.whl (950.7 kB view details)

Uploaded CPython 3.12macOS 10.12+ x86-64

File details

Details for the file life_restart_core-0.3.3.tar.gz.

File metadata

  • Download URL: life_restart_core-0.3.3.tar.gz
  • Upload date:
  • Size: 73.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: maturin/1.10.2

File hashes

Hashes for life_restart_core-0.3.3.tar.gz
Algorithm Hash digest
SHA256 159c18d8be1e869db21db048f7f7c2d0f05f7a1b2f825d6b86ca29f1c9c630cb
MD5 90a97d0c104bb0ceb2736d7a1fbbf1cb
BLAKE2b-256 926c4ac4b7b1d486cd348f5f0f476440114f3c6f402cfcd2c620939cdcefe207

See more details on using hashes here.

File details

Details for the file life_restart_core-0.3.3-cp312-cp312-win_amd64.whl.

File metadata

File hashes

Hashes for life_restart_core-0.3.3-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 55bb1bb4cfa98fe071a753641b76d5810dcc55bdfdafc7080c94dc671075b03e
MD5 0d52f7ad0607e5b3d7bcc64f924e112e
BLAKE2b-256 d1587799a9cb81b303e44f666224b4c958d36bffbabed39f53eb9c48961d6b83

See more details on using hashes here.

File details

Details for the file life_restart_core-0.3.3-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for life_restart_core-0.3.3-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 6b9491479e3be4ae58ba18b0c23c90869debf5f4084c19fd646def517cbb1354
MD5 622c6ac3892b3d88b91cb5ab59c900fc
BLAKE2b-256 1ccb6a5583cf5e902e9c1fe586411f329bba7723416ce7a6cfd8dd27d8d798a0

See more details on using hashes here.

File details

Details for the file life_restart_core-0.3.3-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for life_restart_core-0.3.3-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 1717b084233dab14b4dd53f0c5d0a95700bb9ade7401995c6862dbaa96824b1d
MD5 13bf993b66d5f40af96c02d409c2fa34
BLAKE2b-256 83c685c6549e85441bac6a86bf38163300d649874aee7215543fb902ce1c4eb8

See more details on using hashes here.

File details

Details for the file life_restart_core-0.3.3-cp312-cp312-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for life_restart_core-0.3.3-cp312-cp312-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 a42e8a8ea6aabc7f49278825ede13bcfb4d1da65088ce8d2e324da51100ee72a
MD5 26c9da902ac47b9654fd8390f38dbc7d
BLAKE2b-256 2bccfcf249fdb5caa151a0843a2883f0308df093b6f9a155564eb450e9b3897f

See more details on using hashes here.

File details

Details for the file life_restart_core-0.3.3-cp312-cp312-macosx_10_12_x86_64.whl.

File metadata

File hashes

Hashes for life_restart_core-0.3.3-cp312-cp312-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 d6935b0de9b41d0c5feaa9e84ee51e0b4dd8c4ebac5634a2d7f89a3573a39e6f
MD5 1b416a82b09935f4561f7a51cd6f1572
BLAKE2b-256 606dc988a5cf06dce7b69d5bc3a6d0b00059f289faf8106cb989b4362461dd40

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page