The VG Resource
Simplest Alarm Clock Example - Printable Version

+- The VG Resource (https://www.vg-resource.com)
+-- Forum: Archive (https://www.vg-resource.com/forum-65.html)
+--- Forum: July 2014 Archive (https://www.vg-resource.com/forum-139.html)
+---- Forum: Creative Zone (https://www.vg-resource.com/forum-86.html)
+----- Forum: Games Development (https://www.vg-resource.com/forum-22.html)
+----- Thread: Simplest Alarm Clock Example (/thread-12870.html)



Simplest Alarm Clock Example - ZeldaClassicEXPERT - 05-11-2010

Title: SimplestAlarmClockExample
Description: Need an alarm clock? Here ya all go. To all feel free to distribute and use as long as it is safe and grant anyone
permission to distribute and use as long as it is safe.
GM Version: Game Maker 8 which you may download http://www.yoyogames.com/gamemaker/try
Registered: No.
File type: .gmk
File size: When I highlight file with mouse it shows 21.3 KB but the file itself says 22 KB
File link: [Image: link.png]

Additional Info:
Permission includes editing, selling, giving away copies, audio recording with or without sound or both, video recording
with or without sound or both etc.


RE: Simplest Alarm Clock Example - Vipershark - 05-11-2010

i dont have game maker 8 and i dont want to download it
can you remake this in game maker 6 or 7 please


RE: Simplest Alarm Clock Example - Codestar - 05-11-2010

Better yet, just post the source if it's a script.


RE: Simplest Alarm Clock Example - ZeldaClassicEXPERT - 05-11-2010

(05-11-2010, 01:55 PM)Vipershark Wrote: i dont have game maker 8 and i dont want to download it
can you remake this in game maker 6 or 7 please

Merry Christmas to ya all.

Code:
[ code ] no spaces
Change object(s), variable(s), name(s) as desired or othered or both.
Or keep the same to if desired, othered, both.

Information about object: object0

Sprite: sprite1
Solid: false
Visible: true
Depth: 0
Persistent: false
Parent: <no parent>
Mask: <same as sprite>

Step Event:
for all object1: if var_alarm is equal to 15
      play sound Jessica; looping: true
D&D Drag and Drop ^

Information about object: object1

Sprite: sprite0
Solid: false
Visible: true
Depth: 0
Persistent: false
Parent: <no parent>
Mask: <same as sprite>

Create Event:
set variable var_alarm to 0
set Alarm 0 to room_speed/2

Alarm Event for alarm 0:
set Alarm 1 to room_speed/2

Alarm Event for alarm 1:
set Alarm 0 to room_speed/2
set variable var_alarm relative to +1

All D&D ^

Coding:

Information about object: object2

Sprite: sprite0
Solid: false
Visible: true
Depth: 0
Persistent: false
Parent: <no parent>
Mask: <same as sprite>

Other Event: Outside Room:
execute code:

/*
if ( object0.var_alarm == 15 )
{
  sound_play(Jessica);
}

var_alarm += 1;
alarm[0] = room_speed/2 //room_speed divided by half or 2 anyways.
This is simple use as an alarm clock each 3600 seconds equals one hours
one var_alarm = 1 second

/*

[ / code ] no spaces