[Mod] Mesecons (= redstone) [GitHub] [minetest-mod-mesecons]

ThomasMonroe
Member
 
Posts: 37
Joined: Tue Apr 04, 2017 16:21
IRC: ThomasMonroe Tre
In-game: ThomasMonroe Tre

Re: [Mod] Mesecons (= redstone) [GitHub] [minetest-mod-mesec

by ThomasMonroe » Mon Apr 10, 2017 15:29

i never thought about a switch case, *faceslap*
even though i knew it was there *another faceslap*
bit coin donations: 1BcREBJozvjYHmusGcwMu9Zt4fNLvLitHq
 

User avatar
DS-minetest
Member
 
Posts: 738
Joined: Thu Jun 19, 2014 19:49
Location: in front of my pc (which is at home)
GitHub: DS-Minetest
In-game: DS

Re: [Mod] Mesecons (= redstone) [GitHub] [minetest-mod-mesec

by DS-minetest » Mon Apr 10, 2017 15:49

Hybrid Dog wrote:You could implement switch-case in luacontroller.

AFAIK lua has no switch-case. It hasn't even labels, so it would make no sense. But you can make your own switch-case.
Do not call me -minetest.
Call me DS or DS-minetest.
I am German, so you don't have to pm me English if you are also German.
The background is a lie.
 

ThomasMonroe
Member
 
Posts: 37
Joined: Tue Apr 04, 2017 16:21
IRC: ThomasMonroe Tre
In-game: ThomasMonroe Tre

Re: [Mod] Mesecons (= redstone) [GitHub] [minetest-mod-mesec

by ThomasMonroe » Tue Apr 11, 2017 22:11

duh that why i never thought of it
bit coin donations: 1BcREBJozvjYHmusGcwMu9Zt4fNLvLitHq
 

v-rob
Member
 
Posts: 20
Joined: Thu Mar 24, 2016 03:19
Location: Where do you think I am?

Re: [Mod] Mesecons (= redstone) [GitHub] [minetest-mod-mesec

by v-rob » Sun Apr 23, 2017 00:31

I found some interesting ideas for mesecons. I know my earlier ideas were bad, but these ones, I hope, are better.

The first things would be an SCR and an SCS.

Image

The SCR (Silicon Controlled Rectifier) is like a diode, except for power to go through it, it needs a shock of power from the gate. When power goes through the gate, the gate doesn't need power anymore, and the SCR will act like a diode until the main power turns off.

The SCS (Silicon Controlled Switch) is the same, except it has another gate called the anode gate. This turns off the power in the same way as the gate turns it on.

A third gate could be made with only the anode gate and no normal gate, and power would always get through until turned off with the anode gate. As far as I know, this doesn't actually exist, so I can't show an abbreviation.

An interesting thing about these logic gates is that they can have multiple gates and anode gates.

Manually made gates
SCR: Image
SCS: Image
Nameless Gate: Image

An LED would be useful. It would be a diode and a flow sensor in one, plus the fact that it can come in many colors. A small lightbulb would be another good flow sensor, and it wouldn't have a diode built in. The main difference between these and lightstones would be that power could flow through the lightbulb and the LED as opposed to just stopping like the lightstones.

A useful thing would be a switch plant. The plant would have two ports for producing power and would act similarly to a blinky plant. It would switch from each port every three seconds. This could be made with two blinky plants, but it is extremely annoying to have to synchronize them properly. Delayers don't work for this, since they take time to turn off.

I would like a capacitor similar to this:

Image

The capacitor would be charged through one wire, and once it is charged, the light in the corner would turn green, and power could be released by turning on another wire, by clicking on it with the mouse, or automatically. I don't really know how this would be done. Different capacitors could hold different amounts of power, like one second, three seconds, five seconds, ten seconds, a minute, etc.

There are solar panels, but what if there was a lunar panel that makes electricity at night? You could make one with a solar panel and a not gate, torch, or an xor gate, but those aren't compact. A lunar panel could be red or something and crafted like this:

[--, --, --]
[solar_panel, mesecon_torch, mesecon]
[--, --, --]

A different craft could be used. That one is just a sample of what it could be.

Lastly, I would like a photoresistor. When it has light, it lets power through. When it is dark, it doesn't. Similar to the solar panel, I would like an inverted one. It could have a similar craft and be called a photoconductor.

I hope some of these things can be implemented into mesecons.
 

ABJ
Member
 
Posts: 2577
Joined: Sun Jan 18, 2015 13:02
Location: In Earth orbit, with a perigee of 1048 km and an apogee of 1337 km and an inclination of 69 degrees.
GitHub: ABJ-MV
In-game: ABJ
 

v-rob
Member
 
Posts: 20
Joined: Thu Mar 24, 2016 03:19
Location: Where do you think I am?

Re: [Mod] Mesecons (= redstone) [GitHub] [minetest-mod-mesec

by v-rob » Sun Apr 23, 2017 20:31

ABJ wrote:How about replacing logic gates with transistors?


Transistors should be made, but logic gates should still be kept. They save space.

I forgot something. There is a logic gate not included in mesecons: XNOR. The XNOR logic gate powers its output if both inputs are powered or not powered. If only one is powered, then the output is not powered. Its symbol looks like XOR, but it has a circle at the end, like the NOT gate.
 

ABJ
Member
 
Posts: 2577
Joined: Sun Jan 18, 2015 13:02
Location: In Earth orbit, with a perigee of 1048 km and an apogee of 1337 km and an inclination of 69 degrees.
GitHub: ABJ-MV
In-game: ABJ
 

User avatar
Linuxdirk
Member
 
Posts: 539
Joined: Wed Sep 17, 2014 11:21
Location: Germany
GitHub: dsohler
In-game: Linuxdirk

Re: [Mod] Mesecons (= redstone) [GitHub] [minetest-mod-mesec

by Linuxdirk » Tue Apr 25, 2017 09:41

v-rob wrote:There is a logic gate not included in mesecons: XNOR. The XNOR logic gate powers its output if both inputs are powered or not powered. If only one is powered, then the output is not powered. Its symbol looks like XOR, but it has a circle at the end, like the NOT gate.

https://en.wikipedia.org/wiki/XNOR_gate#Alternatives

:)
 

v-rob
Member
 
Posts: 20
Joined: Thu Mar 24, 2016 03:19
Location: Where do you think I am?

Re: [Mod] Mesecons (= redstone) [GitHub] [minetest-mod-mesec

by v-rob » Tue Apr 25, 2017 13:46

Oh... I never thought of that. Then again, the XNOR gate would save space, just like how the OR can be two diodes but they made a gate anyway. Interesting though. I'll keep that in mind if the XNOR isn't put in mesecons.
 

ABJ
Member
 
Posts: 2577
Joined: Sun Jan 18, 2015 13:02
Location: In Earth orbit, with a perigee of 1048 km and an apogee of 1337 km and an inclination of 69 degrees.
GitHub: ABJ-MV
In-game: ABJ
 

User avatar
Linuxdirk
Member
 
Posts: 539
Joined: Wed Sep 17, 2014 11:21
Location: Germany
GitHub: dsohler
In-game: Linuxdirk

Re: [Mod] Mesecons (= redstone) [GitHub] [minetest-mod-mesec

by Linuxdirk » Tue Apr 25, 2017 14:07

v-rob wrote:Oh... I never thought of that. Then again, the XNOR gate would save space, just like how the OR can be two diodes but they made a gate anyway. Interesting though. I'll keep that in mind if the XNOR isn't put in mesecons.

Actually you can build all logic gates using NAND gates only. So all gates except NAND gates are just space savers.

But I'm a little torn about this. Either only use the most common gates. (In the end XNOR isn't that wide spread.) Or implement XNOR (It's the only logic gate missing from the standard logic gates)
 

User avatar
DS-minetest
Member
 
Posts: 738
Joined: Thu Jun 19, 2014 19:49
Location: in front of my pc (which is at home)
GitHub: DS-Minetest
In-game: DS

Re: [Mod] Mesecons (= redstone) [GitHub] [minetest-mod-mesec

by DS-minetest » Tue Apr 25, 2017 16:36

@v-rob: We don't need a XNOR gate, just use a fpga.
Do not call me -minetest.
Call me DS or DS-minetest.
I am German, so you don't have to pm me English if you are also German.
The background is a lie.
 

v-rob
Member
 
Posts: 20
Joined: Thu Mar 24, 2016 03:19
Location: Where do you think I am?

Re: [Mod] Mesecons (= redstone) [GitHub] [minetest-mod-mesec

by v-rob » Wed Apr 26, 2017 03:01

Seeing as no one will make it, I made the XNOR gate. Anyone who wants to can just copy this into the logic gates' init.lua, or someone could actually put this into the main mod.

Code: Select all
register_gate("xnor", 2, function (val1, val2) return not (val1 or val2) or (val1 and val2) end,
   {{"mesecons:mesecon", "", ""},
    {"mesecons_materials:silicon", "mesecons:mesecon", "mesecons_torch:mesecon_torch_on"},
    {"mesecons:mesecon", "", ""}},
   "XNOR Gate")


Make a different craft if you want. I don't really care. Also, the symbol is nearly impossible with the space provided in the texture, so make your own.

I did suggest other things, so I would like your input on those, too. I can't program the transistors I had an idea for (I just guessed on the XNOR until I got lucky), and I would really like to have them, along with most of the rest of my ideas.

By the way, I made an orange and a purple lightstone. Put this at the bottom of the lightstones' init.lua if you want them.

Code: Select all
mesecon.lightstone_add("purple", "dye:violet", "jeija_lightstone_purple_off.png", "jeija_lightstone_purple_on.png")
mesecon.lightstone_add("orange", "dye:orange", "jeija_lightstone_orange_off.png", "jeija_lightstone_orange_on.png")


Full rainbow now! :)

Textures are attached.
Attachments
other_lightstones.zip
lightstone textures
(2.47 KiB) Downloaded 1 time
 

User avatar
DS-minetest
Member
 
Posts: 738
Joined: Thu Jun 19, 2014 19:49
Location: in front of my pc (which is at home)
GitHub: DS-Minetest
In-game: DS

Re: [Mod] Mesecons (= redstone) [GitHub] [minetest-mod-mesec

by DS-minetest » Wed Apr 26, 2017 12:40

@v-rob: The forum is the wrong page for this, go to the github mesecons repository.
Btw, there were already discussions for more lightstones.
Do not call me -minetest.
Call me DS or DS-minetest.
I am German, so you don't have to pm me English if you are also German.
The background is a lie.
 

User avatar
JoshMars
Member
 
Posts: 106
Joined: Sat May 17, 2014 23:24
In-game: rubber UbuntuJosh

Re: [Mod] Mesecons (= redstone) [GitHub] [minetest-mod-mesec

by JoshMars » Wed Apr 26, 2017 13:16

DS-minetest wrote:@v-rob: The forum is the wrong page for this, go to the github mesecons repository.
Btw, there were already discussions for more lightstones.


Sometimes it's nice to put little additions into the forum because they're not likely to be pulled, don't merit a whole new branch, and fit nicely here for anyone else who is interested.
 

v-rob
Member
 
Posts: 20
Joined: Thu Mar 24, 2016 03:19
Location: Where do you think I am?

Re: [Mod] Mesecons (= redstone) [GitHub] [minetest-mod-mesec

by v-rob » Wed Apr 26, 2017 22:53

Sorry if I shouldn't have done that. I just want people's input on my ideas, so I put the XNOR code there to stop the argument over it. Could some people just give me their honest opinions on my ideas? If it matters that much just for this to be on GitHub, tell me. Thanks.
 

Previous

Return to Mod Releases



Who is online

Users browsing this forum: Bing [Bot], johnapero and 8 guests