/melting_glass command not working

/melting_glass command not working

Postby 94ge7j998 » 12 Apr 2013, 20:51

It doesn't do anything when i try to do the command. I need it for some parkour maps.
94ge7j998
 
Posts: 64
Joined: 26 Oct 2011, 20:49

Re: /melting_glass command not working

Postby dzienny » 13 Apr 2013, 19:54

There's no melting glass command or block. I'm not even sure what do you mean by melting glass.
User avatar
dzienny
Administrator
 
Posts: 1181
Joined: 23 Jan 2011, 14:27

Re: /melting_glass command not working

Postby 94ge7j998 » 13 Apr 2013, 22:14

It's listed in /blocks
Idk if im talking about the right block or not, but Im looking for the glass block that disappears when you step on it.
94ge7j998
 
Posts: 64
Joined: 26 Oct 2011, 20:49

Re: /melting_glass command not working

Postby Alshima » 13 Apr 2013, 22:36

94ge7j998 wrote:It doesn't do anything when i try to do the command. I need it for some parkour maps.

I know this is off-topic but what does melting_glass do anyways?
Alshima
 
Posts: 160
Joined: 11 Mar 2013, 02:22
Location: Alshima Island

Re: /melting_glass command not working

Postby 94ge7j998 » 13 Apr 2013, 22:43

I'm looking for the block command where when someone steps on the glass it disappears and comes back in a few seconds.
94ge7j998
 
Posts: 64
Joined: 26 Oct 2011, 20:49

Re: /melting_glass command not working

Postby ismellike » 13 Apr 2013, 23:35

I remember always trying to use it, but I think it's just used like when the ahl touches sand, then it turns into glass.
What a beast...
User avatar
ismellike
Coder
 
Posts: 731
Joined: 31 Oct 2012, 04:04
Location: Kansas

Re: /melting_glass command not working

Postby 94ge7j998 » 14 Apr 2013, 02:20

94ge7j998 wrote:I'm looking for the block command where when someone steps on the glass it disappears and comes back in a few seconds.
94ge7j998
 
Posts: 64
Joined: 26 Oct 2011, 20:49

Re: /melting_glass command not working

Postby ismellike » 14 Apr 2013, 02:39

You can try this, just make a cmd block for it.


Instead of /melting_glass just put yellow blocks where you want the block to disappear.

The block will disappear in 1 second and reappear after 2 seconds.

You only need 1 cmd block.

Code: Select all
using System;
using System.Collections.Generic;
using System.Threading;
namespace MCDzienny
{
    public class CmdDissipate : Command
    {
        public List<Player> dissipating = new List<Player>();
        public override string name { get { return ""; } }
        public override string shortcut { get { return ""; } }
        public override string type { get { return "other"; } }
        public override bool museumUsable { get { return false; } }
        public override LevelPermission defaultRank { get { return LevelPermission.Nobody; } }

        public override void Use(Player p, string message)
        {
            if (dissipating.Contains(p))
            {
                return;
            }
            dissipating.Add(p);
            Thread dissipateThread = new Thread(new ThreadStart(delegate
            {
                while (dissipating.Contains(p))
                {
                    Thread.Sleep(500);
                    ushort x = (ushort)(p.pos[0] / 32);
                    ushort y = (ushort)(p.pos[1] / 32 - 1);
                    ushort z = (ushort)(p.pos[2] / 32);
                    if (p.level.GetTile(x, y, z) == Block.yellow)
                    {
                        Thread.Sleep(1000);
                        p.level.Blockchange(null, x, y, z, Block.air);
                        Thread.Sleep(2000);
                        p.level.Blockchange(null, x, y, z, Block.yellow);
                    }
                }
            }));
            dissipateThread.Start();
        }
        public override void Help(Player p)
        {
            Player.SendMessage(p, "/dissipate, make a cmd block for this");
        }
    }
}
What a beast...
User avatar
ismellike
Coder
 
Posts: 731
Joined: 31 Oct 2012, 04:04
Location: Kansas

Re: /melting_glass command not working

Postby 94ge7j998 » 14 Apr 2013, 04:29

Ok, so I have compiled and loaded. You said I only need one command block though? Wouldn't I place one in every spot that I wanted it to disappear?
94ge7j998
 
Posts: 64
Joined: 26 Oct 2011, 20:49

Re: /melting_glass command not working

Postby ismellike » 14 Apr 2013, 05:17

No just in a spot where everyone will pass through.
What a beast...
User avatar
ismellike
Coder
 
Posts: 731
Joined: 31 Oct 2012, 04:04
Location: Kansas

Next

Return to Help

Who is online

Users browsing this forum: No registered users and 9 guests

cron