Welcome to Dream.In.Code
Getting Help is Easy!

Join 132,629 Programmers for FREE! Get instant access to thousands of experts, tutorials, code snippets, and more! There are 1,031 people online right now. Registration is fast and FREE... Join Now!




PASCAL@@@

 
Reply to this topicStart new topic

PASCAL@@@

honey babee
post 20 May, 2005 - 04:10 PM
Post #1


New D.I.C Head

*
Joined: 20 May, 2005
Posts: 21

I know this is a reallllly oldd programing language, but i had to study it in school, which i hate><
But anyways how do you do a mouse control. Because we are currently doing a project that requires that.
smile.gif
User is offlineProfile CardPM

Go to the top of the page

Amadeus
post 20 May, 2005 - 08:49 PM
Post #2


g++ -o drink whiskey.cpp

Group Icon
Joined: 12 Jul, 2002
Posts: 12,176



Thanked 33 times

Dream Kudos: 25
My Contributions


Geez, its been about a million years since I've done pascal, but do you need a mouse control for text or graphic mode?
User is offlineProfile CardPM

Go to the top of the page

honey babee
post 21 May, 2005 - 04:29 PM
Post #3


New D.I.C Head

*
Joined: 20 May, 2005
Posts: 21

WOOOOW you must be old:P
lol
Well, i am doing text, and do you think you can help me if i want to insert a graphic into the program?
Or sound?
User is offlineProfile CardPM

Go to the top of the page

born2c0de
post 23 May, 2005 - 01:46 AM
Post #4


printf("I'm a %XR",195936478);

Group Icon
Joined: 26 Nov, 2004
Posts: 3,905



Thanked 34 times

Dream Kudos: 2800

Expert In: 80x86 Assembly, C/C++, VB6, VB.NET, C#, J2SE, Win32 API, Reversing

My Contributions


See if this links helps:
CLICK HERE
User is offlineProfile CardPM

Go to the top of the page

honey babee
post 23 May, 2005 - 05:55 AM
Post #5


New D.I.C Head

*
Joined: 20 May, 2005
Posts: 21

Thankies but i also need to know how to do mouse control
cool.gif
And what is a
CODE
SB VOC player


This post has been edited by honey babee: 23 May, 2005 - 05:55 AM
User is offlineProfile CardPM

Go to the top of the page

honey babee
post 6 Jun, 2005 - 04:09 PM
Post #6


New D.I.C Head

*
Joined: 20 May, 2005
Posts: 21

CODE
program wheel(input, output);
var
  c, x, y:integer;
       procedure delays;
var
  x, y:integer;
               begin
                       for x:=1 to 32000 do
                       begin
                               for y:=1 to 50 do
                       end;
               end;
       procedure help;
