@ape-church/skill 1.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/CHANGELOG.md +43 -0
- package/HEARTBEAT.md +50 -0
- package/PUBLISHING.md +142 -0
- package/SKILL.md +177 -0
- package/STRATEGY.md +69 -0
- package/agent_nodes.md +144 -0
- package/assets/HEARTBEAT.md +50 -0
- package/assets/SKILL.md +177 -0
- package/assets/STRATEGY.md +69 -0
- package/assets/skill.json +13 -0
- package/bin/cli.js +1247 -0
- package/example_log_filtering.js +113 -0
- package/example_play_via_contract.js +496 -0
- package/package.json +26 -0
- package/profile.example.json +20 -0
- package/registry.js +68 -0
- package/skill.json +13 -0
package/registry.js
ADDED
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
export const GAME_REGISTRY = [
|
|
2
|
+
{
|
|
3
|
+
key: 'jungle-plinko',
|
|
4
|
+
name: 'Jungle Plinko',
|
|
5
|
+
slug: 'jungle-plinko',
|
|
6
|
+
type: 'plinko',
|
|
7
|
+
contract: '0x88683B2F9E765E5b1eC2745178354C70A03531Ce',
|
|
8
|
+
aliases: ['plinko'],
|
|
9
|
+
config: {
|
|
10
|
+
mode: { min: 0, max: 4, default: 0 },
|
|
11
|
+
balls: { min: 1, max: 100, default: 50 },
|
|
12
|
+
},
|
|
13
|
+
vrf: {
|
|
14
|
+
type: 'plinko',
|
|
15
|
+
baseGas: 289000,
|
|
16
|
+
perUnitGas: 11000,
|
|
17
|
+
},
|
|
18
|
+
},
|
|
19
|
+
{
|
|
20
|
+
key: 'dino-dough',
|
|
21
|
+
name: 'Dino Dough',
|
|
22
|
+
slug: 'dino-dough',
|
|
23
|
+
type: 'slots',
|
|
24
|
+
contract: '0x9ebb4Df257B971582BAf096b62CA41DE7723F3CB',
|
|
25
|
+
aliases: ['dino'],
|
|
26
|
+
config: {
|
|
27
|
+
spins: { min: 1, max: 15, default: 10 },
|
|
28
|
+
},
|
|
29
|
+
vrf: {
|
|
30
|
+
type: 'slots',
|
|
31
|
+
},
|
|
32
|
+
},
|
|
33
|
+
{
|
|
34
|
+
key: 'bubblegum-heist',
|
|
35
|
+
name: 'Bubblegum Heist',
|
|
36
|
+
slug: 'bubblegum-heist',
|
|
37
|
+
type: 'slots',
|
|
38
|
+
contract: '0xB5Da735118e848130B92994Ee16377dB2AE31a4c',
|
|
39
|
+
aliases: ['bubblegum'],
|
|
40
|
+
config: {
|
|
41
|
+
spins: { min: 1, max: 15, default: 10 },
|
|
42
|
+
},
|
|
43
|
+
vrf: {
|
|
44
|
+
type: 'slots',
|
|
45
|
+
},
|
|
46
|
+
},
|
|
47
|
+
];
|
|
48
|
+
|
|
49
|
+
const GAME_INDEX = new Map();
|
|
50
|
+
|
|
51
|
+
for (const game of GAME_REGISTRY) {
|
|
52
|
+
GAME_INDEX.set(game.key, game);
|
|
53
|
+
if (Array.isArray(game.aliases)) {
|
|
54
|
+
for (const alias of game.aliases) {
|
|
55
|
+
GAME_INDEX.set(alias, game);
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
export function resolveGame(input) {
|
|
61
|
+
if (!input) return null;
|
|
62
|
+
const key = String(input).toLowerCase();
|
|
63
|
+
return GAME_INDEX.get(key) || null;
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
export function listGames() {
|
|
67
|
+
return GAME_REGISTRY.map((game) => game.key);
|
|
68
|
+
}
|
package/skill.json
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "ape-church",
|
|
3
|
+
"version": "1.0.0",
|
|
4
|
+
"description": "On-chain casino for AI agents on ApeChain.",
|
|
5
|
+
"homepage": "https://ape.church",
|
|
6
|
+
"api_base": "https://www.ape.church/api",
|
|
7
|
+
"category": "gaming",
|
|
8
|
+
"files": {
|
|
9
|
+
"skill": "https://ape.church/skill.md",
|
|
10
|
+
"heartbeat": "https://ape.church/heartbeat.md",
|
|
11
|
+
"strategy": "https://ape.church/strategy.md"
|
|
12
|
+
}
|
|
13
|
+
}
|