Click to walk, Double-click to run?

Started by Janik, Thu 02/09/2004 01:26:36

Previous topic - Next topic

Janik

Hi,

I'm fairly new to AGS (did the whole tutorial and searched the manual though), but I do know how to program.

My question is, has anyone implemented a "click once to walk, double-click to run" feature in an AGS game, and can I see the script used? The Longest Journey and Syberia have this feature, and I really like it. I think every adventure game should have it!

Thanks,

Janik
Play pen and paper D&D? Then try DM Genie - software for Dungeons and Dragons!

Dusk

#1
Quote from: Janik on Thu 02/09/2004 01:26:36

My question is, has anyone implemented a "click once to walk, double-click to run" feature in an AGS game, and can I see the script used?


This topic should put you on the right way: http://www.adventuregamestudio.co.uk/yabb/index.php?topic=12190.0

bye
D.

Janik

Hey, thanks, that look like it would work.

I used this:
http://www.digitalmindstudio.ch/script.php?id=8&lang=en

But I didn't like the delay (waiting for a double click) when you clicked the eye/hand/whatever. What I changed was that there is now only double-clicking detection when the walking icon is selected. Seems to work pretty well so far!
Play pen and paper D&D? Then try DM Genie - software for Dungeons and Dragons!

kadok

i,ve read this topic and I must ask

will I be able to make somethink like that:

>one click walk double click run
>double click on object a ladder for exaple and
  atomatically character walk up on 



sorry for may english... it's not my native language so I may make some mistake's

Goot

Yes. Use a timer and IsButtonPressed (mouse button) to see if they click twice within a certain amount of time.

Janik

Indeed. In the example code given here:

http://www.digitalmindstudio.ch/script.php?id=9&lang=en

...when a click event is recorded, a dblClick variable is either 0 or 1. So your script can record double-clicks for any clicking even, be it eyes, hand or walk.
Play pen and paper D&D? Then try DM Genie - software for Dungeons and Dragons!

SMF spam blocked by CleanTalk