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.1.tar.gz (73.2 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.1-cp312-cp312-win_amd64.whl (805.7 kB view details)

Uploaded CPython 3.12Windows x86-64

life_restart_core-0.3.1-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.1-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.1-cp312-cp312-macosx_11_0_arm64.whl (887.5 kB view details)

Uploaded CPython 3.12macOS 11.0+ ARM64

life_restart_core-0.3.1-cp312-cp312-macosx_10_12_x86_64.whl (955.2 kB view details)

Uploaded CPython 3.12macOS 10.12+ x86-64

File details

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

File metadata

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

File hashes

Hashes for life_restart_core-0.3.1.tar.gz
Algorithm Hash digest
SHA256 f6acfa1b939aace63caef0c1a9740db0f34053b26a5fdebaead0cb5a676fcc08
MD5 7e27a3b1c50247e8a04c5599669754b0
BLAKE2b-256 14d44789ea9dc58fe939c49791f82c5ed7bfd95810e46d015a54edcce8f7d610

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for life_restart_core-0.3.1-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 0a0183ff0dbe00e4e765cc2baa1dadb8edc93258cc8f137274ff7d1c9d4f3a58
MD5 3f987d5eda225af153fe9d1c79c43bdf
BLAKE2b-256 b7f52d88922370e82ddb45a10c6d72107e770bd887b6ba518dca5bd430963c95

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for life_restart_core-0.3.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 0ee890399b94846c5858f275b7efd3d48ee692dc69104cd22861a7f57f531800
MD5 09e505aa59ed3715384ae2dae9773ee3
BLAKE2b-256 0317b4388f484d0c55bdf0ab5593da85e1fcb627d916b7abc411273b77b2221d

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for life_restart_core-0.3.1-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 a084b017ab82eb7b8718944e5a9b1c93b417bad24f13b075a2a8b5e3047a487f
MD5 0219dec159416248f5d71afc2a82dd4f
BLAKE2b-256 c7bf8a09dd2534d4934f62a8beb9a47a2846d5e11d367735b018a63b5d18f360

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for life_restart_core-0.3.1-cp312-cp312-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 516830b8b3e17f526270273e410942f5e1168e5006062933c8bfc72bc3778e7d
MD5 d9179610fe2fc2f0d44a9380ef8c6549
BLAKE2b-256 13ebed8c497d091f5eaf9ab7f0b500a0117ba3ca8382a54895aba149088561e9

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for life_restart_core-0.3.1-cp312-cp312-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 6fb8fc544f0f4df538acd470f8ad5a7b7ff738ac8197ac6a3a0a4e67dd1c16b3
MD5 0486bc82e2ea82d112eb00aa3c977b77
BLAKE2b-256 aec834c9c3a3bf0eb14a4d57cbcbf7120f787bae6405a43a64079981fa6b44a1

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