var
       choice:packed array[1..20]of char;

       begin
       writeln("1.First you enter a letter of your choice, if the letter is a part of the word it will be revealed, and you will get the amount of money you have spined.
                2.If the letter that you have entered is incorrect, you lose your turn.
                3.If you know the word or phrase that is being presented to you, you may choose to solve or spin. If you solved the word/phrase correctly you keep your point,
                if not you lose all your point and your turn.
                ");
       prompt("Finished? enter(y/n)",choice);
       if (choice=y) then
       menu;
       if (choice=n) then
       help;
       end;
       procedure credit;
var
       choice:pack array[1..20]of char;

       begin
       writeln("1.Code Copyright Delia Xiong and Alexis Bryan.
                2.Game copyright "Wheel of fortune" people
                3.Pascal was used in the making of this program.
                4.Thank you for taking time out to play this fabolous game.");
       prompt("Finished? enter (y/n)",choice);
       if (choice=y) then
       menu;
       if (choice=n) then
       credit;
       end;

       procedure menu;
var

       MX,MY,OldMX,OldMY:integer;
       choice:packed array[1..20]of char;
       icon= Array [1..7,1..6] of byte;

               begin

       OldMX:=GetMouseX;{iniatialy, the old position is where the new one
is}
       OldMX:=GetMouseY;
       MX:=OldMX;
       MY:=OldMY;
           writeln ("            ");
           writeln ("            ");
           writeln ("            ");
           writeln ("            ");
            writeln("
                                           ÉÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍ»");
            writeln("                      º WELCOME TO WHEEL OF FORTUNE º");
            writeln("                      ÈÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍͼ
");
           writeln ("            ");
           writeln ("            ");
           writeln ("            ");
           writeln ("            ");

               MX:=GetMouseX;
               MY:=GetMouseY;
               If LeftPressed Do
                       begin{On mouse click (left button)}
                       end;
               If MX <>OldMX or MY<>OldMY Do
                       begin{on mouse move}
                       redrawmouse;
                       end;
               OldMX:=MX;
               OldMY:=MY;
MouseIcon:icon =((0,98,98,98,98,98),
               (0,0,98,98,98,98),
               (0,31,0,98,98,98),
               (0,31,31,0,98,98),
               (0,31,31,31,0,98),
               (0,31,31,31,31,98),
               (98,0,31,31,31,0));
               writeln ("                               1 ¯ Credit ");
               writeln ("            ");
               writeln ("                               2 ¯ Start game ");
               writeln ("           ");
               writeln ("                               3 ¯ Help  ");
               writeln ("           ");
               writeln ("                               4 ¯ Exit  ");
               prompt("Please Make a choice:(1-4)", choice);
               writeln(" ");
            if (choice="1") then
               credit
             else if(choice="2") then
               start_game
             else if(choice="3") then
               help
             else if(choice="4") then
               exit
             else
               page;
               menu;
                 end;



       procedure start_game;

       begin

               end;
       procedure exit;
               begin
               end;

begin
page;
writeln(" ");
writeln(" ");
writeln(" ");
writeln(" ");
{Letter w start here}
       For c:=10 to 15 do
               begin

               poscursor(c,15);
               write("Û");
               poscursor(c,24);
               write("Û");
               end;
        For c:=13 to 14 do
               begin
               poscursor(15,16);
               write("ß");
               poscursor(15,23);
               write("ß");
               end;
        For c:=16 downto 15 do
               begin
               poscursor(14,17);
               write("Ü");
               poscursor(14,22);
               write("Ü");
               end;
        For c:=16 downto 15 do
               begin
               poscursor(14,18);
               write("ß");
               poscursor(14,21);
               write("ß");
               end;
       For c:=10 to 15 do
               begin

               poscursor(c,15);
               write("Û");
               poscursor(c,24);
               write("Û");
               end;
        For c:=16 downto 15 do
               begin
               poscursor(13,19);
               write("Ü");
               poscursor(13,20);
               write("Ü");
               end;

               delays;
       {Letter h starts}

       For c:=10 to 15 do
               begin
               poscursor(c,27);
               write("Û");
               poscursor(c,36);
               write("Û");
               end;

        For c:=16 downto 15 do
               begin
               poscursor(12,28);
               write("Ü");
               poscursor(12,29);
               write("Ü");
               poscursor(12,30);
               write("Ü");
               poscursor(12,31);
               write("Ü");
               poscursor(12,32);
               write("Ü");
               poscursor(12,33);
               write("Ü");
               poscursor(12,34);
               write("Ü");
               poscursor(12,35);
               write("Ü");
               end;
               delays;
         {Letter E starts}
       For c:=10 to 15 do
               begin
               poscursor(c,40);
               write("Û");
               end;


        For c:=10 to 15 do
               begin
               poscursor(10,41);
               write("ß");
               poscursor(10,42);
               write("ß");
               poscursor(10,43);
               write("ß");
               poscursor(10,44);
               write("ß");
               poscursor(10,45);
               write("ß");
               poscursor(10,46);
               write("ß");
               poscursor(10,47);
               write("ß");
               poscursor(12,41);
               write("Ü");
               poscursor(12,42);
               write("Ü");
               poscursor(12,43);
               write("Ü");
               poscursor(12,44);
               write("Ü");
               poscursor(12,45);
               write("Ü");
               poscursor(12,46);
               write("Ü");
               poscursor(12,47);
               write("Ü");
               poscursor(15,41);
               write("Ü");
               poscursor(15,42);
               write("Ü");
               poscursor(15,43);
               write("Ü");
               poscursor(15,44);
               write("Ü");
               poscursor(15,45);
               write("Ü");
               poscursor(15,46);
               write("Ü");
               poscursor(15,47);
               write("Ü");
               end;

               delays;
         {Letter E starts}
       For c:=10 to 15 do
               begin
               poscursor(c,50);
               write("Û");
               end;
        For c:=10 to 15 do
               begin
               poscursor(10,51);
               write("ß");
               poscursor(10,52);
               write("ß");
               poscursor(10,53);
               write("ß");
               poscursor(10,54);
               write("ß");
               poscursor(10,55);
               write("ß");
               poscursor(10,56);
               write("ß");
               poscursor(10,57);
               write("ß");
               poscursor(12,51);
               write("Ü");
               poscursor(12,52);
               write("Ü");
               poscursor(12,53);
               write("Ü");
               poscursor(12,54);
               write("Ü");
               poscursor(12,55);
               write("Ü");
               poscursor(12,56);
               write("Ü");
               poscursor(12,57);
               write("Ü");
               poscursor(15,51);
               write("Ü");
               poscursor(15,52);
               write("Ü");
               poscursor(15,53);
               write("Ü");
               poscursor(15,54);
               write("Ü");
               poscursor(15,55);
               write("Ü");
               poscursor(15,56);
               write("Ü");
               poscursor(15,57);
               write("Ü");
               end;
               delays;

         {Letter L starts}
       For c:=10 to 15 do
               begin
               poscursor(c,60);
               write("Û");
               poscursor(15,61);
               write("Ü");
               poscursor(15,62);
               write("Ü");
               poscursor(15,63);
               write("Ü");
               poscursor(15,64);
               write("Ü");
               poscursor(15,65);
               write("Ü");
               poscursor(15,66);
               write("Ü");
               poscursor(15,67);
               write("Ü");
               end;
               delays;
               delays;
               page;
         {Letter O starts}
       For c:=11 to 14 do
               begin
               poscursor(c,20);
               write("Û");
               poscursor(c,30);
               write("Û");
               poscursor(10,21);
               write("Ü");
               poscursor(10,22);
               write("Ü");
               poscursor(10,23);
               write("Ü");
               poscursor(10,24);
               write("Ü");
               poscursor(10,25);
               write("Ü");
               poscursor(10,26);
               write("Ü");
               poscursor(10,27);
               write("Ü");
               poscursor(10,28);
               write("Ü");
               poscursor(10,29);
               write("Ü");
               poscursor(15,21);
               write("ß");
               poscursor(15,22);
               write("ß");
               poscursor(15,23);
               write("ß");
               poscursor(15,24);
               write("ß");
               poscursor(15,25);
               write("ß");
               poscursor(15,26);
               write("ß");
               poscursor(15,27);
               write("ß");
               poscursor(15,28);
               write("ß");
               poscursor(15,29);
               write("ß");
               end;
               delays;

         {Letter F starts}
       For c:=10 to 15 do
               begin
               poscursor(c,35);
               write("Û");
               end;
       For c:=10 to 15 do
               begin
               poscursor(10,36);
               write("ß");
               poscursor(10,37);
               write("ß");
               poscursor(10,38);
               write("ß");
               poscursor(10,39);
               write("ß");
               poscursor(10,40);
               write("ß");
               poscursor(10,41);
               write("ß");
               poscursor(10,42);
               write("ß");
               poscursor(10,43);
               write("ß");
               poscursor(10,44);
               write("ß");
               poscursor(10,45);
               write("ß");
               poscursor(13,36);
               write("ß");
               poscursor(13,37);
               write("ß");
               poscursor(13,38);
               write("ß");
               poscursor(13,39);
               write("ß");
               poscursor(13,40);
               write("ß");
               poscursor(13,41);
               write("ß");
               poscursor(13,42);
               write("ß");
               end;
               delays;
               delays;
               page;
       {Letter F begins}
               For c:=10 to 15 do
               begin
               poscursor(c,5);
               write("Û");
               poscursor(10,6);
               write("ß");
               poscursor(10,7);
               write("ß");
               poscursor(10,8);
               write("ß");
               poscursor(10,9);
               write("ß");
               poscursor(10,10);
               write("ß");
               poscursor(10,11);
               write("ß");
               poscursor(13,6);
               write("ß");
               poscursor(13,7);
               write("ß");
               poscursor(13,8);
               write("ß");
               poscursor(13,9);
               write("ß");
               end;
               delays;
       {Letter O begin}
               For c:= 11 to 14 do
               begin
               poscursor(c,15);
               write("Û");
               poscursor(c,23);
               write("Û");
               end;
               For c:=10 to 15 do
               begin
               poscursor(10,16);
               write("Ü");
               poscursor(10,17);
               write("Ü");
               poscursor(10,18);
               write("Ü");
               poscursor(10,19);
               write("Ü");
               poscursor(10,20);
               write("Ü");
               poscursor(10,21);
               write("Ü");
               poscursor(10,22);
               write("Ü");
               poscursor(15,16);
               write("ß");
               poscursor(15,17);
               write("ß");
               poscursor(15,18);
               write("ß");
               poscursor(15,19);
               write("ß");
               poscursor(15,20);
               write("ß");
               poscursor(15,21);
               write("ß");
               poscursor(15,22);
               write("ß");
               end;
               delays;
       {Letter R begin}
               For c:=10 to 15 do
               begin
               poscursor(c,27);
               write("Û");
               end;
               For c:=28 to 34 do
               begin
               poscursor(10,c);
               write("ß");
               poscursor(12,c);
               write("Ü")
               end;
               For c:=10 to 12 do
               begin
               poscursor(c,34);
               write("Û");
               end;
               For c:=10 to 15 do
               begin
               poscursor(13,28);
               write("ß");
               poscursor(13,29);
               write("Ü");
               poscursor(14,30);
               write("ß");
               poscursor(14,31);
               write("Ü");
               poscursor(15,32);
               write("ß");
               poscursor(15,33);
               write("ß");
               poscursor(15,34);
               write("Ü");
               end;
               delays;
       {Letter T begins}
               For c:= 10 to 15 do
               begin
               poscursor(c,42);
               write("Û");
               end;
               For c:= 37 to 47 do
               begin
               poscursor(10,c);
               write("Ü");
               end;
               delays;
       {Letter U begins}
               For c:=10 to 14 do
               begin
               poscursor(c,50);
               write("Û");
               poscursor(c,58);
               write("Û");
               poscursor(15,51);
               write("ß");
               poscursor(15,52);
               write("ß");
               poscursor(15,53);
               write("ß");
               poscursor(15,54);
               write("ß");
               poscursor(15,55);
               write("ß");
               poscursor(15,56);
               write("ß");
               poscursor(15,57);
               write("ß");
               end;
               delays;
       {Letter N begins}
               For c:=10 to 14 do
               begin
               poscursor(c,62);
               write("Û");
               poscursor(c,70);
               write("Û");
               poscursor(10,63);
               write("Ü");
               poscursor(11,64);
               write("ß");
               poscursor(11,65);
               write("Ü");
               poscursor(12,66);
               write("ß");
               poscursor(12,67);
               write("Ü");
               poscursor(13,68);
               write("ß");
               poscursor(13,69);
               write("Ü");
               end;
               delays;
       {Letter E begin}
               For c:=10 to 14 do
               begin
               poscursor(c,73);
               write("Û");
               end;
               For c:=74 to 76 do
               begin
               poscursor(10,c);
               write("ß");
               poscursor(12,c);
               write("Ü");
               poscursor(15,c);
               write("ß");
               end;
               delays;
               delays;

               page;

               {Enter page}
               writeln("    ");
               writeln("    ");
               writeln("    ");
               writeln("    ");
               writeln("    ");
               writeln("    ");
               writeln("    ");
               writeln("    ");
               writeln("    ");
               writeln("    ");
       writeln("               Press enter to continue on to the menu page
please.");
       readln;
       page;
       menu;
{Spacer}
        For c:=16 downto 15 do
               begin
               poscursor(20,17);
               end;
end.

thts all my code, im not one though, but it say that byte is not defined, how would i do that? blink.gif blink.gif
User is offlineProfile CardPM

Go to the top of the page

BlueVD
post 8 Aug, 2005 - 07:51 AM
Post #7


New D.I.C Head

Group Icon
Joined: 8 Aug, 2005
Posts: 29



Thanked 1 times

Dream Kudos: 75
My Contributions


Heh, I remember my pascal programming days... biggrin.gif
I had some experience with the mouse (all nasty and ugly unfortunatley due to the lack of resources available at that time)

Because you don't use the graph unit, all you need is the mouse dos driver and the mouse unit for pascal... I've attached one of the old drivers I used...
It also works with the graph unit.

Hope you'll manage to use it.


Attached File(s)
Attached File  mousf.zip ( 4.54k ) Number of downloads: 69
User is offlineProfile CardPM

Go to the top of the page

Fast ReplyReply to this topicStart new topic
Time is now: 11/23/08 03:49AM

Live Help!

Tutorials

Programming

Web Development

Reference Sheets

Code Snippets

Bye Bye Ads

Free DIC T-Shirt

T-Shirt Example

Related Sites

Monthly Drawing

Thumb Drive

Partners

Top Contributors

Top 10 Kudos This Month