Full lesson
airdrop_quest
What it does
From the project README:
Monsters, challenges, and monster stats are all automatically generated by AI. As a result, some behaviors may become slow or laggy.
- Original
- ytakahashi2020/airdrop_quest
- SuperStack fork
- Blockchains/airdrop_quest @
0d24628 - Stars
- 2
- Last push (original)
- 2025-12-27
- Languages
- TypeScript, CSS, Rust, JavaScript
- Detected stack
- MetaplexNext.jsweb3.js
- Categories
- Other
- Licence
- MIT
- Homepage
- https://qdropadventure.vercel.app
Architecture
32 source files. By extension: .ts ×21, .tsx ×9, .js ×1, .rs ×1.
| Top-level directory | Source files |
|---|---|
pkgs | 32 |
Dapp: deploying
This fork is queued for its own live dapp on Sol.College, with a Devnet/Mainnet switch. It appears here, at /dapps/airdrop-quest/, once it is deployed and checked on devnet. Until then, run it locally with the commands below.
Key code, explained
Excerpts chosen automatically where the code uses the most Solana concepts, pinned to the fork's commit.
pkgs/frontend/src/lib.rs L61–84 @ 0d24628 · MIT · original // Create a context for the transfer and execute the transfer_checked instruction. let cpi_ctx = CpiContext::new(token_program.clone(), transfer_cpi_accounts); token_2022::transfer_checked(cpi_ctx, amount, ctx.accounts.mint.decimals)?; } Ok(()) }} // Define the data structure for the accounts involved in the send_to_all function.#[derive(Accounts)]pub struct SendTokens<'info> { #[account(mut)] pub from: Box<InterfaceAccount<'info, TokenAccount>>, pub authority: Signer<'info>, #[account()] pub mint: Box<InterfaceAccount<'info, Mint>>, pub token_program: Program<'info, Token2022>,} // Custom errors returned from this program.#[error_code]pub enum ErrorCode { #[msg("Invalid Token Account. Please ensure the account is correctly initialized.")]- Line 61
// Create a context for the transfer and execute the transfer_checked instruction.: A checked token transfer, which also verifies the mint and decimals. - Line 62
let cpi_ctx = CpiContext::new(token_program.clone(), transfer_cpi_accounts);: Makes a cross-program invocation into another program. - Line 63
token_2022::transfer_checked(cpi_ctx, amount, ctx.accounts.mint.decimals)?;: Targets the Token-2022 program instead of the original Token Program. - Line 75
pub authority: Signer<'info>,: Requires this account to have signed the transaction.
How to run, build and test
These commands come from the repo's own manifests (package.json scripts, Anchor.toml, Cargo, go.mod, Makefile). Check the README for prerequisites and environment variables.
| Directory | Command | Runs |
|---|---|---|
pkgs/cdk | npm run build | tsc |
pkgs/cdk | npm run test | jest |
pkgs/cdk | npm run deploy | cdk deploy --require-approval never |
pkgs/frontend | npm run dev | next dev |
pkgs/frontend | npm run start | next start |
pkgs/frontend | npm run build | next build |
pkgs/frontend | npm run lint | next lint |
What you could build from it
- Fork the SuperStack copy and extend it within the Other gaps listed on the idea page.
- Learn the pattern first: Program Derived Addresses (PDAs)
- Learn the pattern first: Cross-Program Invocations (CPIs)