Skip to content

baum1810/discord_last_meadow_auto

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 

Repository files navigation

Discord Auto-Clicker Script

An automated script for Discord that handles button clicking and arrow key sequences in mini-games.

⚠️ Disclaimer

This script is for educational purposes only. Use at your own risk. Automating interactions may violate Discord's Terms of Service and could result in account penalties.

Features

  • 🎮 Automatically plays arrow sequence mini-games
  • 🔨 Auto-clicks Craft buttons when available
  • 🗺️ Auto-clicks Adventure buttons
  • ▶️ Handles Continue button after successful crafts
  • ⏱️ Smart timing delays to prevent spam
  • 🔄 Continuous loop with state detection

Prerequisites

  • Discord Desktop App (PTB/Canary recommended) or Web Discord
  • Developer Tools enabled

Installation & Setup

Step 1: Open Developer Console

For Web Discord:

  • Press F12, or
  • Right-click on the page → Select Inspect

For Discord App:

  • Press Ctrl + Shift + I (Windows/Linux)
  • Press Cmd + Option + I (macOS)

Step 2: Enable DevTools (if needed)

If the console doesn't open:

Option 1: Use Discord PTB or Canary version

Option 2: Enable DevTools manually

  1. Open Console (may only work partially)
  2. Type allow pasting and press Enter
  3. This bypasses Discord's paste protection

Step 3: Run the Script

  1. Copy the entire script below
  2. Paste it into the Console
  3. Press Enter
  4. The script will start automatically
let intervalId = null;
let lastArrowTime = 0;
function getArrowKey() {
  // Find the first arrow that hasn't been pressed yet (no arrowSuccess class)
  const arrows = document.querySelectorAll('.sequences__34527 .character__34527 img:not(.arrowSuccess__34527)');
  if (arrows.length === 0) return null;
  
  const firstArrow = arrows[0];
  const alt = firstArrow.alt;
  
  if (alt === 'ArrowUp') return 'ArrowUp';
  if (alt === 'ArrowDown') return 'ArrowDown';
  if (alt === 'ArrowLeft') return 'ArrowLeft';
  if (alt === 'ArrowRight') return 'ArrowRight';
  
  return null;
}
function pressKey(key) {
  const event = new KeyboardEvent('keydown', {
    key: key,
    code: key,
    bubbles: true
  });
  document.dispatchEvent(event);
  console.log('Pressed:', key);
}
function startClicking() {
  if (intervalId) {
    console.log('Already running!');
    return;
  }
  
  intervalId = setInterval(() => {
    // Check for Continue button (after craft success)
    const continueButton = document.querySelector('.continueButtonWrapper__24749 .button__65fca');
    if (continueButton) {
      continueButton.click();
      console.log('Clicked Continue button');
      return;
    }
    
    // Check if crafting mini-game is active
    const arrowKey = getArrowKey();
    if (arrowKey) {
      const now = Date.now();
      // Wait 250ms between arrow presses
      if (now - lastArrowTime >= 250) {
        pressKey(arrowKey);
        lastArrowTime = now;
      }
      return;
    }
    
    // Check for Craft button first (not disabled)
    const craftButton = document.querySelector('.activityButton__8af73:has(img[src*="b6038208c7b31006"]) .button__65fca:not(.disabled__65fca)');
    if (craftButton) {
      craftButton.click();
      console.log('Clicked Craft button');
      return;
    }
    
    // Otherwise click Adventure
    const adventureButton = document.querySelector('.activityButton__8af73:has(img[src*="282df26638d817cd"]) .button__65fca:not(.disabled__65fca)');
    if (adventureButton) {
      adventureButton.click();
      console.log('Clicked Adventure button');
    }
  }, 100);
  
  console.log('Started clicking');
}
function stopClicking() {
  if (intervalId) {
    clearInterval(intervalId);
    intervalId = null;
    console.log('Stopped clicking');
  } else {
    console.log('Not running');
  }
}
startClicking()
// Usage:
// startClicking()  - to start
// stopClicking()   - to stop

Usage

The script starts running immediately after pasting. You can control it with these commands:

// Start the auto-clicker
startClicking()

// Stop the auto-clicker
stopClicking()

How It Works

The script runs in a loop every 100ms and checks for elements in this priority order:

  1. Continue Button - Clicks after successful crafts
  2. Arrow Sequences - Detects and presses arrow keys (250ms delay between presses)
  3. Craft Button - Clicks when enabled
  4. Adventure Button - Clicks when enabled

Arrow Key Detection

The script identifies arrow directions by checking image alt attributes:

  • ArrowUp
  • ArrowDown
  • ArrowLeft
  • ArrowRight

Only unpressed arrows (without .arrowSuccess__34527 class) are detected.

Technical Details

  • Interval: 100ms check cycle
  • Arrow Delay: 250ms between key presses
  • Event Type: Native KeyboardEvent simulation
  • Selector Strategy: Class-based targeting with specificity

Troubleshooting

Issue Solution
Console won't open Use PTB/Canary version or try Ctrl+Shift+I multiple times
"allow pasting" not working Restart Discord and try again
Script stops working Run startClicking() again in console
Buttons not clicking Discord UI may have updated - selectors need adjustment

Customization

Adjust Timing

// Change main loop speed (default: 100ms)
intervalId = setInterval(() => { ... }, 100);

// Change arrow key delay (default: 250ms)
if (now - lastArrowTime >= 250) { ... }

Add Console Logging

The script logs all actions:

  • Pressed: ArrowUp/Down/Left/Right
  • Clicked Continue button
  • Clicked Craft button
  • Clicked Adventure button

Safety Notes

  • ✅ Runs locally in your browser
  • ✅ No external connections
  • ✅ Can be stopped anytime with stopClicking()
  • ⚠️ May trigger Discord's automation detection
  • ⚠️ Use responsibly and sparingly

License

MIT License - Use at your own risk


Need help? Open an issue or check Discord's Developer Documentation for console access changes.

Releases

No releases published

Packages

 
 
 

Contributors