and, or, nand, whatsit?
11 posts • Page 1 of 1
and, or, nand, whatsit?
when you put more than one button in a thing that gets controlled, like the activation botton on a laser, or a mirror/destroy key, and all those kind of thing, to use those in sim, you have to press all the buttons you have inputted. thats called AND. i want a laser that has 4 activation buttons, but i want it in OR, not AND, its a lot easier to handle and mannage rather than FOUR lasers with FOUR different activation buttons with the SAME scripting. what im asking is that you have a drop bar showing AND, OR, NAND, NOT, XOR, NOR, XNOR, or whatever.
-

FuzzyLogicBrain - Posts: 315
- Joined: Mon Jan 31, 2011 7:48 pm
- Location: when online, on the computer. when not, probably on it anyways. ;D lulz
Re: and, or, nand, whatsit?
Hmm. I think I support this. Maybe there should be a textbox that expands last on lasers or motors or whatever, and you can type in what you want the logic to be. For example:
so it would activate when you press A, S, and D OR Z, X, and C, but not if you press both sets at once. And they should make this accessible thru Thyme.
Yes, I support.
- Code: Select all
(A AND S AND D) XOR (Z AND X AND C)
so it would activate when you press A, S, and D OR Z, X, and C, but not if you press both sets at once. And they should make this accessible thru Thyme.
Yes, I support.
Matthias Wandel is epic, in my humble opinion.
I love my brain...
ARE YA HAPPY NOW?????
Thymechanic/Phundamentalist
Recently, I discovered something a lot of you probably already knew: Minecraft is awesome.
Due to this, I may not be as active as usual for a while.
I love my brain...
TC42 wrote:Also, your sig is too big, please change it.
ARE YA HAPPY NOW?????
Thymechanic/Phundamentalist
Recently, I discovered something a lot of you probably already knew: Minecraft is awesome.
Due to this, I may not be as active as usual for a while.
-

Someone Else - Posts: 1147
- Joined: Sun Nov 21, 2010 10:53 pm
- Location: The Milky Way Galaxy
Re: and, or, nand, whatsit?
wow, thats a big leap from my original idea. SUPPORT!!
-

FuzzyLogicBrain - Posts: 315
- Joined: Mon Jan 31, 2011 7:48 pm
- Location: when online, on the computer. when not, probably on it anyways. ;D lulz
Re: and, or, nand, whatsit?
You can simulate that by few lasers with buttons and simple script... 
Dream of Algodoo as game development engine...
-

Kilinich - [Best bug reporter 2010]
- Posts: 2098
- Joined: Mon Aug 31, 2009 8:27 pm
- Location: South Russia
Re: and, or, nand, whatsit?
Support +1
DFTBA nerdfighters
TheWonkits wrote:As immature as some of the people on this forum can be, most of you are pretty cool.
TC42 wrote:Better than spell-check... ...TC42's instant grammar-correction posts!
-

