+ Reply to Thread
Page 3 of 40
FirstFirst 1 2 3 4 5 13 ... LastLast
Results 21 to 30 of 399

Thread: Expression Gate Documentation

  1. #21
    Inactive cold12141 is on a distinguished road cold12141's Avatar
    Join Date
    Mar 2007
    Posts
    16

    Default

    Can you do group not checks? EX:
    Code:
    !(A & B & C) -> D = 1;
    

  2. #22
    Expressionism 2.0

    Syranide has disabled reputation Syranide's Avatar
    Join Date
    Mar 2007
    Location
    Sweden
    Posts
    4,180

    Default

    Can you do group not checks? EX:
    Code:
    !(A & B & C) -> D = 1;
    
    [/b]
    Yepp, you can create any kind of conditions, so that is a perfectly valid example.
    CAUTION: Just note that if you do not assign a value to D before that it will never revert to 0 (variables are kept through each execution), like so:

    Code:
    D = 0
    !(A & B & C) -> D = 1;
    
    Although that would be the same as (for 0/1):

    Code:
    D = !(A & B & C)
    

  3. #23
    Inactive Little Green Man is on a distinguished road Little Green Man's Avatar
    Join Date
    May 2007
    Posts
    32

    Default

    How dou you write the inverted sine (triganometry). is it like sin-1 or sin^-1 or what?
    "If he's dead i'm taking his spleen..."

    DON'T EAT THE CHEESECAKE!!!!
    [quote]Wire igniter? I think it'll turn to hell...[/quote]

  4. #24
    Expressionism 2.0

    Syranide has disabled reputation Syranide's Avatar
    Join Date
    Mar 2007
    Location
    Sweden
    Posts
    4,180

    Default

    How dou you write the inverted sine (triganometry). is it like sin-1 or sin^-1 or what?[/b]
    Inverse sine is called arcus sine and is defined as "asin" in the expression gate as is common.
    So asin(x)

  5. #25
    Inactive bprater is on a distinguished road bprater's Avatar
    Join Date
    May 2007
    Location
    SW Florida
    Posts
    88

    Default

    I think mod() may not be working, Google gives me: 87 mod 6 = 3. When I wire up output = mod(87,6) I get -1. BTW, the docs you wrote only has one input for mod, it should have two! BTW, was looking at your code and realized % can be used - and it works correctly.

  6. #26
    Expressionism 2.0

    Syranide has disabled reputation Syranide's Avatar
    Join Date
    Mar 2007
    Location
    Sweden
    Posts
    4,180

    Default

    I think mod() may not be working, Google gives me: 87 mod 6 = 3. When I wire up output = mod(87,6) I get -1. BTW, the docs you wrote only has one input for mod, it should have two! BTW, was looking at your code and realized % can be used - and it works correctly.[/b]
    mod(n,c) was broken earlier but has been fixed recently (a week ago or something), but forgot to fix the documentation obviously (thanks!), so if you used mod(n,c) and it didn't work (-1) then you just need to update.
    The difference between % and mod is the negative range, % discards the sign, mod keeps it.

  7. #27
    Inactive bprater is on a distinguished road bprater's Avatar
    Join Date
    May 2007
    Location
    SW Florida
    Posts
    88

    Default

    Syra -- quick question: can Lua evaluate itself, or more directly: could it be possible to program in EC with Lua? (I still understand the arguments: crashing servers, etc. but I don't know enough Lua to know if it's possible.)

  8. #28
    Expressionism 2.0

    Syranide has disabled reputation Syranide's Avatar
    Join Date
    Mar 2007
    Location
    Sweden
    Posts
    4,180

    Default

    Syra -- quick question: can Lua evaluate itself, or more directly: could it be possible to program in EC with Lua? (I still understand the arguments: crashing servers, etc. but I don't know enough Lua to know if it's possible.)[/b]
    Lua can evaluate itself, but it was removed from garrysmod because people used it highly irresponsibly... I already had plans for this as it improved the performance of more than 20x for the expression gate, but it is not possible in garrysmod.

  9. #29
    Inactive bprater is on a distinguished road bprater's Avatar
    Join Date
    May 2007
    Location
    SW Florida
    Posts
    88

    Default

    Lua can evaluate itself, but it was removed from garrysmod because people used it highly irresponsibly... I already had plans for this as it improved the performance of more than 20x for the expression gate, but it is not possible in garrysmod.[/b]
    Interesting. Maybe we need to touch base (or try) with Gary and see if it would be possible to add it back but have it only work with "signed devices". Anybody know what the best way to get Gary's attention?

  10. #30
    Wire Dev - Lazy tomb332 has a spectacular aura about tomb332 has a spectacular aura about tomb332's Avatar
    Join Date
    Mar 2007
    Location
    Birmigham,UK
    Posts
    1,294

    Default

    well if you just want attention post a thread about "i love you garry" and you will get his attention in one of 2 ways either he will.
    1. listen to you.
    or
    2. chase you with his auto-banhammer
    Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning.

    Super Easy Wire Download

+ Reply to Thread
Page 3 of 40
FirstFirst 1 2 3 4 5 13 ... LastLast

Similar Threads

  1. Documentation of hi-speed devices
    By Black Phoenix in forum CPU Tutorials & Programs
    Replies: 91
    Last Post: 11-27-2009, 07:23 AM
  2. ZGPU Documentation
    By Black Phoenix in forum CPU Tutorials & Programs
    Replies: 21
    Last Post: 10-07-2009, 01:14 PM
  3. Documentation
    By Black Phoenix in forum CPU Tutorials & Programs
    Replies: 142
    Last Post: 08-31-2009, 11:40 AM
  4. Moongate Documentation
    By BlackNecro in forum Advanced Gates
    Replies: 24
    Last Post: 04-22-2009, 12:32 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts