The following warnings occurred:
Warning [2] count(): Parameter must be an array or an object that implements Countable - Line: 795 - File: showthread.php PHP 7.4.33 (FreeBSD)
File Line Function
/showthread.php 795 errorHandler->error





Post Reply 
Example: creating icon menus
01-03-2014, 10:31 PM (This post was last modified: 01-04-2014 04:55 AM by Han.)
Post: #1
Example: creating icon menus
Link to DIMGROBHELPER: DIMGROBHELPER

Code:

export iconmenu()
begin   local i,key,getmouse=1;
  local cmode,tmode,showbox;
  dimgrob_p(G4,320,70);
  dimgrob_p(G5,320,70);
  blit_p(G4,G0,0,120-35,320,120+35);
  dimgrob_p(G3,320,70,0);
  blit_p(G3,13,3,"xyicon");
  blit_p(G3,90,3,"zicon");
  blit_p(G3,167,3,"boxicon");
  blit_p(G3,244,3,"traceicon");
  for i from 1 to 35 do
    blit_p(G0,0,120-i,320,120+i,G3); 
    wait(.01);
  end;

  while getmouse do
    key:=WAIT(-1);
    if TYPE(key)==6 then
      if key(1)==3 then
        if 90<key(3) AND key(3)<150 then
          case
            if 15<key(2) AND key(2)<75 then cmode:=0; getmouse:=0; end;
            if 92<key(2) AND key(2)<152 then cmode:=1; getmouse:=0; end;
            if 169<key(2) AND key(2)<229 then showbox:=NOT showbox; getmouse:=0; end;
            if 246<key(2) AND key(2)<306 then tmode:=NOT tmode; getmouse:=0; end; 
          end;
        end;
      end;
    end;
  end;

  for i from 35 downto 1 do
    blit_p(G5,G4);
    blit_p(G5,0,35-i,320,35+i,G3);
    blit_p(G0,0,120-35,320,120+35,G5);
    wait(.01);
  end;

  blit_p(G0,0,120-35,320,120+35,G4);
  return(tmode);
end;

// icon data removed; see attached zip file below





Attached File(s)
.zip  icons.zip (Size: 28.88 KB / Downloads: 127)

Graph 3D | QPI | SolveSys
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
Example: creating icon menus - Han - 01-03-2014 10:31 PM
RE: Example: creating icon menus - Han - 01-04-2014, 04:45 AM
RE: Example: creating icon menus - Han - 01-04-2014, 03:55 PM
RE: Example: creating icon menus - Mic - 01-04-2014, 02:57 PM
RE: Example: creating icon menus - Han - 01-08-2014, 05:07 AM
RE: Example: creating icon menus - Han - 01-08-2014, 06:20 PM



User(s) browsing this thread: