how i can create personalized deathmatch with madcommands?

I need help on how to make a deathmatch made with madcommands, without using the plugin “deathmatch” since its pvp this bug.

Create a command that sends players to waiting rooms and prevents using of some commands that lets them leave it, by putting them in a waiting room you place them in an array
Then use size(%waiters%) to see if the amount of players are enough to start a match everytime a player joins (replace %waiters% with the variable you put for players waiting)
When they are enough move them to a new array which will be called %inmatch%
Now while they are in match they will fight
The current events might happen:
1- Death
So trigger death to a command that removes them from the %ingame% array
2- Leaving the server
Trigger leave to that command aswell (or something else if it’s hard for you to make different variables work on the same command but it’s very simple because you can use the %args%[1] and if-then steps)
3- Using a command to leave the death match
Same for the two previous ones

You can also integrate it with a command that sets up scores for those players to add more fun on your server

If you need more explanation about any part of this command or need help let me know.


Btw, the song The Spectre by Alan Walker is one of my favorites ;)

My Server

If you need help goto: support.leet.cc
Or PM me here or on Discord: @Ammarking#7494
I usually reply on Thursdays.

Thanks, but could you give me an example? I would greatly appreciate it since I am new to this and I do not understand much now. Sorry for the inconvenience.

Giving you an example about this wouldn’t help much, since making a “Minigame command” or a “Death match” command requires knowledge in MadCommands
I recommend you to read the help paragraph in the command or go to bit.do/madchelp
After that it will make it alot easier to understand my reply
When you are done reading let me know
I have a proto-type command that does the same thing u r asking for, I put without explanation like I do in my tutorials, if I send it now u may not understand it so I will wait for you to finish reading then post it

My Server

If you need help goto: support.leet.cc
Or PM me here or on Discord: @Ammarking#7494
I usually reply on Thursdays.

I would like a custom DeathMatch as well

Making no sense since 2002™

IGN/Gamertag: JaxThePerson
Discord: JaxThePerson#8819

I own a server named OzoneHaven! Join it at ozonehaven.us.to: 39177.
Vote: http://bit.do/ozonevote
Forum: http://bit.do/ozoneforum
Discord: https://discord.gg/Une7Xrs

I’m still working on it, it’s not finished and it’s not guaranteed to work, but you can have it if you are eager to see it before I finish it and finish the tutorial of it.

/cmd add mg let %ps% = onlineplayers()

