From 0cd03d536b5d5e162b1c43fabf758f7b6f81db07 Mon Sep 17 00:00:00 2001 From: quegzacov Date: Sat, 24 Dec 2022 18:02:18 +0100 Subject: [PATCH] 3.141592 --- index.php | 2 +- script.js | 8 +++++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/index.php b/index.php index dcb4fce..b2a0217 100755 --- a/index.php +++ b/index.php @@ -4,7 +4,7 @@ Roulette à eau - + diff --git a/script.js b/script.js index edcf62f..cdc426b 100755 --- a/script.js +++ b/script.js @@ -18,4 +18,10 @@ function draw_roulette(ctx, w, h, datalist){ ctx.closePath(); lastend += arcsector; } -} \ No newline at end of file +} + +var datalist= new Array(35, 25, 20, 12, 7, 1); +var colist = new Array('blue', 'red', 'green', 'orange', 'gray', 'yellow'); +var canvas = document.getElementById("roulette"); +var rendu = canvas.getContext('2d'); +draw_roulette(rendu, canvas.width, canvas.height, datalist);