@xgamesfun/solana 0.28.4 → 0.28.5
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/README.md +11 -11
- package/package.json +5 -1
- package/skills/xsolana-economy/SKILL.md +5 -5
- package/types/approve/wallet-adds.d.mts +15 -0
package/README.md
CHANGED
|
@@ -77,7 +77,7 @@ codex plugin add xsolana@xgamesfun
|
|
|
77
77
|
|
|
78
78
|
**claude.ai, ChatGPT or Claude Desktop:** add `https://xgames.fun/mcp` as a custom connector. Nothing to install.
|
|
79
79
|
|
|
80
|
-
**Cursor, Cline, opencode or any MCP client:** run `npx -y --package=@xgamesfun/solana@0.28.
|
|
80
|
+
**Cursor, Cline, opencode or any MCP client:** run `npx -y --package=@xgamesfun/solana@0.28.5 xsolana mcp`.
|
|
81
81
|
|
|
82
82
|
**Any agent that reads skills** (Copilot, Gemini CLI, Windsurf…): `npx skills add XGamesFun/solana-kit`.
|
|
83
83
|
|
|
@@ -88,26 +88,26 @@ are in [docs/harnesses.md](docs/harnesses.md).
|
|
|
88
88
|
|
|
89
89
|
```bash
|
|
90
90
|
# find a worked example close to your idea
|
|
91
|
-
npx -y @xgamesfun/solana@0.28.
|
|
91
|
+
npx -y @xgamesfun/solana@0.28.5 examples shop with loot boxes
|
|
92
92
|
|
|
93
93
|
# using a coin you already launched? read it from the chain into its "tokens" entry
|
|
94
|
-
npx -y @xgamesfun/solana@0.28.
|
|
94
|
+
npx -y @xgamesfun/solana@0.28.5 token <its mint address>
|
|
95
95
|
|
|
96
96
|
# does it work? where does the money go? what does it cost?
|
|
97
|
-
npx -y @xgamesfun/solana@0.28.
|
|
98
|
-
npx -y @xgamesfun/solana@0.28.
|
|
99
|
-
npx -y @xgamesfun/solana@0.28.
|
|
97
|
+
npx -y @xgamesfun/solana@0.28.5 check xsolana.json
|
|
98
|
+
npx -y @xgamesfun/solana@0.28.5 simulate xsolana.json
|
|
99
|
+
npx -y @xgamesfun/solana@0.28.5 cost xsolana.json
|
|
100
100
|
|
|
101
101
|
# the whole economy in plain words, and what a cheater could get
|
|
102
|
-
npx -y @xgamesfun/solana@0.28.
|
|
103
|
-
npx -y @xgamesfun/solana@0.28.
|
|
102
|
+
npx -y @xgamesfun/solana@0.28.5 explain xsolana.json
|
|
103
|
+
npx -y @xgamesfun/solana@0.28.5 review xsolana.json
|
|
104
104
|
|
|
105
105
|
# go live: a key file for the project (it prints the address to send SOL to, never the key)…
|
|
106
|
-
npx -y @xgamesfun/solana@0.28.
|
|
106
|
+
npx -y @xgamesfun/solana@0.28.5 keygen ~/.config/xsolana/my-game.json
|
|
107
107
|
# …then everything going live would send, and a code; nothing is sent
|
|
108
|
-
npx -y @xgamesfun/solana@0.28.
|
|
108
|
+
npx -y @xgamesfun/solana@0.28.5 approve xsolana.json --keypair ~/.config/xsolana/my-game.json
|
|
109
109
|
# …and with that code, exactly what it listed is sent
|
|
110
|
-
npx -y @xgamesfun/solana@0.28.
|
|
110
|
+
npx -y @xgamesfun/solana@0.28.5 approve xsolana.json --keypair ~/.config/xsolana/my-game.json --yes <code>
|
|
111
111
|
```
|
|
112
112
|
|
|
113
113
|
Each command names an exact version, so you always run the release you meant to. `xsolana help` lists them all.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@xgamesfun/solana",
|
|
3
|
-
"version": "0.28.
|
|
3
|
+
"version": "0.28.5",
|
|
4
4
|
"mcpName": "io.github.XGamesFun/solana-kit",
|
|
5
5
|
"description": "Loot boxes, gacha, shops, lotteries, auctions, NFT staking, crafting and rewards on Solana without writing a smart contract: one shared program, its JS client, a CLI, and an MCP server and skill so Claude Code, Codex or any AI agent can design, check, simulate and launch an economy.",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -74,6 +74,10 @@
|
|
|
74
74
|
"types": "./types/approve/keyfile.d.mts",
|
|
75
75
|
"default": "./js/approve/keyfile.mjs"
|
|
76
76
|
},
|
|
77
|
+
"./wallet-adds": {
|
|
78
|
+
"types": "./types/approve/wallet-adds.d.mts",
|
|
79
|
+
"default": "./js/approve/wallet-adds.mjs"
|
|
80
|
+
},
|
|
77
81
|
"./idl.json": "./js/client/idl/loot.json",
|
|
78
82
|
"./package.json": "./package.json",
|
|
79
83
|
"./release.json": "./release.json",
|
|
@@ -11,9 +11,9 @@ signed by a key file on the owner's own machine, once they have read what will b
|
|
|
11
11
|
**devnet**, where nothing is real money, and on **mainnet**, where everything is: an economy is on devnet unless its
|
|
12
12
|
file says `"network": "mainnet"`.
|
|
13
13
|
|
|
14
|
-
The tools are the `xsolana_*` MCP tools. Without MCP, the same from a terminal: `npx -y @xgamesfun/solana@0.28.
|
|
15
|
-
`npx -y @xgamesfun/solana@0.28.
|
|
16
|
-
or `npx -y @xgamesfun/solana@0.28.
|
|
14
|
+
The tools are the `xsolana_*` MCP tools. Without MCP, the same from a terminal: `npx -y @xgamesfun/solana@0.28.5 <guide|examples|check|simulate|cost|explain|review|publish|status> [xsolana.json]`,
|
|
15
|
+
`npx -y @xgamesfun/solana@0.28.5 token <mint>` for a coin made elsewhere,
|
|
16
|
+
or `npx -y @xgamesfun/solana@0.28.5 tool <name> '<json>'` for any tool (always with the exact version).
|
|
17
17
|
|
|
18
18
|
## Rules (always)
|
|
19
19
|
|
|
@@ -141,7 +141,7 @@ or `npx -y @xgamesfun/solana@0.28.4 tool <name> '<json>'` for any tool (always w
|
|
|
141
141
|
9. **When they say "put it live"**: `xsolana_publish` lists every step and its cost and gives the commands, which you
|
|
142
142
|
run in the project folder exactly as given (they name the exact version; never drop it):
|
|
143
143
|
- **A new economy gets a key file**, unless the project has one:
|
|
144
|
-
`npx -y @xgamesfun/solana@0.28.
|
|
144
|
+
`npx -y @xgamesfun/solana@0.28.5 keygen ~/.config/xsolana/<name>.json`. Give the person the address it prints. A
|
|
145
145
|
Solana key file they already have and name themselves (`~/.config/solana/id.json`) works the same; never go
|
|
146
146
|
looking for one.
|
|
147
147
|
- **Say what the key file is** before anything is sent: the project's owner, and, unless the spec says otherwise,
|
|
@@ -156,7 +156,7 @@ or `npx -y @xgamesfun/solana@0.28.4 tool <name> '<json>'` for any tool (always w
|
|
|
156
156
|
devnet SOL for an economy on devnet, real SOL for one on mainnet), any seed in a coin that already exists, and every NFT a stash, a raffle or an auction names. A
|
|
157
157
|
collection they already have needs the key's address as its update authority. If they would rather not move
|
|
158
158
|
those, offer the browser wallet.
|
|
159
|
-
- **Show it**: `npx -y @xgamesfun/solana@0.28.
|
|
159
|
+
- **Show it**: `npx -y @xgamesfun/solana@0.28.5 approve xsolana.json --keypair <key file>` prints every step with
|
|
160
160
|
what it pays and trusts, the warnings, the notice and a code, and sends nothing. Give the person that printout as
|
|
161
161
|
it is, not a summary of it, and ask.
|
|
162
162
|
- **On their yes**, the same command with `--yes <code>`. What lands is written back into `xsolana.json`. If it
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Whether `theirs`, the message a wallet signed, is `ours`, the message prepared for it, with nothing but a wallet's
|
|
3
|
+
* own additions. `wallet`: the address the transaction was prepared for.
|
|
4
|
+
* → { ok: true, added: [what it added, in words] } or { ok: false, why: what it did, in words after "it …" }.
|
|
5
|
+
* Two messages that are the same bytes are not this function's to judge (nothing was added).
|
|
6
|
+
*/
|
|
7
|
+
export declare function walletAdded(ours: any, theirs: any, wallet: any): {
|
|
8
|
+
ok: boolean;
|
|
9
|
+
added: any[];
|
|
10
|
+
why?: undefined;
|
|
11
|
+
} | {
|
|
12
|
+
added?: undefined;
|
|
13
|
+
ok: boolean;
|
|
14
|
+
why: string;
|
|
15
|
+
};
|