/cmd edit mg 9 load %minigame-waiters%
/cmd add mg if varset(%minigame-waiters%[%p%]) then goto 14
/cmd add mg let %minigame-waiters%[%p%] = 0
/cmd add mg save %minigame-waiters%
/cmd add mg load %minigame-waiters%
/cmd add mg let %waiting% = %minigame-waiters%[%p%]
/cmd add mg if %waiting% = 0 then goto 18
/cmd add mg message %p% §l§0▶ §4Error! §r§cYou are already in queue waiting for players to join a minigame! §aYou can use §f/mg leave §ato stop waiting
/cmd add mg exit
/cmd add mg load %minigame-players%
/cmd add mg if %p% notin %minigame-players% then goto 23
/cmd add mg message %p% §4Error!§r§c You are already inside a game! §aPlease wait for it to finish or use §f/mg leave
/cmd add mg message %p% §l§0▶ §r§cBut if you use that command you will not receive any points for playing §7(if you were going to in the first place)§c, it’ll be like you didn’t even join this minigame
/cmd add mg exit
/cmd add mg let %option1% = %args%[1]
/cmd add mg if varset(%option1%) then goto 27
/cmd add mg message %p% §l§0▶ §4Error! §r§cAction undefined! §aPlease use §f/mg help §ato see how to use this command
/cmd add mg exit
/cmd add mg let %option% = lowercase(%option1%)
/cmd add mg if varset(%option%) then goto 31
/cmd add mg message %p% §l§0▶ §4Error! §r§cThe action “§f%option1%§c” is not alphanumeric! §aPlease use §f/mg help§a to see how to use this command
/cmd add mg exit
/cmd add mg if %option% != “help” then goto 60
/cmd add mg message %p% §l§c-§6=§e]§dMini§9-§5Games§e[§6=§c-§r
/cmd add mg message %p% §bThis command lets you choose a Mini-Game to play, to use it you need to choose an action between the following actions:
/cmd add mg message %p% - §bHelp
/cmd add mg message %p% §l§0▶§r §bSyntax: §f/mg §bhelp
/cmd add mg message %p% §aShows this help menu
/cmd add mg message %p% §l§0▶ §2Example: §r/mg §bhelp §7will display this menu
/cmd add mg message %p% - §bList
/cmd add mg message %p% §l§0▶§r §bSyntax: §f/mg §blist
/cmd add mg message %p% §aLists Mini-Games that you can play
/cmd add mg message %p% - §bPlay §6(§bP§6)§7 or §bJoin §6(§bJ§6)
/cmd add mg message %p% §l§0▶§r §bSyntax: §f/mg §bplay §fminigame-name §eminigame-type §7, §f/mg §bp §fminigame-name §eminigame-type §7, §f/mg §bjoin §fminigame-name §eminigame-type §7or §f/mg §bj §fminigame-name §eminigame-type
/cmd add mg message %p% §aMakes you join a game
/cmd add mg message %p% §l§0▶§r §aThe §fminigame-name §acan be found in the command §bList
/cmd add mg message %p% §l§0▶§r §aThe §eminigame-type §acan be found in the command §bInfo
/cmd add mg message %p% - §bInformation §6(§bInfo §7- §bI§6)
/cmd add mg message %p% §l§0▶§r §bSyntax: §f/mg §binfo §fminigame-name
/cmd add mg message %p% §aShows information about a mini-game, its rules and how to play it
/cmd add mg exit
/cmd add mg message %p% - §bExit §6(§bE§6)§7 or §bLeave §6(§bl§6)
/cmd add mg message %p% §l§0▶§r §bSyntax: §f/mg §bexit

/cmd edit mg 59 exit
/cmd add mg if (%option% = “list”) or (%option% = “l”) then goto 70
/cmd add mg if (%option% = “join”) or (%option% = “j”) or (%option% = “play”) or (%option% = “p”) then goto 90
/cmd add mg if (%option% = “information”) or (%option% = “info”) or (%option% = “i”) then goto
/cmd add mg if (%option% = “exit”) or (%option% = “e”) or (%option% = “leave”) or (%option% = "l) then goto
/cmd add mg message %p% §l§0▶ §4Error!§r§c The action “§f%action1%§c” does not exist! §aPlease use §f/mg help§a to see vailed actions
/cmd add mg exit

/cmd edit mg 69 # §bList
/cmd add mg message %p% §l§c-§6=§e]§dMini§9-§5Games§e[§6=§c-§r
/cmd add mg message %p% §6- §l§fSpleef
/cmd add mg message %p% §6- §cMore games coming soon!
/cmd add mg exit

/cmd edit mg 89 # §bPlay
/cmd add mg let %game1% = %args%[2]
/cmd add mg if varset(%game1%) then goto 94
/cmd add mg message %p% §l§0▶ §4Error!§r §cMini Game not defined! §aPlease use §f/mg list §ato see available mini games
/cmd add mg exit
/cmd add mg let %game% = lowercase(%game1%)
/cmd add mg if varset(%game%) then goto 98
/cmd add mg message %p% §l§0▶ §4Error! §r§cThe game “§f%game1%§c” is not alphanumeric!
/cmd add mg exit
/cmd add mg if %game% = “spleef” or “s” then goto 111

/cmd edit mg 108 message %p% §l§0▶ §4Error! §r§cThe mini-game “§f%game1%§c” does not exist! §aPlease use §f/mg list §ato see available mini games
/cmd add mg exit
/cmd add mg # §fSpleef
/cmd add mg let %type1% = %args%[3]
/cmd add mg if varset(%type1%) then goto 115
/cmd add mg message %p% §l§0▶ §4Error! §cMini Game type not defined! §aPlease use §f/mg info §bminigame-name §ato list available mini game types
/cmd add mg exit
/cmd add mg let %type% = lowercase(%type1%)
/cmd add mg if varset(%type%) then goto 119
/cmd add mg message %p% §l§0▶ §4Error! §r§cThe game type “§f%type1%§c” is not alphanumeric!
/cmd add mg exit
/cmd add mg if (%type% = “1v1”) or (%type% = “1vs1”) or (%type% = “1versus1”) then goto 129
/cmd add mg if (%type% = “1v2”) or (%type% = “1vs2”) or (%type% = “1versus2”) then goto
/cmd add mg if (%type% = “2v2”) or (%type% = “2vs2”) or (%type% = “2versus2”) then goto
/cmd add mg if (%type% = “2v3”) or (%type% = “2vs3”) or (%type% = “2versus3”) then goto
/cmd add mg if (%type% = “3v3”) or (%type% = “3vs3”) or (%type% = “3versus3”) then goto
/cmd add mg if (%type% = “3v4”) or (%type% = “3vs4”) or (%type% = “3versus4”) then goto
/cmd add mg if (%type% = “4v4”) or (%type% = “4vs4”) or (%type% = “4versus4”) then goto
/cmd add mg message %p% §l§0▶ §4Error! §r§c"§f%type1%§c" is not a vailed game type! §aPlease use §f/mg info spleef §ato list available game types
/cmd add mg exit
/cmd add mg # §fSpleef §e1vs1
/cmd add mg let %maximum% = 2
/cmd add mg if varset(%minigame-players%[“Spleef1vs1”] then goto 134
/cmd add mg let %minigame-players%[“Spleef1vs1”] = “0”
/cmd add mg save %minigame-players%
/cmd add mg load %minigame-players%
/cmd add mg let %num% = size(%minigame-players%[“Spleef1vs1”]
/cmd add mg if %num% < %maximum% then goto 140
/cmd add mg message %p% §l§0▶ §4Error! §r§cThat minigame is already running! §aPlease wait for players who are playing this minigame to finish playing to be able to join this minigame
/cmd add mg message %p% §eYou can use §f/mg info minigame-name §eto see how many players playing and how much time left for it to finish in case no player won
/cmd add mg message %p% §bOr go to the Minigames room and look at the signs
/cmd add mg exit
/cmd add mg move %p% waiting_room_coordinates
/cmd add mg let %minigame-waiters%[%p%] = 1
/cmd add mg save %minigame-waiters%
/cmd add mg if %minigame-players%[“Spleef1vs1”] != 0 then goto 146
/cmd add mg let %minigame-players%[“Spleef1vs1”] = %p%
goto 148
/cmd add mg let %currentplayers% = %minigame-players%[“Spleef1vs1”]
/cmd add mg let %minigame-players%[“Spleef1vs1”] = %currentplayers% + %p%
/cmd add mg save %minigame-players
/cmd add mg let %left% = int(%maximum%) - int(%num%)
/cmd add mg if %left% = 0 then goto 153
/cmd add mg message %ps% §l§c-§6=§e]§dMini§9-§5Games§e[§6=§c-§r §e%p% §bhas joined §l§fSpleef §e1vs1§r§b and s\he’s now waiting for §f%left% §bmore player(s) to join so that the game can start!\n§l§0▶ §r§aUse §f/mg spleef 1vs1 §ato join him/her
/cmd add mg exit
/cmd add mg message %p% §l§c-§6=§e]§dMini§9-§5Games§e[§6=§c-§r §e%p% §bhas joined §l§fSpleef §e1vs1§r§b and the match is starting now!
/cmd add mg let %random-position1% = random(1, 2)
/cmd add mg let %random-position2% = random(1, 2)
/cmd add mg sleep 1
/cmd add mg if %random-position1% = %randomposition2% then goto 154

My Server

If you need help goto: support.leet.cc
Or PM me here or on Discord: @Ammarking#7494
I usually reply on Thursdays.

I just saw the post and I have understood the basics and will continue to see, but the example that you put I have understood better how it works, thank you.

Good to know :)
Np

My Server

If you need help goto: support.leet.cc
Or PM me here or on Discord: @Ammarking#7494
I usually reply on Thursdays.

Log in to reply

Looks like your connection to LEET Forums was lost, please wait while we try to reconnect.