frogman786 - Posts: 71
- Joined: Fri Jan 07, 2011 8:32 am
- Location: Christchurch, New Zealand
Re: and, or, nand, whatsit?
@Kilinich- Can you make it collision-based? And phunlet-safe? And high-acceleration-proof (meaning that if you drop it off a skycraper, it won't momentarily give false output or break)? And easy to use (as in what I poster earlier, as opposed to editing scripts of several lasers)?
My guess? No. But I did just kinda spaz. Okay fine. I completely spazzed, so no offense intended. You have uploaded too much highly useful stuff for me to intend any offense.
Okay, back on topic... and I will revise my previous code to this:
The AND operator is now implied. Hmm, figuring out the Algebraic Order of Operations for this will require some fooling around in Boolean logic. Let's see... AND will be dominant over OR (which is probably what Boole said anyway), so
()
NOT
AND/NAND
OR/NOR (steps involving a non-inverse operation and an inverse operation will proceed left-to-right)
XOR/XNOR
so
So, Algodoo will perform a Boolean Test every simulation step, and turn the motor or laser or whatever on or off accordingly.
Anyway, if you hold N, O, and F, the motor or whatever will come on. Why?
Substitute 0s and 1s in place of letters. And simplify.
(0 x 1 x (0 + 0)) + (1 x 1 x (1 - 0)) + 0 = (0 x 1 x 0) + (1 x 1 x 1) + 0 = 0 + 1 + 0 = 1
And so the motor/laser/controller comes on.
Also, C syntax for the logical operators will also work: () ; ! ; && ; !& ; || ; !| and I don't know the syntax for the exclusive operands.
Wow...that is what I call a Really Long Post.
My guess? No. But I did just kinda spaz. Okay fine. I completely spazzed, so no offense intended. You have uploaded too much highly useful stuff for me to intend any offense.
Okay, back on topic... and I will revise my previous code to this:
- Code: Select all
(A S D) XOR (Z X C)
The AND operator is now implied. Hmm, figuring out the Algebraic Order of Operations for this will require some fooling around in Boolean logic. Let's see... AND will be dominant over OR (which is probably what Boole said anyway), so
()
NOT
AND/NAND
OR/NOR (steps involving a non-inverse operation and an inverse operation will proceed left-to-right)
XOR/XNOR
so
- Code: Select all
(M AND N AND (W OR T)) OR (F AND N AND (NOT W)) OR B
So, Algodoo will perform a Boolean Test every simulation step, and turn the motor or laser or whatever on or off accordingly.
Anyway, if you hold N, O, and F, the motor or whatever will come on. Why?
Substitute 0s and 1s in place of letters. And simplify.
(0 x 1 x (0 + 0)) + (1 x 1 x (1 - 0)) + 0 = (0 x 1 x 0) + (1 x 1 x 1) + 0 = 0 + 1 + 0 = 1
And so the motor/laser/controller comes on.
Also, C syntax for the logical operators will also work: () ; ! ; && ; !& ; || ; !| and I don't know the syntax for the exclusive operands.
Wow...that is what I call a Really Long Post.
Matthias Wandel is epic, in my humble opinion.
I love my brain...
ARE YA HAPPY NOW?????
Thymechanic/Phundamentalist
Recently, I discovered something a lot of you probably already knew: Minecraft is awesome.
Due to this, I may not be as active as usual for a while.
I love my brain...
TC42 wrote:Also, your sig is too big, please change it.
ARE YA HAPPY NOW?????
Thymechanic/Phundamentalist
Recently, I discovered something a lot of you probably already knew: Minecraft is awesome.
Due to this, I may not be as active as usual for a while.
-

Someone Else - Posts: 1147
- Joined: Sun Nov 21, 2010 10:53 pm
- Location: The Milky Way Galaxy
Re: and, or, nand, whatsit?
Someone Else wrote:@Kilinich- Can you make it collision-based? And phunlet-safe? And high-acceleration-proof (meaning that if you drop it off a skycraper, it won't momentarily give false output or break)?
That's Kilinich you're talking about. He can do anything, bro.
/suckup-ness
But honestly, it would be way easier if there was either menu for this, or some SIMPLIFIED way to script this.
-

TC42 - Posts: 984
- Joined: Sun Jan 09, 2011 1:53 pm
- Location: $ sudo apt get-install sandwich_
Re: and, or, nand, whatsit?
Kilinich wrote:You can simulate that by few lasers with buttons and simple script...
yeah the script isnt important. and you CAN do it with more than one laser. the idea is to AVOID that stuff, to make it simple. i know thats an old post, but ive tried to reply to that about 4 times now.
-

FuzzyLogicBrain - Posts: 315
- Joined: Mon Jan 31, 2011 7:48 pm
- Location: when online, on the computer. when not, probably on it anyways. ;D lulz
Re: and, or, nand, whatsit?
Support!
92% of teenagers have resorted to rap music. If you are part of the 8% who listens to real music, put this in your signature.
90% of teenagers today would die if Myspace/Facebook were completely destroyed. If you are one of the 10% who would be laughing their heads off, add this to your signature.
90% of teenagers today would die if Myspace/Facebook were completely destroyed. If you are one of the 10% who would be laughing their heads off, add this to your signature.
- edwardfanboy
- Posts: 10
- Joined: Sun May 29, 2011 2:49 am
Re: and, or, nand, whatsit?
The and function is already implimented i'm sure. You just push the two buttons at the same time. But an or/ andor would be good. Not is irrelevant because you can set the brake.
-

Nxdt - Posts: 1019
- Joined: Mon Aug 31, 2009 6:32 pm
- Location: Scotland!
Re: and, or, nand, whatsit?
Nxdt wrote:The and function is already implimented i'm sure. You just push the two buttons at the same time. But an or/ andor would be good. Not is irrelevant because you can set the brake.
what are you talking about dude? no one has implimented anything dude, its still a suggestion. and the "motor" thing, its for EVERYTHING that has a button that activates anything.
-

FuzzyLogicBrain - Posts: 315
- Joined: Mon Jan 31, 2011 7:48 pm
- Location: when online, on the computer. when not, probably on it anyways. ;D lulz
11 posts • Page 1 of 1
Who is online
Users browsing this forum: No registered users and 3 guests





