+ Reply to Thread
Page 3 of 27 FirstFirst 1234513 ... LastLast
Results 21 to 30 of 270

Thread: Wire GPU Tutorial: by Drunkie

  1. #21
    Wire Sofaking ryland's Avatar
    Join Date
    Oct 2009
    Location
    Card bord box next to wal-mart.
    Posts
    594

    Default re: Wire GPU Tutorial: by Drunkie

    Hey drunkie, this is just a request but, could you explain how to use calls with the GPU, like for example when I press a button I want to draw a square but ONLY if I press a button.
    Last edited by ryland; 11-29-2009 at 01:12 PM.
    "I like pie"-Jat Goodwin

    <Azrael-> ryland: LOL is such a noobish thing to say.
    <ryland> LOL
    <Fox682> LOLLOL
    <Fox682> LOL
    <ryland> LOL

  2. #22
    Ursus maritimus Drunkie's Avatar
    Join Date
    Feb 2009
    Location
    Canada
    Posts
    5,662
    Blog Entries
    1

    Default re: Wire GPU Tutorial: by Drunkie

    Quote Originally Posted by ryland View Post
    Hey drunkie, this is just a request but, could you explain how to use calls with the GPU, like for example when I press a button I want to draw a square but ONLY if I press a button.
    You can already learn how to use calls and jumps by referring to these other tutorials.

    The "Foxy" CPU.

    The "Foxy" CPU - Part 2

  3. #23
    That furred thing Black Phoenix's Avatar
    Join Date
    Feb 2007
    Location
    Kyiv, Ukraine
    Posts
    3,565

    Default re: Wire GPU Tutorial: by Drunkie

    Alpha works in colors. I moved it because this is where tutorials go
    I'm a wire-crazy person with a tail.

    Take a daily journey into my brain

    D2K5

  4. #24
    Ursus maritimus Drunkie's Avatar
    Join Date
    Feb 2009
    Location
    Canada
    Posts
    5,662
    Blog Entries
    1

    Default re: Wire GPU Tutorial: by Drunkie

    Ah, okay thanks
    Last edited by Drunkie; 11-29-2009 at 02:32 PM.

  5. #25
    Wire Sofaking ryland's Avatar
    Join Date
    Oct 2009
    Location
    Card bord box next to wal-mart.
    Posts
    594

    Default re: Wire GPU Tutorial: by Drunkie

    Quote Originally Posted by Drunkie View Post
    You can already learn how to use calls and jumps by referring to these other tutorials.

    The "Foxy" CPU.

    The "Foxy" CPU - Part 2
    I understand how to use calls with zASM and GPU.
    My problem is when I spawn the GPU it automatically draws a square or lags a ton.
    "I like pie"-Jat Goodwin

    <Azrael-> ryland: LOL is such a noobish thing to say.
    <ryland> LOL
    <Fox682> LOLLOL
    <Fox682> LOL
    <ryland> LOL

  6. #26
    Ursus maritimus Drunkie's Avatar
    Join Date
    Feb 2009
    Location
    Canada
    Posts
    5,662
    Blog Entries
    1

    Default re: Wire GPU Tutorial: by Drunkie

    Quote Originally Posted by ryland View Post
    I understand how to use calls with zASM and GPU.
    My problem is when I spawn the GPU it automatically draws a square or lags a ton.
    Code:
    cmp #63488,1;
    je DrawSquare;
    jne Exit;
    
    DrawSquare:
        dcolor white;
        drectwh pos,size;
    jmp Exit;
    
    Exit: dexit;
    
    color white,255,255,255;
    vec2f pos,0,0;
    vec2f size,128,128;
    In your E2 Code:

    Code:
    @inputs GPU:wirelink
    
    GPU[63488] = 1
    GPU[0] = GPU[0]

  7. #27
    Wire Sofaking ryland's Avatar
    Join Date
    Oct 2009
    Location
    Card bord box next to wal-mart.
    Posts
    594

    Default re: Wire GPU Tutorial: by Drunkie

    Quote Originally Posted by Drunkie View Post
    Code:
    cmp #63488,1;
    je DrawSquare;
    jne Exit;
    
    DrawSquare:
        dcolor white;
        drectwh pos,size;
    jmp Exit;
    
    Exit: dexit;
    
    color white,255,255,255;
    vec2f pos,0,0;
    vec2f size,128,128;
    In your E2 Code:

    Code:
    @inputs GPU:wirelink
    
    GPU[63488] = 1
    GPU[0] = GPU[0]
    Thank you, I will test that out and see if I can get it to work, I am working on a GPU casino.

    EDIT:
    It worked first time this clears up a lot of confusion, thank you.
    Now time to go make overcomplicated things.
    Last edited by ryland; 11-29-2009 at 01:45 PM.
    "I like pie"-Jat Goodwin

    <Azrael-> ryland: LOL is such a noobish thing to say.
    <ryland> LOL
    <Fox682> LOLLOL
    <Fox682> LOL
    <ryland> LOL

  8. #28
    Wire Sofaking SatansSimon's Avatar
    Join Date
    Jan 2009
    Location
    Germany
    Posts
    513

    Default re: Wire GPU Tutorial: by Drunkie

    Damn, Drunkie, thank you so much. I always thought I knew almost everything of the simple things like data types and such but I could learn even there something^^
    And the E2-connecting thing is just purely epic!!!

    Thank you again for this great tutorial. I hope this will increase the number of GPU-coders out here.

  9. #29
    Ursus maritimus Drunkie's Avatar
    Join Date
    Feb 2009
    Location
    Canada
    Posts
    5,662
    Blog Entries
    1

    Default re: Wire GPU Tutorial: by Drunkie

    Quote Originally Posted by SatansSimon View Post
    Damn, Drunkie, thank you so much. I always thought I knew almost everything of the simple things like data types and such but I could learn even there something^^
    And the E2-connecting thing is just purely epic!!!

    Thank you again for this great tutorial. I hope this will increase the number of GPU-coders out here.
    Your welcome I started to realize that this wonderful wiremod entity is not being used alot in the wiremod community, and I figured someone had to at least explain the basics.

  10. #30
    Wire Sofaking Wizard of Ass's Avatar
    Join Date
    May 2009
    Location
    Germany Bremerhaven
    Posts
    1,044

    Default re: Wire GPU Tutorial: by Drunkie

    Could you explain how to get a color into the GPU via wirelink?
    I failed at that today and i have no idea how to do that.

    E2:
    Code:
    @name 
    @inputs GPU:wirelink Keyboard
    @outputs 
    @persist String:string Color:array
    @trigger Keyboard
    
    if(first())
    {
        for(T=1,3)
        {
            GPU[T]=255
        }
    }
    if(Keyboard!=127&Keyboard!=154)
    {
        String+=toChar(Keyboard)
    }
    else
    {
        String=String:left(String:length()-1)
    }
    
    if(String:sub(1,6)=="!color"&Keyboard==13)
    {
        Color=String:explode(" ")
        GPU[1]=Color[2,string]:toNumber()
        GPU[2]=Color[3,string]:toNumber()
        GPU[3]=Color[4,string]:toNumber()
        String=""
    }
    
    GPU:writeString(63488,String)
    GPU[0]=GPU[0]
    Writing works.

    GPU:
    Code:
    dcvxpipe 3;
    
    mov color1.r,#63485;
    mov color1.g,#63486;
    mov color1.b,#63487;
    dcolor color1;
    dsetsize 16;
    dwrite pos,63488;
    
    dexit;
    
    vec2f pos,-1,-0.05;
    color color1,255,255,255;
    seriously getting serious

+ Reply to Thread
Page 3 of 27 FirstFirst 1234513 ... LastLast

LinkBacks (?)

  1. 03-02-2010, 02:10 PM
  2. 02-14-2010, 06:42 AM
  3. 02-14-2010, 04:41 AM

Similar Threads

  1. Slot Machine [GPU + E2]
    By Drunkie in forum Finished contraptions
    Replies: 69
    Last Post: 11-13-2010, 04:39 PM
  2. Drunkie's Arcade Game - Skee Ball
    By Drunkie in forum Finished contraptions
    Replies: 21
    Last Post: 11-06-2010, 07:06 PM
  3. Drunkie's Pub
    By Drunkie in forum Servers
    Replies: 339
    Last Post: 06-08-2010, 12:06 AM
  4. DrunKie's iPod custom?
    By Fear57 in forum Wiremod General Chat
    Replies: 19
    Last Post: 12-01-2009, 03:56 PM

Tags for this Thread

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
proceed-collector
proceed-collector
proceed-collector
proceed-collector
linguistic-parrots
linguistic-parrots
linguistic-parrots
linguistic-parrots