@senators/bifrost-cli 0.0.0-stage → 7.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +180 -2
- package/out/accountEditor-CQB91PVf.js +2 -0
- package/out/accountEditor-CQB91PVf.js.map +1 -0
- package/out/achievements-Df5qqpYQ.js +2 -0
- package/out/achievements-Df5qqpYQ.js.map +1 -0
- package/out/active-CnUKpiEo.js +2 -0
- package/out/active-CnUKpiEo.js.map +1 -0
- package/out/alliance-BsPnhi7w.js +2 -0
- package/out/alliance-BsPnhi7w.js.map +1 -0
- package/out/allianceAdmin-Bkyl6ev4.js +2 -0
- package/out/allianceAdmin-Bkyl6ev4.js.map +1 -0
- package/out/arsenal-BMCmAHzv.js +2 -0
- package/out/arsenal-BMCmAHzv.js.map +1 -0
- package/out/ban-BXNvHPMq.js +2 -0
- package/out/ban-BXNvHPMq.js.map +1 -0
- package/out/banList-3DbCToEy.js +2 -0
- package/out/banList-3DbCToEy.js.map +1 -0
- package/out/banList-dT5GF5eO.js +2 -0
- package/out/banList-dT5GF5eO.js.map +1 -0
- package/out/battleHall-C4BALP6S.js +2 -0
- package/out/battleHall-C4BALP6S.js.map +1 -0
- package/out/battleHall-P7Co1jS5.js +2 -0
- package/out/battleHall-P7Co1jS5.js.map +1 -0
- package/out/battleReport-BG0-S-bF.js +2 -0
- package/out/battleReport-BG0-S-bF.js.map +1 -0
- package/out/battleReport-C3PQTXxc.js +2 -0
- package/out/battleReport-C3PQTXxc.js.map +1 -0
- package/out/battleSimulator-BOySErLn.js +2 -0
- package/out/battleSimulator-BOySErLn.js.map +1 -0
- package/out/board-CsNgDx4j.js +2 -0
- package/out/board-CsNgDx4j.js.map +1 -0
- package/out/board-DSCl8eU8.js +2 -0
- package/out/board-DSCl8eU8.js.map +1 -0
- package/out/bonusSummary-Dmm646zj.js +2 -0
- package/out/bonusSummary-Dmm646zj.js.map +1 -0
- package/out/buddyList-B50t-9_g.js +2 -0
- package/out/buddyList-B50t-9_g.js.map +1 -0
- package/out/buildings-CXrMgFyb.js +2 -0
- package/out/buildings-CXrMgFyb.js.map +1 -0
- package/out/catalog-DmSXp_YG.js +2 -0
- package/out/catalog-DmSXp_YG.js.map +1 -0
- package/out/chat-BvtMl-I7.js +2 -0
- package/out/chat-BvtMl-I7.js.map +1 -0
- package/out/clearCache-79cjREI0.js +2 -0
- package/out/clearCache-79cjREI0.js.map +1 -0
- package/out/cli.js +3 -0
- package/out/cli.js.map +1 -0
- package/out/containers-BhguCCkz.js +2 -0
- package/out/containers-BhguCCkz.js.map +1 -0
- package/out/control-IJRy1LDx.js +2 -0
- package/out/control-IJRy1LDx.js.map +1 -0
- package/out/create-D-IygCER.js +2 -0
- package/out/create-D-IygCER.js.map +1 -0
- package/out/createMoon-BMWjdwO0.js +2 -0
- package/out/createMoon-BMWjdwO0.js.map +1 -0
- package/out/cronjob-CCJKDSuv.js +2 -0
- package/out/cronjob-CCJKDSuv.js.map +1 -0
- package/out/dailyBonus-2UwWD4D0.js +2 -0
- package/out/dailyBonus-2UwWD4D0.js.map +1 -0
- package/out/delivery-d8NKP-f1.js +2 -0
- package/out/delivery-d8NKP-f1.js.map +1 -0
- package/out/disclaimer-BmejHZqk.js +2 -0
- package/out/disclaimer-BmejHZqk.js.map +1 -0
- package/out/dump--mJa5m3e.js +2 -0
- package/out/dump--mJa5m3e.js.map +1 -0
- package/out/endpoints-CbZGTbF-.js +2 -0
- package/out/endpoints-CbZGTbF-.js.map +1 -0
- package/out/externalAuth-Dwl3VAHa.js +2 -0
- package/out/externalAuth-Dwl3VAHa.js.map +1 -0
- package/out/findDebris-DOMvMC1l.js +2 -0
- package/out/findDebris-DOMvMC1l.js.map +1 -0
- package/out/fleet-DyITa_Xu.js +2 -0
- package/out/fleet-DyITa_Xu.js.map +1 -0
- package/out/fleetAjax-BGxyUtdi.js +2 -0
- package/out/fleetAjax-BGxyUtdi.js.map +1 -0
- package/out/fleetDealer-n6LM_8IT.js +2 -0
- package/out/fleetDealer-n6LM_8IT.js.map +1 -0
- package/out/fleetMissile-CucQvNmZ.js +2 -0
- package/out/fleetMissile-CucQvNmZ.js.map +1 -0
- package/out/fleetStep1-wp-NgTsC.js +2 -0
- package/out/fleetStep1-wp-NgTsC.js.map +1 -0
- package/out/fleetStep2-C-GzHXyn.js +2 -0
- package/out/fleetStep2-C-GzHXyn.js.map +1 -0
- package/out/fleetStep3-D_fqImWm.js +2 -0
- package/out/fleetStep3-D_fqImWm.js.map +1 -0
- package/out/fleetTable-BpWLh0R1.js +2 -0
- package/out/fleetTable-BpWLh0R1.js.map +1 -0
- package/out/flyingFleet-ClIrGPJz.js +2 -0
- package/out/flyingFleet-ClIrGPJz.js.map +1 -0
- package/out/galaxy-B12wKQUU.js +2 -0
- package/out/galaxy-B12wKQUU.js.map +1 -0
- package/out/get-Cn2hFvGS.js +2 -0
- package/out/get-Cn2hFvGS.js.map +1 -0
- package/out/giveaway-CDWEArOF.js +2 -0
- package/out/giveaway-CDWEArOF.js.map +1 -0
- package/out/growth-C_-C8rLD.js +2 -0
- package/out/growth-C_-C8rLD.js.map +1 -0
- package/out/index.d.ts +29 -0
- package/out/index.d.ts.map +1 -0
- package/out/index.js +1 -0
- package/out/information-CqfqYCH1.js +2 -0
- package/out/information-CqfqYCH1.js.map +1 -0
- package/out/information-DK93hgyE.js +2 -0
- package/out/information-DK93hgyE.js.map +1 -0
- package/out/log-BBE1Jt9i.js +2 -0
- package/out/log-BBE1Jt9i.js.map +1 -0
- package/out/login--4vqysQx.js +2 -0
- package/out/login--4vqysQx.js.map +1 -0
- package/out/login-C_DqRApn.js +2 -0
- package/out/login-C_DqRApn.js.map +1 -0
- package/out/logout-BYnLiMja.js +2 -0
- package/out/logout-BYnLiMja.js.map +1 -0
- package/out/logout-BsCSXzv8.js +2 -0
- package/out/logout-BsCSXzv8.js.map +1 -0
- package/out/lostPassword-Pc_1CUBD.js +2 -0
- package/out/lostPassword-Pc_1CUBD.js.map +1 -0
- package/out/market-DN8cY1tr.js +2 -0
- package/out/market-DN8cY1tr.js.map +1 -0
- package/out/messageList-k_zW_D0G.js +2 -0
- package/out/messageList-k_zW_D0G.js.map +1 -0
- package/out/messages-D461yIe6.js +2 -0
- package/out/messages-D461yIe6.js.map +1 -0
- package/out/missions-5zZtlLIm.js +2 -0
- package/out/missions-5zZtlLIm.js.map +1 -0
- package/out/module-BEPeTBhK.js +2 -0
- package/out/module-BEPeTBhK.js.map +1 -0
- package/out/multiIp-CP3lub1T.js +2 -0
- package/out/multiIp-CP3lub1T.js.map +1 -0
- package/out/new-star-BaVTTcIn.js +2 -0
- package/out/new-star-BaVTTcIn.js.map +1 -0
- package/out/news-BdDDcd-M.js +2 -0
- package/out/news-BdDDcd-M.js.map +1 -0
- package/out/news-Dd1C9JDl.js +2 -0
- package/out/news-Dd1C9JDl.js.map +1 -0
- package/out/notes-DLngBta3.js +2 -0
- package/out/notes-DLngBta3.js.map +1 -0
- package/out/overview-CzcSTNla.js +2 -0
- package/out/overview-CzcSTNla.js.map +1 -0
- package/out/overview-wQWIR_CB.js +2 -0
- package/out/overview-wQWIR_CB.js.map +1 -0
- package/out/password-ZA_1lStC.js +2 -0
- package/out/password-ZA_1lStC.js.map +1 -0
- package/out/phalanx-DaMaoJCT.js +2 -0
- package/out/phalanx-DaMaoJCT.js.map +1 -0
- package/out/planet-CecZ2cAZ.js +2 -0
- package/out/planet-CecZ2cAZ.js.map +1 -0
- package/out/playerCard-BG711xQi.js +2 -0
- package/out/playerCard-BG711xQi.js.map +1 -0
- package/out/post-C_ywAss7.js +2 -0
- package/out/post-C_ywAss7.js.map +1 -0
- package/out/production-D8SZfez8.js +2 -0
- package/out/production-D8SZfez8.js.map +1 -0
- package/out/public-TVVf75qu.js +2 -0
- package/out/public-TVVf75qu.js.map +1 -0
- package/out/questions-NwzZ5_fL.js +2 -0
- package/out/questions-NwzZ5_fL.js.map +1 -0
- package/out/quickEditor-DEJQFH0f.js +2 -0
- package/out/quickEditor-DEJQFH0f.js.map +1 -0
- package/out/records-CDVglYGy.js +2 -0
- package/out/records-CDVglYGy.js.map +1 -0
- package/out/records-Djjz9kxk.js +2 -0
- package/out/records-Djjz9kxk.js.map +1 -0
- package/out/reduceFleet-y8p89weR.js +2 -0
- package/out/reduceFleet-y8p89weR.js.map +1 -0
- package/out/reduceResources-CnGJ9fuf.js +2 -0
- package/out/reduceResources-CnGJ9fuf.js.map +1 -0
- package/out/refreshStatistics-CjGWyNc_.js +2 -0
- package/out/refreshStatistics-CjGWyNc_.js.map +1 -0
- package/out/register-4x5hZcWe.js +2 -0
- package/out/register-4x5hZcWe.js.map +1 -0
- package/out/research-dTK3-tOW.js +2 -0
- package/out/research-dTK3-tOW.js.map +1 -0
- package/out/reset-CHiMI9rj.js +2 -0
- package/out/reset-CHiMI9rj.js.map +1 -0
- package/out/resources-CjnevA41.js +2 -0
- package/out/resources-CjnevA41.js.map +1 -0
- package/out/rights-WPf-j_YF.js +2 -0
- package/out/rights-WPf-j_YF.js.map +1 -0
- package/out/rules-E29jtQRj.js +2 -0
- package/out/rules-E29jtQRj.js.map +1 -0
- package/out/runner-C2bQQS2G.js +43 -0
- package/out/runner-C2bQQS2G.js.map +1 -0
- package/out/scan-RvWZeyyM.js +2 -0
- package/out/scan-RvWZeyyM.js.map +1 -0
- package/out/screens-CZ4g-KNp.js +2 -0
- package/out/screens-CZ4g-KNp.js.map +1 -0
- package/out/search-BYvqiUBF.js +2 -0
- package/out/search-BYvqiUBF.js.map +1 -0
- package/out/search-auPbK2Xc.js +2 -0
- package/out/search-auPbK2Xc.js.map +1 -0
- package/out/sendMessages-B2Uj3PW4.js +2 -0
- package/out/sendMessages-B2Uj3PW4.js.map +1 -0
- package/out/settings-DFFa6Ush.js +2 -0
- package/out/settings-DFFa6Ush.js.map +1 -0
- package/out/settings-Ddez5x9U.js +2 -0
- package/out/settings-Ddez5x9U.js.map +1 -0
- package/out/shared-DoaW4mlX.js +2 -0
- package/out/shared-DoaW4mlX.js.map +1 -0
- package/out/shipyard-DXr745hR.js +2 -0
- package/out/shipyard-DXr745hR.js.map +1 -0
- package/out/shops-CEE02c0g.js +2 -0
- package/out/shops-CEE02c0g.js.map +1 -0
- package/out/snapshot-CrJ8l50N.js +2 -0
- package/out/snapshot-CrJ8l50N.js.map +1 -0
- package/out/social-1Gdni-jZ.js +2 -0
- package/out/social-1Gdni-jZ.js.map +1 -0
- package/out/spec-CrkWB0BN.js +2 -0
- package/out/spec-CrkWB0BN.js.map +1 -0
- package/out/statistics-zg3aVAvW.js +2 -0
- package/out/statistics-zg3aVAvW.js.map +1 -0
- package/out/store-dXG7NoB4.js +2 -0
- package/out/store-dXG7NoB4.js.map +1 -0
- package/out/support-DisUQr57.js +2 -0
- package/out/support-DisUQr57.js.map +1 -0
- package/out/techtree-Ba3FEH5_.js +2 -0
- package/out/techtree-Ba3FEH5_.js.map +1 -0
- package/out/ticket-O_8jTKW8.js +2 -0
- package/out/ticket-O_8jTKW8.js.map +1 -0
- package/out/trader-zFDGaHZ9.js +2 -0
- package/out/trader-zFDGaHZ9.js.map +1 -0
- package/out/universe-DO32RnLQ.js +2 -0
- package/out/universe-DO32RnLQ.js.map +1 -0
- package/out/universeSettings-S7enRJR4.js +2 -0
- package/out/universeSettings-S7enRJR4.js.map +1 -0
- package/out/values-gwcnIHXs.js +2 -0
- package/out/values-gwcnIHXs.js.map +1 -0
- package/out/verify-sYnZ9juV.js +2 -0
- package/out/verify-sYnZ9juV.js.map +1 -0
- package/out/version-Cgs-grc5.js +2 -0
- package/out/version-Cgs-grc5.js.map +1 -0
- package/package.json +65 -4
- package/src/admin.ts +317 -0
- package/src/arguments.ts +323 -0
- package/src/catalog.ts +117 -0
- package/src/cli.ts +29 -0
- package/src/commands/admin/accountEditor.ts +33 -0
- package/src/commands/admin/active.ts +25 -0
- package/src/commands/admin/ban.ts +59 -0
- package/src/commands/admin/clearCache.ts +12 -0
- package/src/commands/admin/create.ts +59 -0
- package/src/commands/admin/cronjob.ts +94 -0
- package/src/commands/admin/dump.ts +25 -0
- package/src/commands/admin/flyingFleet.ts +25 -0
- package/src/commands/admin/giveaway.ts +37 -0
- package/src/commands/admin/information.ts +12 -0
- package/src/commands/admin/log.ts +37 -0
- package/src/commands/admin/login.ts +15 -0
- package/src/commands/admin/logout.ts +12 -0
- package/src/commands/admin/messageList.ts +19 -0
- package/src/commands/admin/module.ts +25 -0
- package/src/commands/admin/multiIp.ts +25 -0
- package/src/commands/admin/news.ts +40 -0
- package/src/commands/admin/overview.ts +12 -0
- package/src/commands/admin/password.ts +18 -0
- package/src/commands/admin/quickEditor.ts +30 -0
- package/src/commands/admin/refreshStatistics.ts +12 -0
- package/src/commands/admin/reset.ts +26 -0
- package/src/commands/admin/rights.ts +68 -0
- package/src/commands/admin/search.ts +31 -0
- package/src/commands/admin/sendMessages.ts +26 -0
- package/src/commands/admin/support.ts +48 -0
- package/src/commands/admin/universe.ts +49 -0
- package/src/commands/admin/universeSettings.ts +32 -0
- package/src/commands/game/achievements.ts +18 -0
- package/src/commands/game/alliance.ts +248 -0
- package/src/commands/game/allianceAdmin.ts +236 -0
- package/src/commands/game/arsenal.ts +12 -0
- package/src/commands/game/banList.ts +20 -0
- package/src/commands/game/battleHall.ts +21 -0
- package/src/commands/game/battleReport.ts +20 -0
- package/src/commands/game/battleSimulator.ts +41 -0
- package/src/commands/game/board.ts +12 -0
- package/src/commands/game/bonusSummary.ts +12 -0
- package/src/commands/game/buddyList.ts +76 -0
- package/src/commands/game/buildings.ts +81 -0
- package/src/commands/game/chat.ts +12 -0
- package/src/commands/game/containers.ts +33 -0
- package/src/commands/game/control.ts +16 -0
- package/src/commands/game/createMoon.ts +28 -0
- package/src/commands/game/dailyBonus.ts +18 -0
- package/src/commands/game/delivery.ts +34 -0
- package/src/commands/game/endpoints.ts +61 -0
- package/src/commands/game/findDebris.ts +16 -0
- package/src/commands/game/fleetAjax.ts +24 -0
- package/src/commands/game/fleetDealer.ts +36 -0
- package/src/commands/game/fleetMissile.ts +25 -0
- package/src/commands/game/fleetStep1.ts +74 -0
- package/src/commands/game/fleetStep2.ts +27 -0
- package/src/commands/game/fleetStep3.ts +28 -0
- package/src/commands/game/fleetTable.ts +96 -0
- package/src/commands/game/galaxy.ts +26 -0
- package/src/commands/game/growth.ts +313 -0
- package/src/commands/game/information.ts +56 -0
- package/src/commands/game/logout.ts +12 -0
- package/src/commands/game/market.ts +67 -0
- package/src/commands/game/messages.ts +129 -0
- package/src/commands/game/notes.ts +65 -0
- package/src/commands/game/overview.ts +49 -0
- package/src/commands/game/phalanx.ts +23 -0
- package/src/commands/game/planet.ts +78 -0
- package/src/commands/game/playerCard.ts +20 -0
- package/src/commands/game/questions.ts +23 -0
- package/src/commands/game/records.ts +16 -0
- package/src/commands/game/reduceFleet.ts +41 -0
- package/src/commands/game/reduceResources.ts +35 -0
- package/src/commands/game/research.ts +80 -0
- package/src/commands/game/resources.ts +49 -0
- package/src/commands/game/scan.ts +12 -0
- package/src/commands/game/search.ts +44 -0
- package/src/commands/game/settings.ts +121 -0
- package/src/commands/game/shipyard.ts +61 -0
- package/src/commands/game/shops.ts +89 -0
- package/src/commands/game/statistics.ts +22 -0
- package/src/commands/game/store.ts +12 -0
- package/src/commands/game/techtree.ts +16 -0
- package/src/commands/game/ticket.ts +44 -0
- package/src/commands/game/trader.ts +51 -0
- package/src/commands/game/workflows/fleet.ts +12 -0
- package/src/commands/game/workflows/snapshot.ts +84 -0
- package/src/commands/game/workflows/social.ts +37 -0
- package/src/commands/http/get.ts +13 -0
- package/src/commands/http/post.ts +44 -0
- package/src/commands/public/banList.ts +21 -0
- package/src/commands/public/battleHall.ts +20 -0
- package/src/commands/public/battleReport.ts +20 -0
- package/src/commands/public/board.ts +20 -0
- package/src/commands/public/disclaimer.ts +20 -0
- package/src/commands/public/externalAuth.ts +17 -0
- package/src/commands/public/index.ts +22 -0
- package/src/commands/public/login.ts +20 -0
- package/src/commands/public/lostPassword.ts +57 -0
- package/src/commands/public/news.ts +20 -0
- package/src/commands/public/register.ts +46 -0
- package/src/commands/public/rules.ts +20 -0
- package/src/commands/public/screens.ts +20 -0
- package/src/commands/public/verify.ts +38 -0
- package/src/commands/rules/new-star.ts +221 -0
- package/src/commands/rules/production.ts +51 -0
- package/src/completion/BifrostCompletion.psm1 +47 -0
- package/src/completion.ts +445 -0
- package/src/connection.ts +106 -0
- package/src/destination.ts +64 -0
- package/src/game.ts +978 -0
- package/src/help.ts +203 -0
- package/src/i18n.ts +45 -0
- package/src/index.ts +2 -0
- package/src/input/admin/accountEditor.ts +156 -0
- package/src/input/admin/ban.ts +23 -0
- package/src/input/admin/create.ts +36 -0
- package/src/input/admin/cronjob.ts +22 -0
- package/src/input/admin/fields.ts +432 -0
- package/src/input/admin/login.ts +9 -0
- package/src/input/admin/messageList.ts +21 -0
- package/src/input/admin/news.ts +29 -0
- package/src/input/admin/quickEditor.ts +115 -0
- package/src/input/admin/records.ts +68 -0
- package/src/input/admin/reset.ts +29 -0
- package/src/input/admin/search.ts +23 -0
- package/src/input/admin/sendMessages.ts +21 -0
- package/src/input/admin/universeSettings.ts +46 -0
- package/src/input/files.ts +65 -0
- package/src/input/game/allianceAdmin.ts +55 -0
- package/src/input/game/battleSimulator.ts +25 -0
- package/src/input/game/fleetStep1.ts +14 -0
- package/src/input/game/settings.ts +46 -0
- package/src/input/game/ticket.ts +16 -0
- package/src/input/parse.ts +173 -0
- package/src/input/paths.ts +392 -0
- package/src/input/protocol/context.ts +10 -0
- package/src/input/protocol/missions.ts +6 -0
- package/src/input/protocol/routes.ts +15 -0
- package/src/input/protocol/settings.ts +126 -0
- package/src/input/protocol/values.ts +13 -0
- package/src/input/public/externalAuth.ts +26 -0
- package/src/input/public/register.ts +9 -0
- package/src/input/rules/new-star.ts +21 -0
- package/src/input/rules/production.ts +14 -0
- package/src/input/shared.ts +51 -0
- package/src/input/spec.ts +155 -0
- package/src/input/values.ts +114 -0
- package/src/input/workflows/fleet.ts +22 -0
- package/src/input/workflows/snapshot.ts +74 -0
- package/src/locales/en-US/commands.ts +377 -0
- package/src/locales/en-US/diagnostics.ts +89 -0
- package/src/locales/en-US.ts +61 -0
- package/src/locales/zh-CN/commands.ts +307 -0
- package/src/locales/zh-CN/diagnostics.ts +81 -0
- package/src/locales/zh-CN.ts +57 -0
- package/src/options.ts +48 -0
- package/src/output.ts +201 -0
- package/src/pointer.ts +46 -0
- package/src/presentation.ts +96 -0
- package/src/public.ts +99 -0
- package/src/registry.ts +67 -0
- package/src/requests.ts +13 -0
- package/src/result.ts +27 -0
- package/src/rules.ts +77 -0
- package/src/runner.ts +214 -0
- package/src/selection.ts +44 -0
- package/src/terminal.ts +27 -0
- package/src/types.ts +110 -0
- package/src/version.ts +11 -0
|
@@ -0,0 +1,313 @@
|
|
|
1
|
+
import {
|
|
2
|
+
ancientContainerShop,
|
|
3
|
+
ancientContainerUpgrade,
|
|
4
|
+
artifact,
|
|
5
|
+
artifactUpgrade,
|
|
6
|
+
auction,
|
|
7
|
+
auctionUpgrade,
|
|
8
|
+
band,
|
|
9
|
+
bandUpgrade,
|
|
10
|
+
blueprints,
|
|
11
|
+
blueprintsUpgrade,
|
|
12
|
+
details,
|
|
13
|
+
detailsUpgrade,
|
|
14
|
+
development,
|
|
15
|
+
developmentUpgrade,
|
|
16
|
+
ethics,
|
|
17
|
+
ethicsUpgrade,
|
|
18
|
+
fair,
|
|
19
|
+
fairUpgrade,
|
|
20
|
+
government,
|
|
21
|
+
governmentUpgrade,
|
|
22
|
+
ideologies,
|
|
23
|
+
ideologiesUpgrade,
|
|
24
|
+
minerals,
|
|
25
|
+
mineralsUpgrade,
|
|
26
|
+
officer,
|
|
27
|
+
officerUpgrade,
|
|
28
|
+
party,
|
|
29
|
+
partyUpgrade,
|
|
30
|
+
premium,
|
|
31
|
+
premiumUpgrade,
|
|
32
|
+
race,
|
|
33
|
+
raceUpgrade,
|
|
34
|
+
} from '@senators/bifrost'
|
|
35
|
+
|
|
36
|
+
import { observedCommand } from '../../catalog.ts'
|
|
37
|
+
import { planetReferenceInput } from '../../input/shared.ts'
|
|
38
|
+
import { numberInput, required } from '../../input/spec.ts'
|
|
39
|
+
import type { InputSpec } from '../../input/spec.ts'
|
|
40
|
+
import type { NetworkCommand } from '../../types.ts'
|
|
41
|
+
|
|
42
|
+
const quantityUpgradeSchema = {
|
|
43
|
+
kind: 'object',
|
|
44
|
+
fields: {
|
|
45
|
+
planetId: required(numberInput),
|
|
46
|
+
elementId: required(numberInput),
|
|
47
|
+
amount: required(numberInput),
|
|
48
|
+
},
|
|
49
|
+
} satisfies InputSpec<Parameters<typeof ancientContainerUpgrade>[1]>
|
|
50
|
+
|
|
51
|
+
const choiceUpgradeSchema = {
|
|
52
|
+
kind: 'object',
|
|
53
|
+
fields: {
|
|
54
|
+
planetId: required(numberInput),
|
|
55
|
+
elementId: required(numberInput),
|
|
56
|
+
},
|
|
57
|
+
} satisfies InputSpec<Parameters<typeof ethicsUpgrade>[1]>
|
|
58
|
+
|
|
59
|
+
export const ancientContainerShopCommand: NetworkCommand = observedCommand(
|
|
60
|
+
'game',
|
|
61
|
+
'ancientContainerShop',
|
|
62
|
+
planetReferenceInput,
|
|
63
|
+
ancientContainerShop,
|
|
64
|
+
'planetId',
|
|
65
|
+
)
|
|
66
|
+
|
|
67
|
+
export const ancientContainerUpgradeCommand: NetworkCommand = observedCommand(
|
|
68
|
+
'game',
|
|
69
|
+
'ancientContainerUpgrade',
|
|
70
|
+
quantityUpgradeSchema,
|
|
71
|
+
ancientContainerUpgrade,
|
|
72
|
+
'planetId',
|
|
73
|
+
)
|
|
74
|
+
|
|
75
|
+
export const artifactCommand: NetworkCommand = observedCommand(
|
|
76
|
+
'game',
|
|
77
|
+
'artifact',
|
|
78
|
+
planetReferenceInput,
|
|
79
|
+
artifact,
|
|
80
|
+
'planetId',
|
|
81
|
+
)
|
|
82
|
+
|
|
83
|
+
export const artifactUpgradeCommand: NetworkCommand = observedCommand(
|
|
84
|
+
'game',
|
|
85
|
+
'artifactUpgrade',
|
|
86
|
+
quantityUpgradeSchema,
|
|
87
|
+
artifactUpgrade,
|
|
88
|
+
'planetId',
|
|
89
|
+
)
|
|
90
|
+
|
|
91
|
+
export const auctionCommand: NetworkCommand = observedCommand(
|
|
92
|
+
'game',
|
|
93
|
+
'auction',
|
|
94
|
+
planetReferenceInput,
|
|
95
|
+
auction,
|
|
96
|
+
'planetId',
|
|
97
|
+
)
|
|
98
|
+
|
|
99
|
+
export const auctionUpgradeCommand: NetworkCommand = observedCommand(
|
|
100
|
+
'game',
|
|
101
|
+
'auctionUpgrade',
|
|
102
|
+
quantityUpgradeSchema,
|
|
103
|
+
auctionUpgrade,
|
|
104
|
+
'planetId',
|
|
105
|
+
)
|
|
106
|
+
|
|
107
|
+
export const bandCommand: NetworkCommand = observedCommand(
|
|
108
|
+
'game',
|
|
109
|
+
'band',
|
|
110
|
+
planetReferenceInput,
|
|
111
|
+
band,
|
|
112
|
+
'planetId',
|
|
113
|
+
)
|
|
114
|
+
|
|
115
|
+
export const bandUpgradeCommand: NetworkCommand = observedCommand(
|
|
116
|
+
'game',
|
|
117
|
+
'bandUpgrade',
|
|
118
|
+
quantityUpgradeSchema,
|
|
119
|
+
bandUpgrade,
|
|
120
|
+
'planetId',
|
|
121
|
+
)
|
|
122
|
+
|
|
123
|
+
export const blueprintsCommand: NetworkCommand = observedCommand(
|
|
124
|
+
'game',
|
|
125
|
+
'blueprints',
|
|
126
|
+
planetReferenceInput,
|
|
127
|
+
blueprints,
|
|
128
|
+
'planetId',
|
|
129
|
+
)
|
|
130
|
+
|
|
131
|
+
export const blueprintsUpgradeCommand: NetworkCommand = observedCommand(
|
|
132
|
+
'game',
|
|
133
|
+
'blueprintsUpgrade',
|
|
134
|
+
quantityUpgradeSchema,
|
|
135
|
+
blueprintsUpgrade,
|
|
136
|
+
'planetId',
|
|
137
|
+
)
|
|
138
|
+
|
|
139
|
+
export const detailsCommand: NetworkCommand = observedCommand(
|
|
140
|
+
'game',
|
|
141
|
+
'details',
|
|
142
|
+
planetReferenceInput,
|
|
143
|
+
details,
|
|
144
|
+
'planetId',
|
|
145
|
+
)
|
|
146
|
+
|
|
147
|
+
export const detailsUpgradeCommand: NetworkCommand = observedCommand(
|
|
148
|
+
'game',
|
|
149
|
+
'detailsUpgrade',
|
|
150
|
+
quantityUpgradeSchema,
|
|
151
|
+
detailsUpgrade,
|
|
152
|
+
'planetId',
|
|
153
|
+
)
|
|
154
|
+
|
|
155
|
+
export const developmentCommand: NetworkCommand = observedCommand(
|
|
156
|
+
'game',
|
|
157
|
+
'development',
|
|
158
|
+
planetReferenceInput,
|
|
159
|
+
development,
|
|
160
|
+
'planetId',
|
|
161
|
+
)
|
|
162
|
+
|
|
163
|
+
export const developmentUpgradeCommand: NetworkCommand = observedCommand(
|
|
164
|
+
'game',
|
|
165
|
+
'developmentUpgrade',
|
|
166
|
+
quantityUpgradeSchema,
|
|
167
|
+
developmentUpgrade,
|
|
168
|
+
'planetId',
|
|
169
|
+
)
|
|
170
|
+
|
|
171
|
+
export const ethicsCommand: NetworkCommand = observedCommand(
|
|
172
|
+
'game',
|
|
173
|
+
'ethics',
|
|
174
|
+
planetReferenceInput,
|
|
175
|
+
ethics,
|
|
176
|
+
'planetId',
|
|
177
|
+
)
|
|
178
|
+
|
|
179
|
+
export const ethicsUpgradeCommand: NetworkCommand = observedCommand(
|
|
180
|
+
'game',
|
|
181
|
+
'ethicsUpgrade',
|
|
182
|
+
choiceUpgradeSchema,
|
|
183
|
+
ethicsUpgrade,
|
|
184
|
+
'planetId',
|
|
185
|
+
)
|
|
186
|
+
|
|
187
|
+
export const fairCommand: NetworkCommand = observedCommand(
|
|
188
|
+
'game',
|
|
189
|
+
'fair',
|
|
190
|
+
planetReferenceInput,
|
|
191
|
+
fair,
|
|
192
|
+
'planetId',
|
|
193
|
+
)
|
|
194
|
+
|
|
195
|
+
export const fairUpgradeCommand: NetworkCommand = observedCommand(
|
|
196
|
+
'game',
|
|
197
|
+
'fairUpgrade',
|
|
198
|
+
quantityUpgradeSchema,
|
|
199
|
+
fairUpgrade,
|
|
200
|
+
'planetId',
|
|
201
|
+
)
|
|
202
|
+
|
|
203
|
+
export const governmentCommand: NetworkCommand = observedCommand(
|
|
204
|
+
'game',
|
|
205
|
+
'government',
|
|
206
|
+
planetReferenceInput,
|
|
207
|
+
government,
|
|
208
|
+
'planetId',
|
|
209
|
+
)
|
|
210
|
+
|
|
211
|
+
export const governmentUpgradeCommand: NetworkCommand = observedCommand(
|
|
212
|
+
'game',
|
|
213
|
+
'governmentUpgrade',
|
|
214
|
+
choiceUpgradeSchema,
|
|
215
|
+
governmentUpgrade,
|
|
216
|
+
'planetId',
|
|
217
|
+
)
|
|
218
|
+
|
|
219
|
+
export const ideologiesCommand: NetworkCommand = observedCommand(
|
|
220
|
+
'game',
|
|
221
|
+
'ideologies',
|
|
222
|
+
planetReferenceInput,
|
|
223
|
+
ideologies,
|
|
224
|
+
'planetId',
|
|
225
|
+
)
|
|
226
|
+
|
|
227
|
+
export const ideologiesUpgradeCommand: NetworkCommand = observedCommand(
|
|
228
|
+
'game',
|
|
229
|
+
'ideologiesUpgrade',
|
|
230
|
+
quantityUpgradeSchema,
|
|
231
|
+
ideologiesUpgrade,
|
|
232
|
+
'planetId',
|
|
233
|
+
)
|
|
234
|
+
|
|
235
|
+
export const mineralsCommand: NetworkCommand = observedCommand(
|
|
236
|
+
'game',
|
|
237
|
+
'minerals',
|
|
238
|
+
planetReferenceInput,
|
|
239
|
+
minerals,
|
|
240
|
+
'planetId',
|
|
241
|
+
)
|
|
242
|
+
|
|
243
|
+
export const mineralsUpgradeCommand: NetworkCommand = observedCommand(
|
|
244
|
+
'game',
|
|
245
|
+
'mineralsUpgrade',
|
|
246
|
+
quantityUpgradeSchema,
|
|
247
|
+
mineralsUpgrade,
|
|
248
|
+
'planetId',
|
|
249
|
+
)
|
|
250
|
+
|
|
251
|
+
export const officerCommand: NetworkCommand = observedCommand(
|
|
252
|
+
'game',
|
|
253
|
+
'officer',
|
|
254
|
+
planetReferenceInput,
|
|
255
|
+
officer,
|
|
256
|
+
'planetId',
|
|
257
|
+
)
|
|
258
|
+
|
|
259
|
+
export const officerUpgradeCommand: NetworkCommand = observedCommand(
|
|
260
|
+
'game',
|
|
261
|
+
'officerUpgrade',
|
|
262
|
+
quantityUpgradeSchema,
|
|
263
|
+
officerUpgrade,
|
|
264
|
+
'planetId',
|
|
265
|
+
)
|
|
266
|
+
|
|
267
|
+
export const partyCommand: NetworkCommand = observedCommand(
|
|
268
|
+
'game',
|
|
269
|
+
'party',
|
|
270
|
+
planetReferenceInput,
|
|
271
|
+
party,
|
|
272
|
+
'planetId',
|
|
273
|
+
)
|
|
274
|
+
|
|
275
|
+
export const partyUpgradeCommand: NetworkCommand = observedCommand(
|
|
276
|
+
'game',
|
|
277
|
+
'partyUpgrade',
|
|
278
|
+
quantityUpgradeSchema,
|
|
279
|
+
partyUpgrade,
|
|
280
|
+
'planetId',
|
|
281
|
+
)
|
|
282
|
+
|
|
283
|
+
export const premiumCommand: NetworkCommand = observedCommand(
|
|
284
|
+
'game',
|
|
285
|
+
'premium',
|
|
286
|
+
planetReferenceInput,
|
|
287
|
+
premium,
|
|
288
|
+
'planetId',
|
|
289
|
+
)
|
|
290
|
+
|
|
291
|
+
export const premiumUpgradeCommand: NetworkCommand = observedCommand(
|
|
292
|
+
'game',
|
|
293
|
+
'premiumUpgrade',
|
|
294
|
+
quantityUpgradeSchema,
|
|
295
|
+
premiumUpgrade,
|
|
296
|
+
'planetId',
|
|
297
|
+
)
|
|
298
|
+
|
|
299
|
+
export const raceCommand: NetworkCommand = observedCommand(
|
|
300
|
+
'game',
|
|
301
|
+
'race',
|
|
302
|
+
planetReferenceInput,
|
|
303
|
+
race,
|
|
304
|
+
'planetId',
|
|
305
|
+
)
|
|
306
|
+
|
|
307
|
+
export const raceUpgradeCommand: NetworkCommand = observedCommand(
|
|
308
|
+
'game',
|
|
309
|
+
'raceUpgrade',
|
|
310
|
+
choiceUpgradeSchema,
|
|
311
|
+
raceUpgrade,
|
|
312
|
+
'planetId',
|
|
313
|
+
)
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import { information, informationDestroyMissiles, informationSendFleet } from '@senators/bifrost'
|
|
2
|
+
|
|
3
|
+
import { observedCommand } from '../../catalog.ts'
|
|
4
|
+
import { elementInput, planetReferenceInput } from '../../input/shared.ts'
|
|
5
|
+
import { numberInput, required } from '../../input/spec.ts'
|
|
6
|
+
import type { InputSpec } from '../../input/spec.ts'
|
|
7
|
+
import type { NetworkCommand } from '../../types.ts'
|
|
8
|
+
|
|
9
|
+
const informationSchema = {
|
|
10
|
+
kind: 'object',
|
|
11
|
+
fields: {
|
|
12
|
+
planetId: required(numberInput),
|
|
13
|
+
elementId: required(numberInput),
|
|
14
|
+
},
|
|
15
|
+
} satisfies InputSpec<Parameters<typeof information>[1]>
|
|
16
|
+
|
|
17
|
+
const informationDestroyMissilesSchema = {
|
|
18
|
+
kind: 'object',
|
|
19
|
+
fields: {
|
|
20
|
+
planetId: required(numberInput),
|
|
21
|
+
missiles: required(elementInput),
|
|
22
|
+
},
|
|
23
|
+
} satisfies InputSpec<Parameters<typeof informationDestroyMissiles>[1]>
|
|
24
|
+
|
|
25
|
+
const informationSendFleetSchema = {
|
|
26
|
+
kind: 'object',
|
|
27
|
+
fields: {
|
|
28
|
+
origin: required(planetReferenceInput),
|
|
29
|
+
ships: required(elementInput),
|
|
30
|
+
target: required(planetReferenceInput),
|
|
31
|
+
},
|
|
32
|
+
} satisfies InputSpec<Parameters<typeof informationSendFleet>[1]>
|
|
33
|
+
|
|
34
|
+
export const informationCommand: NetworkCommand = observedCommand(
|
|
35
|
+
'game',
|
|
36
|
+
'information',
|
|
37
|
+
informationSchema,
|
|
38
|
+
information,
|
|
39
|
+
'planetId',
|
|
40
|
+
)
|
|
41
|
+
|
|
42
|
+
export const informationDestroyMissilesCommand: NetworkCommand = observedCommand(
|
|
43
|
+
'game',
|
|
44
|
+
'informationDestroyMissiles',
|
|
45
|
+
informationDestroyMissilesSchema,
|
|
46
|
+
informationDestroyMissiles,
|
|
47
|
+
'planetId',
|
|
48
|
+
)
|
|
49
|
+
|
|
50
|
+
export const informationSendFleetCommand: NetworkCommand = observedCommand(
|
|
51
|
+
'game',
|
|
52
|
+
'informationSendFleet',
|
|
53
|
+
informationSendFleetSchema,
|
|
54
|
+
informationSendFleet,
|
|
55
|
+
'origin',
|
|
56
|
+
)
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { logout } from '@senators/bifrost'
|
|
2
|
+
|
|
3
|
+
import { observedCommand } from '../../catalog.ts'
|
|
4
|
+
import { emptyInput } from '../../input/spec.ts'
|
|
5
|
+
import type { NetworkCommand } from '../../types.ts'
|
|
6
|
+
|
|
7
|
+
export const logoutCommand: NetworkCommand = observedCommand<Record<string, never>>(
|
|
8
|
+
'game',
|
|
9
|
+
'logout',
|
|
10
|
+
emptyInput,
|
|
11
|
+
(session) => logout(session),
|
|
12
|
+
)
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
import { market, marketBuyLot, marketCancelLot, marketCreateLot } from '@senators/bifrost'
|
|
2
|
+
|
|
3
|
+
import { observedCommand } from '../../catalog.ts'
|
|
4
|
+
import { planetReferenceInput, elementInput } from '../../input/shared.ts'
|
|
5
|
+
import { numberInput, required } from '../../input/spec.ts'
|
|
6
|
+
import type { InputSpec } from '../../input/spec.ts'
|
|
7
|
+
import type { NetworkCommand } from '../../types.ts'
|
|
8
|
+
|
|
9
|
+
const marketSchema = planetReferenceInput satisfies InputSpec<Parameters<typeof market>[1]>
|
|
10
|
+
|
|
11
|
+
const marketBuyLotSchema = {
|
|
12
|
+
kind: 'object',
|
|
13
|
+
fields: {
|
|
14
|
+
planetId: required(numberInput),
|
|
15
|
+
lotId: required(numberInput),
|
|
16
|
+
},
|
|
17
|
+
} satisfies InputSpec<Parameters<typeof marketBuyLot>[1]>
|
|
18
|
+
|
|
19
|
+
const marketCancelLotSchema = {
|
|
20
|
+
kind: 'object',
|
|
21
|
+
fields: {
|
|
22
|
+
planetId: required(numberInput),
|
|
23
|
+
lotId: required(numberInput),
|
|
24
|
+
},
|
|
25
|
+
} satisfies InputSpec<Parameters<typeof marketCancelLot>[1]>
|
|
26
|
+
|
|
27
|
+
const marketCreateLotSchema = {
|
|
28
|
+
kind: 'object',
|
|
29
|
+
fields: {
|
|
30
|
+
planetId: required(numberInput),
|
|
31
|
+
category: required(numberInput),
|
|
32
|
+
elements: required(elementInput),
|
|
33
|
+
price: required(numberInput),
|
|
34
|
+
},
|
|
35
|
+
} satisfies InputSpec<Parameters<typeof marketCreateLot>[1]>
|
|
36
|
+
|
|
37
|
+
export const marketCommand: NetworkCommand = observedCommand(
|
|
38
|
+
'game',
|
|
39
|
+
'market',
|
|
40
|
+
marketSchema,
|
|
41
|
+
market,
|
|
42
|
+
'planetId',
|
|
43
|
+
)
|
|
44
|
+
|
|
45
|
+
export const marketBuyLotCommand: NetworkCommand = observedCommand(
|
|
46
|
+
'game',
|
|
47
|
+
'marketBuyLot',
|
|
48
|
+
marketBuyLotSchema,
|
|
49
|
+
marketBuyLot,
|
|
50
|
+
'planetId',
|
|
51
|
+
)
|
|
52
|
+
|
|
53
|
+
export const marketCancelLotCommand: NetworkCommand = observedCommand(
|
|
54
|
+
'game',
|
|
55
|
+
'marketCancelLot',
|
|
56
|
+
marketCancelLotSchema,
|
|
57
|
+
marketCancelLot,
|
|
58
|
+
'planetId',
|
|
59
|
+
)
|
|
60
|
+
|
|
61
|
+
export const marketCreateLotCommand: NetworkCommand = observedCommand(
|
|
62
|
+
'game',
|
|
63
|
+
'marketCreateLot',
|
|
64
|
+
marketCreateLotSchema,
|
|
65
|
+
marketCreateLot,
|
|
66
|
+
'planetId',
|
|
67
|
+
)
|
|
@@ -0,0 +1,129 @@
|
|
|
1
|
+
import {
|
|
2
|
+
messages,
|
|
3
|
+
messagesAction,
|
|
4
|
+
messagesArchiveOne,
|
|
5
|
+
messagesDeleteOne,
|
|
6
|
+
messagesSend,
|
|
7
|
+
messagesView,
|
|
8
|
+
messagesWrite,
|
|
9
|
+
} from '@senators/bifrost'
|
|
10
|
+
|
|
11
|
+
import { observedCommand } from '../../catalog.ts'
|
|
12
|
+
import {
|
|
13
|
+
arrayInput,
|
|
14
|
+
emptyInput,
|
|
15
|
+
enumeration,
|
|
16
|
+
numberInput,
|
|
17
|
+
optional,
|
|
18
|
+
required,
|
|
19
|
+
stringInput,
|
|
20
|
+
} from '../../input/spec.ts'
|
|
21
|
+
import type { InputSpec } from '../../input/spec.ts'
|
|
22
|
+
import type { NetworkCommand } from '../../types.ts'
|
|
23
|
+
|
|
24
|
+
const messagesActionSchema = {
|
|
25
|
+
kind: 'object',
|
|
26
|
+
fields: {
|
|
27
|
+
category: required(numberInput),
|
|
28
|
+
command: required(
|
|
29
|
+
enumeration([
|
|
30
|
+
'readmarked',
|
|
31
|
+
'readtypeall',
|
|
32
|
+
'readall',
|
|
33
|
+
'deletemarked',
|
|
34
|
+
'deleteunmarked',
|
|
35
|
+
'deletetypeall',
|
|
36
|
+
'deleteall',
|
|
37
|
+
'archivemarked',
|
|
38
|
+
]),
|
|
39
|
+
),
|
|
40
|
+
ids: optional(arrayInput(numberInput)),
|
|
41
|
+
},
|
|
42
|
+
} satisfies InputSpec<Parameters<typeof messagesAction>[1]>
|
|
43
|
+
|
|
44
|
+
const messagesArchiveOneSchema = {
|
|
45
|
+
kind: 'object',
|
|
46
|
+
fields: {
|
|
47
|
+
msgId: required(numberInput),
|
|
48
|
+
},
|
|
49
|
+
} satisfies InputSpec<Parameters<typeof messagesArchiveOne>[1]>
|
|
50
|
+
|
|
51
|
+
const messagesDeleteOneSchema = {
|
|
52
|
+
kind: 'object',
|
|
53
|
+
fields: {
|
|
54
|
+
msgId: required(numberInput),
|
|
55
|
+
},
|
|
56
|
+
} satisfies InputSpec<Parameters<typeof messagesDeleteOne>[1]>
|
|
57
|
+
|
|
58
|
+
const messagesSendSchema = {
|
|
59
|
+
kind: 'object',
|
|
60
|
+
fields: {
|
|
61
|
+
recipientId: required(numberInput),
|
|
62
|
+
subject: required(stringInput),
|
|
63
|
+
text: required(stringInput),
|
|
64
|
+
},
|
|
65
|
+
} satisfies InputSpec<Parameters<typeof messagesSend>[1]>
|
|
66
|
+
|
|
67
|
+
const messagesViewSchema = {
|
|
68
|
+
kind: 'object',
|
|
69
|
+
fields: {
|
|
70
|
+
category: required(numberInput),
|
|
71
|
+
page: required(numberInput),
|
|
72
|
+
},
|
|
73
|
+
} satisfies InputSpec<Parameters<typeof messagesView>[1]>
|
|
74
|
+
|
|
75
|
+
const messagesWriteSchema = {
|
|
76
|
+
kind: 'object',
|
|
77
|
+
fields: {
|
|
78
|
+
recipientId: required(numberInput),
|
|
79
|
+
},
|
|
80
|
+
} satisfies InputSpec<Parameters<typeof messagesWrite>[1]>
|
|
81
|
+
|
|
82
|
+
export const messagesCommand: NetworkCommand = observedCommand<Record<string, never>>(
|
|
83
|
+
'game',
|
|
84
|
+
'messages',
|
|
85
|
+
emptyInput,
|
|
86
|
+
(session) => messages(session),
|
|
87
|
+
)
|
|
88
|
+
|
|
89
|
+
export const messagesActionCommand: NetworkCommand = observedCommand(
|
|
90
|
+
'game',
|
|
91
|
+
'messagesAction',
|
|
92
|
+
messagesActionSchema,
|
|
93
|
+
messagesAction,
|
|
94
|
+
)
|
|
95
|
+
|
|
96
|
+
export const messagesArchiveOneCommand: NetworkCommand = observedCommand(
|
|
97
|
+
'game',
|
|
98
|
+
'messagesArchiveOne',
|
|
99
|
+
messagesArchiveOneSchema,
|
|
100
|
+
messagesArchiveOne,
|
|
101
|
+
)
|
|
102
|
+
|
|
103
|
+
export const messagesDeleteOneCommand: NetworkCommand = observedCommand(
|
|
104
|
+
'game',
|
|
105
|
+
'messagesDeleteOne',
|
|
106
|
+
messagesDeleteOneSchema,
|
|
107
|
+
messagesDeleteOne,
|
|
108
|
+
)
|
|
109
|
+
|
|
110
|
+
export const messagesSendCommand: NetworkCommand = observedCommand(
|
|
111
|
+
'game',
|
|
112
|
+
'messagesSend',
|
|
113
|
+
messagesSendSchema,
|
|
114
|
+
messagesSend,
|
|
115
|
+
)
|
|
116
|
+
|
|
117
|
+
export const messagesViewCommand: NetworkCommand = observedCommand(
|
|
118
|
+
'game',
|
|
119
|
+
'messagesView',
|
|
120
|
+
messagesViewSchema,
|
|
121
|
+
messagesView,
|
|
122
|
+
)
|
|
123
|
+
|
|
124
|
+
export const messagesWriteCommand: NetworkCommand = observedCommand(
|
|
125
|
+
'game',
|
|
126
|
+
'messagesWrite',
|
|
127
|
+
messagesWriteSchema,
|
|
128
|
+
messagesWrite,
|
|
129
|
+
)
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
import { notes, notesDelete, notesDetail, notesInsert } from '@senators/bifrost'
|
|
2
|
+
|
|
3
|
+
import { observedCommand } from '../../catalog.ts'
|
|
4
|
+
import {
|
|
5
|
+
arrayInput,
|
|
6
|
+
emptyInput,
|
|
7
|
+
numberInput,
|
|
8
|
+
optional,
|
|
9
|
+
required,
|
|
10
|
+
stringInput,
|
|
11
|
+
} from '../../input/spec.ts'
|
|
12
|
+
import type { InputSpec } from '../../input/spec.ts'
|
|
13
|
+
import type { NetworkCommand } from '../../types.ts'
|
|
14
|
+
|
|
15
|
+
const notesDeleteSchema = {
|
|
16
|
+
kind: 'object',
|
|
17
|
+
fields: {
|
|
18
|
+
noteIds: required(arrayInput(numberInput)),
|
|
19
|
+
},
|
|
20
|
+
} satisfies InputSpec<Parameters<typeof notesDelete>[1]>
|
|
21
|
+
|
|
22
|
+
const notesDetailSchema = {
|
|
23
|
+
kind: 'object',
|
|
24
|
+
fields: {
|
|
25
|
+
noteId: required(numberInput),
|
|
26
|
+
},
|
|
27
|
+
} satisfies InputSpec<Parameters<typeof notesDetail>[1]>
|
|
28
|
+
|
|
29
|
+
const notesInsertSchema = {
|
|
30
|
+
kind: 'object',
|
|
31
|
+
fields: {
|
|
32
|
+
noteId: optional(numberInput),
|
|
33
|
+
priority: optional(numberInput),
|
|
34
|
+
text: optional(stringInput),
|
|
35
|
+
title: optional(stringInput),
|
|
36
|
+
},
|
|
37
|
+
} satisfies InputSpec<Parameters<typeof notesInsert>[1]>
|
|
38
|
+
|
|
39
|
+
export const notesCommand: NetworkCommand = observedCommand<Record<string, never>>(
|
|
40
|
+
'game',
|
|
41
|
+
'notes',
|
|
42
|
+
emptyInput,
|
|
43
|
+
(session) => notes(session),
|
|
44
|
+
)
|
|
45
|
+
|
|
46
|
+
export const notesDeleteCommand: NetworkCommand = observedCommand(
|
|
47
|
+
'game',
|
|
48
|
+
'notesDelete',
|
|
49
|
+
notesDeleteSchema,
|
|
50
|
+
notesDelete,
|
|
51
|
+
)
|
|
52
|
+
|
|
53
|
+
export const notesDetailCommand: NetworkCommand = observedCommand(
|
|
54
|
+
'game',
|
|
55
|
+
'notesDetail',
|
|
56
|
+
notesDetailSchema,
|
|
57
|
+
notesDetail,
|
|
58
|
+
)
|
|
59
|
+
|
|
60
|
+
export const notesInsertCommand: NetworkCommand = observedCommand(
|
|
61
|
+
'game',
|
|
62
|
+
'notesInsert',
|
|
63
|
+
notesInsertSchema,
|
|
64
|
+
notesInsert,
|
|
65
|
+
)
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import { overview, overviewDelete, overviewRename } from '@senators/bifrost'
|
|
2
|
+
|
|
3
|
+
import { observedCommand } from '../../catalog.ts'
|
|
4
|
+
import { planetReferenceInput } from '../../input/shared.ts'
|
|
5
|
+
import { numberInput, required, stringInput } from '../../input/spec.ts'
|
|
6
|
+
import type { InputSpec } from '../../input/spec.ts'
|
|
7
|
+
import type { NetworkCommand } from '../../types.ts'
|
|
8
|
+
|
|
9
|
+
const overviewSchema = planetReferenceInput satisfies InputSpec<Parameters<typeof overview>[1]>
|
|
10
|
+
|
|
11
|
+
const overviewDeleteSchema = {
|
|
12
|
+
kind: 'object',
|
|
13
|
+
fields: {
|
|
14
|
+
planetId: required(numberInput),
|
|
15
|
+
password: required(stringInput),
|
|
16
|
+
},
|
|
17
|
+
} satisfies InputSpec<Parameters<typeof overviewDelete>[1]>
|
|
18
|
+
|
|
19
|
+
const overviewRenameSchema = {
|
|
20
|
+
kind: 'object',
|
|
21
|
+
fields: {
|
|
22
|
+
planetId: required(numberInput),
|
|
23
|
+
name: required(stringInput),
|
|
24
|
+
},
|
|
25
|
+
} satisfies InputSpec<Parameters<typeof overviewRename>[1]>
|
|
26
|
+
|
|
27
|
+
export const overviewCommand: NetworkCommand = observedCommand(
|
|
28
|
+
'game',
|
|
29
|
+
'overview',
|
|
30
|
+
overviewSchema,
|
|
31
|
+
overview,
|
|
32
|
+
'planetId',
|
|
33
|
+
)
|
|
34
|
+
|
|
35
|
+
export const overviewDeleteCommand: NetworkCommand = observedCommand(
|
|
36
|
+
'game',
|
|
37
|
+
'overviewDelete',
|
|
38
|
+
overviewDeleteSchema,
|
|
39
|
+
overviewDelete,
|
|
40
|
+
'planetId',
|
|
41
|
+
)
|
|
42
|
+
|
|
43
|
+
export const overviewRenameCommand: NetworkCommand = observedCommand(
|
|
44
|
+
'game',
|
|
45
|
+
'overviewRename',
|
|
46
|
+
overviewRenameSchema,
|
|
47
|
+
overviewRename,
|
|
48
|
+
'planetId',
|
|
49
|
+
)
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { phalanx } from '@senators/bifrost'
|
|
2
|
+
|
|
3
|
+
import { observedCommand } from '../../catalog.ts'
|
|
4
|
+
import { coordinateInput, planetReferenceInput } from '../../input/shared.ts'
|
|
5
|
+
import { required } from '../../input/spec.ts'
|
|
6
|
+
import type { InputSpec } from '../../input/spec.ts'
|
|
7
|
+
import type { NetworkCommand } from '../../types.ts'
|
|
8
|
+
|
|
9
|
+
const phalanxSchema = {
|
|
10
|
+
kind: 'object',
|
|
11
|
+
fields: {
|
|
12
|
+
origin: required(planetReferenceInput),
|
|
13
|
+
target: required(coordinateInput),
|
|
14
|
+
},
|
|
15
|
+
} satisfies InputSpec<Parameters<typeof phalanx>[1]>
|
|
16
|
+
|
|
17
|
+
export const phalanxCommand: NetworkCommand = observedCommand(
|
|
18
|
+
'game',
|
|
19
|
+
'phalanx',
|
|
20
|
+
phalanxSchema,
|
|
21
|
+
phalanx,
|
|
22
|
+
'origin',
|
|
23
|
+
)
|