Skip to content
MPGHThe Dark Arts
/
RegisterLog in
Forum
Community
What's NewLatest posts across the boardTrendingHottest threads right nowSubscribedThreads you follow
Discussion
GeneralIntroductionsEntertainmentDebate FortFlaming & Rage
Board
News & AnnouncementsMPGH TimesSuggestions & HelpGiveaways
More Sections
Art & Graphic DesignProgrammingHackingCryptocurrency
Hacks & Cheats
Games
ValorantCS2 / CS:GOCall of Duty / WarzoneFortniteApex LegendsEscape From Tarkov
+14 moreLeague of LegendsGTA VMinecraftRustROTMGBattlefieldTroveBattleOnCombat ArmsCrossFireBlackshotRuneScapeDayZDead by Daylight
Resources
Game Hacking TutorialsReverse EngineeringGeneral Game HackingAnti-CheatConsole Game Hacking
Tools
Game Hacking ToolsTrainers & CheatsHack/Release NewsNew
Submit a release →Share your cheat, tool, or config with the community.
AINEW
AI Tools
General & DiscussionPrompt EngineeringLLM JailbreaksHotAI Agents & AutomationLocal / Open Models
AI × Gaming
AI Aimbots & VisionML Anti-CheatGame Bots & Automation
Create
AI Coding / Vibe CodingAI Art & MediaAI Voice & TTS
The AI frontier →Where game hacking meets modern machine learning. Jump in.
Marketplace
Buy & Sell
SellingBuyingTradingUser Services
Trust & Safety
Middleman LoungeMarketplace TalkVouch Copy Profiles
Money
Cryptocurrency TalkCurrency ExchangeWork & Job Offers
Start selling →List accounts, services, and goods. Use the middleman to trade safe.
MPGH The Dark Arts

A community for offensive security research, reverse engineering, and AI.

Community

ForumMarketplaceSearch

Account

RegisterLog in

Legal

Privacy PolicyForum RulesHelp & FAQ
© 2026 MPGH · All rights reserved.Built by the community, for the community. For educational purposes onlyContent is shared for security research and education — we don't condone illegal use. You're responsible for complying with applicable laws. Use at your own risk.
Home › Forum › Programming › Other Programming › Web Languages › need help while creating a simple game

Unhappyneed help while creating a simple game

Posts 1–2 of 2 · Page 1 of 1
TH
thescoutoftf2
need help while creating a simple game
hello
so... this is the first time i used canvas and i really need help solving this one

this is what the game should look like :
http://imgur.com/a/G3RsB

and this is how it ended:
http://imgur.com/a/uCqlu



this is my html code:
<!DOCTYPE html>
<html>
<head>
<title>EXercice 5</title>
<meta charset="utf-8">
<script src="it.js" type="text/javascript"></script>
<link rel = "stylesheet" type = "text/css" href = "css.css" />
</head>
<body>
<p>détection du déplacement.(deplacer l'image) </p>
<h2> les billes dans les boites </h2>
<p id="info"></p>
<div id="boite1"></div>
<div id="boite2"></div>
<canvas id="billes1" width="40" height="40" draggable="true">
Texte pour les navigateur qui ne supportent pas canvas
</canvas>
<canvas id="billes2" width="40" height="40" draggable="true">
Texte pour les navigateur qui ne supportent pas canvas
</canvas>
<canvas id="billes3" width="40" height="40" draggable="true">
Texte pour les navigateur qui ne supportent pas canvas
</canvas>
<canvas id="billes4" width="40" height="40" draggable="true">
Texte pour les navigateur qui ne supportent pas canvas
</canvas>
<canvas id="billes5" width="40" height="40" draggable="true">
Texte pour les navigateur qui ne supportent pas canvas
</canvas>
</style>
<img id="image1" src="logo.png" draggable="true" ondragstart="fonction_dragstart(event)" width="100" height="100">
<p id="info"><p>
<img id="image1" src="logoo.png" draggable="true" width="100" height="100">
</body>
</html>





my javascript code:
var image = document.getElementById('image1')
image.addEventListener('dragstart',fonction_dragst art,false);
image;addEventListener('dragend',fonction_dragend, false);
function fonction_dragstart(ev){
var id = ev.target.id;
document.getElementById('info').innerHTML="deplace ment de"+id;
this.style.opacity=0.2;
this.style.borderStyle='dashed';
ev.dataTransfer.setData("Text",ev.target.id);
}
function fonction_dragend(ev){
var id = ev.target.id;
document.getElementById('info').innerHTML="fin de deplacement de"+id;
this.style.opacity=1;
this.style.borderStyle='none';
}
var cible = document.getElementById('cible')
cible.addEventListener('dragover',fonction_dragove r,false);
cible.addEventListener('drop',fonction_drop,false) ;
function fonction_dragover(ev){
ev.preventDefault();
}
function fonction_drop(ev){
var data=ev.dataTransfer.getData("Text");
ev.target.apprendChild(document.getElementById(dat a));
}





and my css


#boite1, #boite2 {
display: :inline-block;
width: 200px;height: 200px;border: 1px solid #aaaaaa;
}



been 2 weeks trying to solve this
#1 · edited 9y ago · 9y ago
HA
Hackinet
@thescoutoftf2 ,made this for you http://jsfiddle.net/Hackinet/hQTLa/40/ , hope it helps
#2 · 9y ago
Posts 1–2 of 2 · Page 1 of 1

Post a Reply

Similar Threads

  • it's not request for hack i just need help to creat an account game KRBy kazuma-san in General Game Hacking
    0Last post 13y ago
  • Need help for creating a rotmg pserv on linux.By nathan_hh in Realm of the Mad God Private Servers Help
    2Last post 11y ago
  • [help request]i need help te creat a server of a gameBy Xxbatrik in Suggestions, Requests & General Help
    0Last post 13y ago
  • Need help for creating 2d gamesBy mkn16 in Programming Tutorial Requests
    0Last post 12y ago
  • Need help learning to crack multiple games(paying)By mjrr1998 in Minecraft Help
    4Last post 13y ago

Tags for this Thread

None