A comprehensive guide to code a multi-screen watch face with animated fading transitions and changeable colors in Watchmaker for non coders

This guide will walk you trough coding a 3 screens watch face with 4 changeable colors.

Page 1

By Frank Dufaux

To Begin The Main Script. This is the complete main script that will drive the watch face it is color coded in 4 sections. Starting at the page 3 we will go trough each sections of the script and explain in detail what they are and what they do. var_changescreen= 1 var_clrnum= 1 var_color={'0000ff','00ff00','ff0000','00ffff'} tweens.screen1= 100 tweens.screen2= 0 tweens.screen3= 0 function setclr() if var_clrnum== 4 then var_clrnum=1 else var_clrnum=var_clrnum+1 end end function chscreen() if var_changescreen== 3 then var_changescreen= 1 else var_changescreen= var_changescreen +1 end end function screenfades() if var_changescreen==1 then wm_schedule { action='tween', tween='screen3', from=100, to=0, duration=0.5, easing=linear } wm_schedule { action='tween', tween='screen1', from=0, to=100, duration=0.5, easing=linear } end if var_changescreen==2 then wm_schedule { action='tween', tween='screen1', from=100, to=0, duration=0.5, easing=linear } wm_schedule { action='tween', tween='screen2', from=0, to=100, duration=0.5, easing=linear } end if var_changescreen==3 then wm_schedule { action='tween', tween='screen2', from=100, to=0, duration=0.5, easing=linear } wm_schedule { action='tween', tween='screen3', from=0, to=100, duration=0.5, easing=linear } end end

Page 2

By Frank Dufaux

Main Script Section 1 The Variables (var) and the Tweens var_changescreen= 1 var_clrnum= 1 var_color={'0000ff','00ff00','ff0000','00ffff'} tweens.screen1= 100 tweens.screen2= 0 tweens.screen3= 0 Variables are defining the state of different element like color, rotation etc... anything you want to control trough code. The tweens are a type of variables that define the state of an animation for any elements you want to animate. var_changescreen= 1 (this is the initial state of the screen change. The var_ part is a default use to define a variable the changescreen part is compose by you and can be anything logically related to what you want to do, the = 1 part is the screen number that will be loaded by default for that variable when the watch is loaded.) var_clrnum=1 (this is the variable initial state for the color selection. The var_ part is a default use to define a variable the clrnum part is compose by you and can be anything logically related to what you want to do, the = 1 part is the color that will be loaded by default for that variable when the watch is loaded.) var_color={'0000ff','00ff00','ff0000','00ffff'} (this is the variable where you define the array-list of colors you want. The var_ part is a default use to define a variable the color part is compose by you and can be anything logically related to what you want to do, the ={'0000ff','00ff00','ff0000','00ffff'} part is the array list you create to define the colors you want the user to access.) tweens.screen1= 100 (this is the animation initial variable value for the opacity amount of screen 1. the tweens. part is a default use to define a animation variable, the screen1 part is compose by you logically related to what you want to animate, the = 100 the opacity level applied at the watch face loading.) tweens.screen2= 0 (this is the animation initial variable value for the opacity amount of screen 2. the tweens. part is a default use to define a animation variable, the screen2 part is compose by you logically related to what you want to animate, the = 0 the opacity level applied at the watch face loading.) tweens.screen3= 0 (this is the animation initial variable value for the opacity amount of screen 3. the tweens. part is a default use to define a animation variable, the screen3 part is compose by you logically related to what you want to animate, the = 0 the opacity level applied at the watch face loading.) Page 3

By Frank Dufaux

Main Script Section 2 The Color Change Function. function setclr() if var_clrnum== 4 then var_clrnum=1 else var_clrnum=var_clrnum+1 end end

Page 4

By Frank Dufaux

watchmaker LUA Explained.pdf

Loading… Page 1. Whoops! There was a problem loading more pages. Retrying... watchmaker LUA Explained.pdf. watchmaker LUA Explained.pdf. Open. Extract. Open with. Sign In. Main menu. Displaying watchmaker LUA Explained.pdf.

94KB Sizes 6 Downloads 144 Views

Recommend Documents

lua debugger.pdf
Sign in. Loading… Whoops! There was a problem loading more pages. Whoops! There was a problem previewing this document. Retrying... Download. Connect ...

HYREL 3D - WatchMaker WorkLight Flyer v2.pdf
3D Scanner. We accept wire transfers on request (must be approved). Page 2 of 2. HYREL 3D - WatchMaker WorkLight Flyer v2.pdf. HYREL 3D - WatchMaker ...

Abbott's American watchmaker and jeweler (1898).pdf
Page 3 of 393. ABBOTT'S. AMERICAN WATCHMAKER. AND JEWELER. AN ENCYCLOPEDIA. FOR THE HOROLOGIST, JEWELER, GOLD AND SILVERSMITH. CONTAINING HUNDREDS OF PRIVATE. RECEIPTS AND FORMULAS COMPILED FROM THE BEST. AND MOST RELIABLE SOURCES. COMPLETE ...

pdf-2484\audemars-piguet-master-watchmaker-since-1875-by ...
Loading… Page 1. Whoops! There was a problem loading more pages. pdf-2484\audemars-piguet-master-watchmaker-since-1875-by-francois-chaille.pdf.

Lua chin day dong.pdf
There was a problem previewing this document. Retrying... Download. Connect more apps... Try one of the apps below to open or edit this item. Lua chin day ...

Khong the bi lua doi.pdf
Sign in. Page. 1. /. 253. Loading… Page 1 of 253. Page 1 of 253. Page 2 of 253. Page 2 of 253. Page 3 of 253. Page 3 of 253. Khong the bi lua doi.pdf. Khong the bi lua doi.pdf. Open. Extract. Open with. Sign In. Main menu. Displaying Khong the bi l

Lua chin day dong.pdf
Loading… Page 1. Whoops! There was a problem loading more pages. Retrying... Lua chin day dong.pdf. Lua chin day dong.pdf. Open. Extract. Open with. Sign In. Main menu. Displaying Lua chin day dong.pdf.

Wrox Beginning Lua Programming.pdf
Page 3 of 673. 01_069172 ffirs.qxp 1/2/07 7:52 PM Page ii. Page 3 of 673. Wrox Beginning Lua Programming.pdf. Wrox Beginning Lua Programming.pdf. Open.