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.1.1.tar.gz (45.5 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.1.1-cp312-cp312-win_amd64.whl (213.0 kB view details)

Uploaded CPython 3.12Windows x86-64

life_restart_core-0.1.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (331.7 kB view details)

Uploaded CPython 3.12manylinux: glibc 2.17+ x86-64

life_restart_core-0.1.1-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (328.0 kB view details)

Uploaded CPython 3.12manylinux: glibc 2.17+ ARM64

life_restart_core-0.1.1-cp312-cp312-macosx_11_0_arm64.whl (305.4 kB view details)

Uploaded CPython 3.12macOS 11.0+ ARM64

life_restart_core-0.1.1-cp312-cp312-macosx_10_12_x86_64.whl (315.2 kB view details)

Uploaded CPython 3.12macOS 10.12+ x86-64

File details

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

File metadata

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

File hashes

Hashes for life_restart_core-0.1.1.tar.gz
Algorithm Hash digest
SHA256 a7699c3320fedf71b6fea6d2449a4263df232ba1956f48511022a1791a7e02ec
MD5 c45deba428d449eaed70b6c1ac8aa96a
BLAKE2b-256 4379135c7d26dfa34b9a901fdc797f8e75a326513cc0f3c88ae09a7e5a1083bb

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for life_restart_core-0.1.1-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 60d0889e4f3d2eae95e415ff6dea4861d5b99544f32ba12941cbc0d2fc3e13f2
MD5 93b44f259b0461eb6a14e23ee759aa82
BLAKE2b-256 9f27d64c26328adb84c76f0599155487e80fb6e5b63950a267c9d4e531a38e3b

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for life_restart_core-0.1.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 29f983b16ecabee55c05f9698bd332556eff8ec0f91d2314743fd03fb34493bd
MD5 1a05a4bf59dd51ebd5a653ad2d95b614
BLAKE2b-256 5056d6ad02e067ec367a7d3e098c2ae5635e02809ad25d661bc6b433b951058d

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for life_restart_core-0.1.1-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 08ef01691bbc5f796034ab3562b48fa479208ebb2922ecee570c2652479f9173
MD5 7adddaa36960e542f5ad7065952dcec8
BLAKE2b-256 863276b2b0ad05e08d9b0bbd97692b5aa9baf099769b32f9528e4e7f59fb3c11

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for life_restart_core-0.1.1-cp312-cp312-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 a9e69bf9cb0ac727c490018a54896913765346cefc47d72f62aa9e3ef131e761
MD5 7d5242886ff197071fac614cdf044ea4
BLAKE2b-256 cec3a0cf3ebfa5e89ae954edb8c688103b31b4a91a8c07484ed0fe673f1c790e

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for life_restart_core-0.1.1-cp312-cp312-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 cfa05722e8b48d8dcb58466659aecab2105c6c5e58abb6b338fa34ba7a76db81
MD5 e5f8decef47b5924c74cc40b76b63407
BLAKE2b-256 23abb32a68d14d288bf2c2127a494480f30482b7caa9e3c9fce0fff46a1183a2

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