Skip to content

feat(glaziery): ancient runic glass prism spectrograph, triangular dispersion bench, and chromatic engine - #287

Open
angelTomo9 wants to merge 2 commits into
Bitcoindefi:mainfrom
angelTomo9:feat-prism-spectrograph-1788151262354
Open

feat(glaziery): ancient runic glass prism spectrograph, triangular dispersion bench, and chromatic engine#287
angelTomo9 wants to merge 2 commits into
Bitcoindefi:mainfrom
angelTomo9:feat-prism-spectrograph-1788151262354

Conversation

@angelTomo9

Copy link
Copy Markdown

Summary

Implements an ancient runic glass prism spectrograph, triangular dispersion bench, and chromatic light dispersion system, spectrograph benches (Pine Prism Spectrograph Bench, Runic Brass Dispersion Goniometer, Celestial Void Prismatic Aurora Sanctum), raw triangular glass prisms (Flint Glass Triangular Prism, Fluorite Chromatic Dispersion Crystal, Celestial Void Rainbow Aurora Prism), chromatic spectrograph recipes (Solar Flare Dispersion Spectrograph, Lunar Rainbow Chromatic Prism, Celestial Void Seraphic Aurora Spectrograph), chromatic dispersion ratings (scaled across catalog baselines ~14% to 100%), calibrated magic pierce and spell critical scaling, upfront material deduction on all attempts, consistent remainingProvidedPrisms shapes across all branches, extensionless test import, and spectrograph bench maintenance for OpenAO MMORPG.

Features

  • Spectrograph bench catalog with power ratings, durability, and chromatic bonuses
  • Chromatic spectrograph recipes with calibrated magic pierce and spell critical scaling
  • Independent chromatic dispersion quality roll scaling
  • Upfront material deduction on all craft attempts to prevent zero-cost retries
  • Consistent remainingProvidedPrisms arrays returned on all early rejection branches
  • Cached static catalog maxima and table maintenance with durability threshold gating
  • Full unit test coverage under Vitest including mid-range dispersion tests

Comment thread api/src/lib/ancientRunicGlassPrismSpectrograph.ts Outdated
@gitar-bot

gitar-bot Bot commented Aug 31, 2026

Copy link
Copy Markdown
Code Review ✅ Approved 1 resolved / 1 findings

Implements ancient runic glass prism spectrograph, triangular dispersion bench, and chromatic light dispersion system with spectrograph bench catalog, chromatic recipes with calibrated magic pierce and spell critical scaling, upfront material deduction on craft attempts, and consistent array returns across all branches. Addresses the gameplay RNG vulnerability by switching to cryptographically secure random defaults. No issues found.

✅ 1 resolved
Security: Gameplay RNG defaults to non-secure Math.random()

📄 api/src/lib/ancientRunicGlassPrismSpectrograph.ts:118-119 📄 api/src/lib/ancientRunicGlassPrismSpectrograph.ts:177 📄 api/src/lib/ancientRunicGlassPrismSpectrograph.ts:192
The craft and dispersion rolls default to Math.random(), which is not cryptographically secure and is predictable/seedable in some engines. For server-side MMORPG crafting outcomes this can be exploited to farm high-quality results. The file already imports node:crypto; consider deriving the default rolls from crypto.randomInt/randomBytes (or requiring the caller to always supply an authoritative roll) rather than Math.random().

Options

Auto-apply is off → Gitar will not commit updates to this branch.
Display: compact → Showing less information.

Comment with these commands to change the behavior for this request:

Auto-apply Compact
gitar auto-apply:on         
gitar display:verbose         

Important

Your trial ends in 1 day — upgrade now to keep code review, CI analysis, auto-apply, custom automations, and more.

Was this helpful? React with 👍 / 👎 | Gitar

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant