jarjonam 5 tahun lalu
melakukan
a1afd1519d
69 mengubah file dengan 1622 tambahan dan 0 penghapusan
  1. 6 0
      .gitignore
  2. TEMPAT SAMPAH
      Clicky.apk
  3. 54 0
      dev/config.xml
  4. TEMPAT SAMPAH
      dev/icons/144.png
  5. TEMPAT SAMPAH
      dev/icons/192.png
  6. TEMPAT SAMPAH
      dev/icons/512.png
  7. TEMPAT SAMPAH
      dev/icons/72.png
  8. TEMPAT SAMPAH
      dev/icons/96.png
  9. TEMPAT SAMPAH
      dev/icons/icon.png
  10. TEMPAT SAMPAH
      dev/icons/icon.psd
  11. TEMPAT SAMPAH
      dev/icons/icon180.png
  12. TEMPAT SAMPAH
      dev/icons/icon2014.png
  13. TEMPAT SAMPAH
      dev/img/heart.png
  14. TEMPAT SAMPAH
      dev/img/heart.psd
  15. TEMPAT SAMPAH
      dev/img/like.png
  16. 100 0
      dev/index.html
  17. 798 0
      dev/logic.js
  18. TEMPAT SAMPAH
      dev/screen/splashscreen.psd
  19. TEMPAT SAMPAH
      dev/screen/splashscreen1280.png
  20. TEMPAT SAMPAH
      dev/screen/splashscreen200.png
  21. TEMPAT SAMPAH
      dev/screen/splashscreen320.png
  22. TEMPAT SAMPAH
      dev/screen/splashscreen480.png
  23. TEMPAT SAMPAH
      dev/screen/splashscreen720.png
  24. TEMPAT SAMPAH
      dev/screen/splashscreen960.png
  25. TEMPAT SAMPAH
      dev/sounds/achievement.mp3
  26. TEMPAT SAMPAH
      dev/sounds/chime.wav
  27. TEMPAT SAMPAH
      dev/sounds/coin.wav
  28. TEMPAT SAMPAH
      dev/sounds/error.mp3
  29. TEMPAT SAMPAH
      dev/sounds/error.wav
  30. TEMPAT SAMPAH
      dev/sounds/lose.mp3
  31. TEMPAT SAMPAH
      dev/sounds/lose.wav
  32. TEMPAT SAMPAH
      dev/sounds/oldtap.ogg
  33. TEMPAT SAMPAH
      dev/sounds/purchase.mp3
  34. TEMPAT SAMPAH
      dev/sounds/purchase.wav
  35. TEMPAT SAMPAH
      dev/sounds/tap.aac
  36. 27 0
      dev/sounds/tap.aup
  37. TEMPAT SAMPAH
      dev/sounds/tap.mp3
  38. TEMPAT SAMPAH
      dev/sounds/tap.ogg
  39. TEMPAT SAMPAH
      dev/sounds/tap.wav
  40. TEMPAT SAMPAH
      dev/sounds/tap2.mp3
  41. TEMPAT SAMPAH
      dev/sounds/tap2.ogg
  42. TEMPAT SAMPAH
      dev/sounds/tap_data/e00/d00/e000041d.au
  43. TEMPAT SAMPAH
      dev/sounds/tap_data/e00/d00/e000064f.au
  44. TEMPAT SAMPAH
      dev/store/graphic.png
  45. TEMPAT SAMPAH
      dev/store/graphic.psd
  46. TEMPAT SAMPAH
      dev/store/screenshots/Screenshot_2017-06-16-19-56-43.png
  47. TEMPAT SAMPAH
      dev/store/screenshots/Screenshot_2017-06-16-19-57-01.png
  48. TEMPAT SAMPAH
      dev/store/screenshots/Screenshot_2017-06-21-14-47-47.png
  49. TEMPAT SAMPAH
      dev/store/screenshots/Screenshot_2017-06-21-14-48-44.png
  50. TEMPAT SAMPAH
      dev/store/screenshots/greencropped.png
  51. TEMPAT SAMPAH
      dev/store/screenshots/screenshotcropped.png
  52. 486 0
      dev/style.css
  53. 54 0
      dist/config.xml
  54. TEMPAT SAMPAH
      dist/icons/144.png
  55. TEMPAT SAMPAH
      dist/icons/192.png
  56. TEMPAT SAMPAH
      dist/icons/512.png
  57. TEMPAT SAMPAH
      dist/icons/72.png
  58. TEMPAT SAMPAH
      dist/icons/96.png
  59. TEMPAT SAMPAH
      dist/img/heart.png
  60. TEMPAT SAMPAH
      dist/img/heart.psd
  61. TEMPAT SAMPAH
      dist/img/like.png
  62. 95 0
      dist/index.html
  63. 1 0
      dist/logic.js
  64. TEMPAT SAMPAH
      dist/sounds/achievement.mp3
  65. TEMPAT SAMPAH
      dist/sounds/error.mp3
  66. TEMPAT SAMPAH
      dist/sounds/purchase.mp3
  67. TEMPAT SAMPAH
      dist/sounds/tap.ogg
  68. TEMPAT SAMPAH
      dist/sounds/tap2.ogg
  69. 1 0
      dist/style.css

+ 6 - 0
.gitignore

@@ -0,0 +1,6 @@
+.DS_Store/
+server.js
+clicky.keystore
+clicky release.zip
+package.json
+

TEMPAT SAMPAH
Clicky.apk


+ 54 - 0
dev/config.xml

@@ -0,0 +1,54 @@
+<?xml version="1.0" encoding="UTF-8"?>
+	<widget xmlns = "http://www.w3.org/ns/widgets"
+		xmlns:gap = "http://phonegap.com/ns/1.0"
+		xmlns:android = "http://schemas.android.com/apk/res/android"
+		id        = "com.clicky.clicky"
+		versionCode="100010"
+		version   = "">
+		<name>Clicky		</name>
+		<description>		</description>
+		<author href="" email="">		</author>
+
+		<platform name="ios">
+            <icon src="clicky/icons/144.png" width="144" height="144" />
+            <icon src="clicky/icons/72.png" width="72" height="72" />
+		</platform>
+		<platform name="android">
+            <config-file target="AndroidManifest.xml" parent="/manifest">
+            </config-file>
+            <icon src="clicky/icons/72.png" qualifier="hdpi" />
+            <icon src="clicky/icons/96.png" qualifier="xhdpi" />
+            <icon src="clicky/icons/144.png" qualifier="xxhdpi" />
+            <icon src="clicky/icons/192.png" qualifier="xxxhdpi" />
+		</platform>
+		<platform name="winphone">
+		</platform>
+		 <icon src="icon.png" />
+        <preference name="android-minSdkVersion" value="15" />
+        <preference name="orientation" value="portrait" />
+        <preference name="AndroidLaunchMode" value="singleTop" />
+        <preference name="permissions" value="none" />
+        <gap:config-file platform="android" parent="/manifest/application">
+            <activity android:launchMode="singleTop" />
+        </gap:config-file>
+        <preference name="android-build-tool" value="gradle" /> 
+        <plugin name="cordova-plugin-facebook4" source="npm" spec="~1.9.0">
+            <param name="APP_ID" value="1713477538946821" />
+            <param name="APP_NAME" value="Clicky" />
+        </plugin>
+        <!--<gap:plugin name="com.phonegap.plugins.facebookconnect" spec="0.8.0">
+            <param name="APP_ID" value="1713477538946821" />
+            <param name="APP_NAME" value="Clicky" />
+        </gap:plugin>-->
+        
+        <gap:plugin name="cc.fovea.cordova.purchase" source="npm" version="6.0.0">
+           <param name="BILLING_KEY" value="MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAkUPUuXRMsIjAA8MB6zXtA+Ry+cfbF08/ZxNiHq/L0bul1Uq8sxVuXRZB55NGM7VwWNeazuMS7+0NX5xVAOYvuZ+j040r5K2t9FE15g8frQe16Ezw1zMhqsAB3jxhY2pCkt1vCGfNbsT5S5+hrAs9X2gDqNHDNdEO2NFSA9+L7nwD9x/15UOp6x3r+suIPgwkbd5V3dFIneZhVPoUlCS8xM67qom//yMPCLCdLNOHYq35LRo4nRdhX3iJjHKJEogOgK8QH8GooIbW/r70f79IONu4wAc2E+74BgkiVs29zwwR6AUFRVPoclD11FBwgdLQN7Z8gxg3iLyKH9nD42s0DwIDAQAB"/>
+        </gap:plugin>
+        <plugin name="org.apache.cordova.media" source="npm" />
+        <plugin name="org.apache.cordova.dialogs" source="npm" />
+        <framework src="com.google.android.gms:play-services-ads:+" />
+
+        <!--<gap:plugin name="phonegap-admob" source="npm"/>-->
+        <gap:plugin name="cordova-plugin-admobpro" source="npm" />
+        <gap:plugin name="cordova-plugin-globalization" source="npm" />
+</widget>

TEMPAT SAMPAH
dev/icons/144.png


TEMPAT SAMPAH
dev/icons/192.png


TEMPAT SAMPAH
dev/icons/512.png


TEMPAT SAMPAH
dev/icons/72.png


TEMPAT SAMPAH
dev/icons/96.png


TEMPAT SAMPAH
dev/icons/icon.png


TEMPAT SAMPAH
dev/icons/icon.psd


TEMPAT SAMPAH
dev/icons/icon180.png


TEMPAT SAMPAH
dev/icons/icon2014.png


TEMPAT SAMPAH
dev/img/heart.png


TEMPAT SAMPAH
dev/img/heart.psd


TEMPAT SAMPAH
dev/img/like.png


+ 100 - 0
dev/index.html

@@ -0,0 +1,100 @@
+<html>
+<head>
+    <script type="text/javascript" src="cordova.js"></script>
+    <script type="text/javascript" src="logic.js" charset="UTF-8"></script>
+    <link rel="stylesheet" type="text/css" href="style.css">
+</head>
+<body class="splash">
+    <div id="lives">
+        <div id="livesCounter">3</div>
+        <div id="livesIcon"></div>
+    </div>
+    <div id="clicker" class="button round-button blue">
+        <div class="round-button-inside">
+            <a id="textlabel">Click?</a>
+    </div></div>
+    
+    <div class="overlay" id="loserOverlay">
+        <div class="overlayText" id="loserText">
+            <div id="heartRespawn"></div>
+            <!--<img id="heartRespawn" src="img/heart.png">-->
+            <div id="loseReason">You lost!</div>
+            <div id="loserScore">You scored <a>0</a> points</div>
+            <div id="heartExplanation" style="font-size: 0.4em; margin-top: 40px; color:rgba(200,200,200,0.8); transition: color 0.4s; -webkit-transition: color 0.4s;">(Tap heart to continue this game)</div>
+            <div id="newScore" class="normalScore">Share highscore!</div>
+            <div id="highscoreText">Highscore: <span>0</span> points</div>
+        </div>
+        <div class="overlayText" id="loserGoToMenu">Menu</div>
+    </div>
+    <div class="overlay"  id="menuOverlay">
+        <div id="menuText">
+            <div id="playButton" style="font-size: 2.2em">Play</div>
+            <div id="shareButton" style="margin-top:20px">Share</div>
+            <div id="storeButton" style="margin-top:15px">Store</div>
+            <!--<div id="highscoreButton" style="margin-top:15px">Highscores</div>-->
+            <div id="settingsButton" style="margin-top:15px">Settings</div>
+        </div>
+    </div>
+    <div class="overlay"  id="storeOverlay">
+        <div id="storeListing">
+            <div class="storeButton" id="freelife" style="margin-top:8px">
+                <div class="title">1 free life!</div>
+                <!--<img src="img/heart.png" width="25px" style="display:inline">-->
+                <div class="price" style="display:inline"><span id="watchVideo">Watch video</span> <span id="videoCountdown">(60s)</span></div>
+            </div>
+            <div class="storeButton" id="buy20lives" style="margin-top:8px">
+                <div class="title">Loading...</div>
+                <img src="img/heart.png" width="20px" style="display:inline">
+                <div class="price" style="display:inline">...</div>
+            </div>
+            <div class="storeButton" id="buy50lives" style="margin-top:8px">
+                <div class="title">Loading...</div>
+                <img src="img/heart.png" width="20px" style="display:inline">
+                <img src="img/heart.png" width="20px" style="display:inline">
+                <div class="price" style="display:inline">...</div>
+            </div>
+            <div class="storeButton" id="buy200lives" style="margin-top:8px">
+                <div class="title">Loading...</div>
+                <img src="img/heart.png" width="20px" style="display:inline">
+                <img src="img/heart.png" width="20px" style="display:inline">
+                <img src="img/heart.png" width="20px" style="display:inline">
+                <div class="price" style="display:inline">...</div>
+            </div>
+            <div class="storeButton" id="removeads" style="margin-top:8px">
+                <div class="title">Loading...</div>
+                <div class="price" style="display:inline">...</div>
+            </div>
+        </div>
+        <div class="overlayText" id="storeGoToMenu">Menu</div>
+        <div class="overlayText" id="storeGoToGame">Back</div>
+        <div class="overlayText" id="storeGoToLoser">Back</div>
+    </div>
+    <div class="overlay"  id="settingsOverlay">
+        <div id="settingsText">
+            <div class="" id="soundButton" style="margin-top:40px">&nbsp Sound &nbsp</div>
+            <div class="" id="creditsButton" style="margin-top:40px">Credits</div>
+        </div>
+        <div class="overlayText" id="settingsGoToMenu">Menu</div>
+    </div>
+    <div class="overlay"  id="creditsOverlay">
+        <div id="creditsText">
+        <div>This game wouldn't have been possible without:</div>
+        </br>
+        <div><u>Icons</u></div>
+            <div>Hand icon made by <a href="http://www.freepik.com/">Freepik</a> from <a href="http://www.flaticon.com">www.flaticon.com</a></div>
+            <div>Heart icon made by <a href="http://www.flaticon.com/authors/madebyoliver">Freepik</a> from <a href="http://www.flaticon.com">www.flaticon.com</a></div>
+        </br>
+        <div><u>Sounds</u></div>
+            <div>Tap sound made by <a href="https://www.freesound.org/people/jcallison/">jcallison</a> from <a href="https://www.freesound.org">www.freesound.org</a></div>
+            <div>Achievement sound made by <a href="shinephoenixstormcrow">shinephoenixstormcrow</a> from <a href="https://www.freesound.org">www.freesound.org</a></div>
+            <div>Buying sound made by <a href="https://www.freesound.org/people/rhodesmas/">rhodesmas</a> from <a href="https://www.freesound.org">www.freesound.org</a></div>
+            <div>Lose sound made by <a href="https://www.freesound.org/people/original_sound/">original_sound</a> from <a href="https://www.freesound.org">www.freesound.org</a></div>
+        </div>
+    </div>
+    <div id="splashScreen">
+        <img src="icons/512.png">
+    </div>  
+    <div id="message">20 points!</div>
+    
+</body>
+</html>

+ 798 - 0
dev/logic.js

@@ -0,0 +1,798 @@
+
+// Objects
+var clicker;
+var text;
+var loserOverlay;
+var menuOverlay;
+var heartRespawn;
+var livesCounter;
+var settingsOverlay;
+var storeOverlay;
+var admobid = {};
+var lang = 'en';
+var blueInRow = 1;
+// Sounds
+var tapSound;
+var tapSound2;
+var achievementSound;
+var errorSound;
+var purchaseSound;
+
+// State
+var playing = false;
+var lastClickTime;
+var lostTime;
+var canRespawn = true;
+var score = 0;
+var colour = 0; //0 - blue, 1 - red, 2 - green
+var heartClippingY = 0;
+var numberOfGames = 0;
+
+
+// Translations
+var langStrs = {
+    "en":{
+        "playButton": "Play",
+        "shareButton":"Share",
+        "storeButton":"Store",
+        "settingsButton":"Settings",
+        "freeLife":"1 free life!",
+        "watchVideo":"Watch video",
+        "loading":"Loading...",
+        "textlabel":"Click?",
+        "loseReason":"You lost!",
+        "loserScore":"You scored <a>0</a> points",
+        "heartExplanation":"(Tap heart to continue this game)",
+        "shareHighscore":"Share highscore!",
+        "shareScore":"Share score",
+        "goToMenu":"Menu",
+        "goBack":"Back",
+        "soundButton":"&nbsp Sound &nbsp",
+        "buy":"Buy ",
+        "highscore":"New highscore!",
+        "points":" points!",
+        "notRed":"Not red!",
+        "tooSlow":"Too slow!",
+        "removeAds":"Remove ads in the store!",
+        "description":"Just press the button",
+        "shareTitle":"New Clicky score!",
+        "shareDescription1":"I got ",
+        "shareDescription2":" points in Clicky! How many can you get?",
+        "highscoreText":"Highscore: <span>0</span> points",
+        "credits":"Credits"
+    },
+    "fr":{
+        "playButton": "Jouer",
+        "shareButton":"Partager",
+        "storeButton":"Magasin",
+        "settingsButton":"Options",
+        "freeLife":"1 vie gratuite!",
+        "watchVideo":"Regarder la vidéo",
+        "loading":"Chargement...",
+        "textlabel":"Cliquez",
+        "loseReason":"Vous avez perdu!",
+        "loserScore":"Vous avez obtenu <a>0</a> points",
+        "heartExplanation":"(Appuyez sur le coeur pour continuer)",
+        "shareHighscore":"Partagez highscore!",
+        "shareScore":"Partagez score",
+        "goToMenu":"Menu",
+        "goBack":"Retour",
+        "soundButton":"&nbsp Son &nbsp",
+        "buy":"Acheter ",
+        "highscore":"Nouveau highscore!",
+        "points":" points!",
+        "notRed":"Pas rouge!",
+        "tooSlow":"Trop lent!",
+        "removeAds":"Enlevez les pubs au magasin!",
+        "description":"Appuyez sur le bouton",
+        "shareTitle":"Nouveau score Clicky!",
+        "shareDescription1":"J'ai eu ",
+        "shareDescription2":" points sur Clicky! Peux-tu faire mieux?",
+        "highscoreText":"Highscore: <span>0</span> points",
+        "credits":"Infos"
+    },
+    "es":{
+        "playButton": "Jugar",
+        "shareButton":"Compartir",
+        "storeButton":"Tienda",
+        "settingsButton":"Ajustes",
+        "freeLife":"¡1 vida gratis!",
+        "watchVideo":"Ve el vídeo",
+        "loading":"Cargando...",
+        "textlabel":"Click?",
+        "loseReason":"Perdiste",
+        "loserScore":"Has obtenido <a>0</a> puntos",
+        "heartExplanation":"(Pulsa el corazón para continuar)",
+        "shareHighscore":"¡Compartir récord!",
+        "shareScore":"Compartir puntuación",
+        "goToMenu":"Menú",
+        "goBack":"Atrás",
+        "soundButton":"&nbsp Sonido &nbsp",
+        "buy":"Comprar ",
+        "highscore":"¡Nuevo récord!",
+        "points":" puntos",
+        "notRed":"¡Rojo no!",
+        "tooSlow":"¡Muy lento!",
+        "removeAds":"¡Quita los anuncios en la tienda!",
+        "description":"Pulsa el botón",
+        "shareTitle":"¡Nuevo resultado en Clicky!",
+        "shareDescription1":"¡He sacado ",
+        "shareDescription2":" puntos en Clicky! ¿Puedes superarlo?",
+        "highscoreText":"Récord: <span>0</span> puntos",
+        "credits":"Créditos"
+    }
+}
+
+//Ads
+/*var isPendingInterstitial = false;
+var isAutoshowInterstitial = false;
+
+function prepareInterstitialAd() {
+    if (!isPendingInterstitial) { // We won't ask for another interstitial ad if we already have an available one
+        admob.requestInterstitialAd({
+            autoShowInterstitial: isAutoshowInterstitial
+        });
+    }
+}
+function onAdLoadedEvent(e) {
+    if (e.adType === admob.AD_TYPE.INTERSTITIAL && !isAutoshowInterstitial) {
+        isPendingInterstitial = true;
+    }
+}
+function showInterstitialAd() {
+    if (isPendingInterstitial) {
+        admob.showInterstitialAd(function () {
+                isPendingInterstitial = false;
+                isAutoshowInterstitial = false;
+                prepareInterstitialAd();
+        });
+    } else {
+        // The interstitial is not prepared, so in this case, we want to show the interstitial as soon as possible
+        isAutoshowInterstitial = true;
+        admob.requestInterstitialAd({
+            autoShowInterstitial: isAutoshowInterstitial
+        });
+    }
+}*/
+
+document.addEventListener("deviceready", onReady, false);
+
+// Load
+
+function load(){
+    // Internationalization
+    document.getElementById('playButton').innerHTML = langStrs[lang]["playButton"]
+    document.getElementById('shareButton').innerHTML = langStrs[lang]["shareButton"]
+    document.getElementById('storeButton').innerHTML = langStrs[lang]["storeButton"]
+    document.getElementById('settingsButton').innerHTML = langStrs[lang]["settingsButton"]
+    var loadingTitles = document.querySelectorAll('#storeOverlay .title')
+    for(var i = 0; i < loadingTitles.length; i++){
+        loadingTitles[i].innerHTML = langStrs[lang]["loading"]
+    }
+    document.querySelector('#freeLife .title').innerHTML = langStrs[lang]["freeLife"]
+    document.getElementById('watchVideo').innerHTML = langStrs[lang]["watchVideo"]
+    document.getElementById('textlabel').innerHTML = langStrs[lang]["textlabel"]
+    document.getElementById('loseReason').innerHTML = langStrs[lang]["loseReason"]
+    document.getElementById('loserScore').innerHTML = langStrs[lang]["loserScore"]
+    document.getElementById('heartExplanation').innerHTML = langStrs[lang]["heartExplanation"]
+    document.getElementById('newScore').innerHTML = langStrs[lang]["newScore"]
+    document.getElementById('loserGoToMenu').innerHTML = langStrs[lang]["goToMenu"]
+    document.getElementById('storeGoToMenu').innerHTML = langStrs[lang]["goToMenu"]
+    document.getElementById('settingsGoToMenu').innerHTML = langStrs[lang]["goToMenu"]
+    document.getElementById('storeGoToGame').innerHTML = langStrs[lang]["goBack"]
+    document.getElementById('storeGoToLoser').innerHTML = langStrs[lang]["goBack"]
+    document.getElementById('soundButton').innerHTML = langStrs[lang]["soundButton"]
+    document.getElementById('highscoreText').innerHTML = langStrs[lang]["highscoreText"]
+    document.getElementById('creditsButton').innerHTML = langStrs[lang]["credits"]
+    // Game
+    if(localStorage["lives"] == undefined){
+        localStorage["lives"] = 3 //3 lives to start with
+    }
+    if(localStorage["sound"] == undefined){
+        localStorage["sound"] = "true";   
+    }
+    if(localStorage["showAds"] == undefined){
+        localStorage["showAds"] = "true";   
+    }
+    if(localStorage["highscore"] == undefined){
+        localStorage["highscore"] = "0";   
+    }
+    livesCounter = document.getElementById('lives')
+    livesCounter.querySelector('#livesCounter').innerHTML = localStorage["lives"]
+    clicker = document.getElementById('clicker');
+    text = document.getElementById('textlabel');
+    loserOverlay = document.getElementById('loserOverlay')
+    menuOverlay = document.getElementById('menuOverlay')
+    heartRespawn = document.getElementById('heartRespawn')
+    settingsOverlay = document.getElementById('settingsOverlay')
+    storeOverlay = document.getElementById('storeOverlay')
+    try{
+        document.createEvent("TouchEvent")
+        clicker.addEventListener('touchstart',click,false) 
+        loserOverlay.addEventListener('touchstart',restart,false)
+        loserOverlay.querySelector("#loserGoToMenu").addEventListener('touchstart',menu,true)
+        menuOverlay.querySelector('#playButton').addEventListener('touchstart',restart,false)
+        menuOverlay.querySelector('#storeButton').addEventListener('touchstart',goToStore,false)
+       'buy' //menuOverlay.querySelector('#highscoreButton').addEventListener('touchstart',goToHighscores,false)
+        menuOverlay.querySelector('#settingsButton').addEventListener('touchstart',goToSettings,false)
+        document.getElementById('shareButton').addEventListener('touchstart',share,false)
+        heartRespawn.addEventListener('touchstart',respawn,false)
+        livesCounter.addEventListener('touchstart',goToStore,false)
+        settingsOverlay.querySelector('#soundButton').addEventListener('touchstart',toggleSound,false)
+        settingsOverlay.querySelector('#settingsGoToMenu').addEventListener('touchstart',menu,false)
+        storeOverlay.querySelector('#storeGoToMenu').addEventListener('touchstart',menu,false)
+        storeOverlay.querySelector('#storeGoToGame').addEventListener('touchstart',continueGame,false)
+        storeOverlay.querySelector('#storeGoToLoser').addEventListener('touchstart',goToLoser,false)
+        document.getElementById('newScore').addEventListener('touchstart',shareScore,false)
+        document.getElementById('creditsButton').addEventListener('touchstart',openCredits,false)
+        document.getElementById('creditsOverlay').addEventListener('touchstart',closeCredits,false)
+        var freelife = document.getElementById('freelife').addEventListener('touchstart',function(){
+            if(videoTimeLeft <= 0){
+                AdMob.showRewardVideoAd();
+                videoTimeLeft = 90
+                videoRewardCountdown()
+                setTimeout(function(){
+                    AdMob.prepareRewardVideoAd({adId:"ca-app-pub-5926997736584944/8707157712", autoShow:false, isTesting: false})
+                }, 1000)
+            }
+        },false)
+        document.addEventListener('onAdPresent', 
+            function(data){ 
+                if(data.adType == 'rewardvideo') { 
+                    //alert( data.rewardType ); 
+                    //alert( data.rewardAmount ); 
+                    localStorage["lives"] = parseInt(localStorage["lives"]) + 1
+                    livesCounter.querySelector('#livesCounter').innerHTML = localStorage["lives"]
+                } 
+            });
+    }
+    catch (e){
+        clicker.addEventListener('mousedown',click,false) 
+        loserOverlay.addEventListener('mousedown',restart,false)
+        loserOverlay.querySelector("#loserGoToMenu").addEventListener('mousedown',menu,true)
+        menuOverlay.querySelector('#playButton').addEventListener('mousedown',restart,false)
+        //menuOverlay.querySelector('#highscoreButton').addEventListener('mousedown',goToHighscores,false)
+        menuOverlay.querySelector('#settingsButton').addEventListener('mousedown',goToSettings,false)
+        menuOverlay.querySelector('#storeButton').addEventListener('mousedown',goToStore,false)
+        document.getElementById('shareButton').addEventListener('mousedown',share,false)
+        heartRespawn.addEventListener('mousedown',respawn,false)
+        livesCounter.addEventListener('mousedown',goToStore,false)
+        settingsOverlay.querySelector('#soundButton').addEventListener('mousedown',toggleSound,false)
+        settingsOverlay.querySelector('#settingsGoToMenu').addEventListener('mousedown',menu,false)
+        storeOverlay.querySelector('#storeGoToMenu').addEventListener('mousedown',menu,false)
+        storeOverlay.querySelector('#storeGoToGame').addEventListener('mousedown',continueGame,false)
+        storeOverlay.querySelector('#storeGoToLoser').addEventListener('mousedown',goToLoser,false)
+        document.getElementById('newScore').addEventListener('mousedown',shareScore,false)
+        document.getElementById('creditsButton').addEventListener('mousedown',openCredits,false)
+        document.getElementById('creditsOverlay').addEventListener('mousedown',closeCredits,false)
+    }
+}
+
+function onReady(){
+    // Let's try to contact the store
+    try{
+        store.register({
+          id: "20lives",
+          alias: "20 lives",
+          type: store.CONSUMABLE
+        });
+        store.register({
+          id: "50lives",
+          alias: "50 lives",
+          type: store.CONSUMABLE
+        });
+        store.register({
+          id: "200lives",
+          alias: "200 lives",
+          type: store.CONSUMABLE
+        });
+        store.register({
+          id: "removeads",
+          alias: "Remove ads",
+          type: store.NON_CONSUMABLE
+        });
+        store.when("20lives").updated(refreshStore);
+        store.when("50lives").updated(refreshStore);
+        store.when("200lives").updated(refreshStore);
+        store.when("removeads").updated(refreshStore);
+        store.when("20lives").approved(function(product) {
+            localStorage["lives"] = parseInt(localStorage["lives"]) + 20
+            document.getElementById('livesCounter').innerHTML = localStorage["lives"]
+            product.finish();
+            playSound("purchase")
+        });
+        store.when("50lives").approved(function(product) {
+            localStorage["lives"] = parseInt(localStorage["lives"]) + 50
+            document.getElementById('livesCounter').innerHTML = localStorage["lives"]
+            product.finish();
+            playSound("purchase")
+        });
+        store.when("200lives").approved(function(product) {
+            localStorage["lives"] = parseInt(localStorage["lives"]) + 200
+            document.getElementById('livesCounter').innerHTML = localStorage["lives"]
+            product.finish();
+            playSound("purchase")
+        });
+        store.when("removeads").approved(function(product) {
+            localStorage["showAds"] = "false"
+            product.finish();
+            try{
+                AdMob.hideBanner();
+                AdMob.removeBanner();
+            }
+            catch(e){}
+            playSound("purchase")
+        });
+        store.refresh();
+    }
+    catch(e){}
+    // Sounds
+    try{
+        tapSound = new Media("file:///android_asset/www/sounds/tap.ogg");
+        tapSound2 = new Media("file:///android_asset/www/sounds/tap2.ogg");
+        achievementSound = new Media("file:///android_asset/www/sounds/achievement.mp3");
+        errorSound = new Media("file:///android_asset/www/sounds/error.mp3");
+        purchaseSound = new Media("file:///android_asset/www/sounds/purchase.mp3");
+    }
+    catch(e){}
+    // Ads
+    /*if(localStorage["showAds"] == "true"){
+        admob.setOptions({
+            publisherId:          "ca-app-pub-5926997736584944/3066080116" ,  // Required
+            interstitialAdId:     "ca-app-pub-5926997736584944/6019546518",  // Optional
+        });
+        document.addEventListener(admob.events.onAdLoaded, onAdLoadedEvent);
+        prepareInterstitialAd();
+        admob.createBannerView();
+    }*/
+    try{
+        if(localStorage["showAds"] == "true"){
+            admobid = {
+                banner: 'ca-app-pub-5926997736584944/3066080116', 
+                interstitial: 'ca-app-pub-5926997736584944/6019546518'
+            };
+            setTimeout(function(){
+                AdMob.createBanner({
+                    isTesting: false,
+                  adId: admobid.banner,
+                  position: AdMob.AD_POSITION.BOTTOM_CENTER,
+                  autoShow: true,
+                    success: function(){
+                        //alert('yeai')
+                        //alert(AdMob.AD_POSITION.BOTTOM_CENTER)
+                        AdMob.showBanner(AdMob.AD_POSITION.BOTTOM_CENTER)
+                    },
+                    error: function(){
+                        //alert('failed to create banner');
+                    }});
+                AdMob.prepareInterstitial( {adId:admobid.interstitial, autoShow:false, isTesting: false} );
+                AdMob.prepareRewardVideoAd({adId:"ca-app-pub-5926997736584944/8707157712", autoShow:false, isTesting: false}, function(){
+                    //alert('yep')
+                }, function(){
+                    //alert('nope')
+                });
+            }, 50)
+        }
+        videoRewardCountdown()
+    }
+    catch(e){}
+    try{
+    navigator.globalization.getPreferredLanguage(function (language) {
+            var language = language.value.split('-')[0]
+            switch(language){
+                case 'fr': lang = 'fr'; break;
+                case 'de': lang = 'dr'; break;
+                case 'es': lang = 'es'; break;
+                case 'en': lang = 'en'; break;
+                default: lang = 'en'; break;
+            }
+            load()
+            setTimeout(function(){
+                document.body.className = "menu"
+            }, 2500)
+            //alert(lang)
+        })
+        // Load the game
+    }
+    catch(e){}
+}
+
+// Store
+function refreshStore(){
+    // 20 lives
+    try{
+        var product20 = store.get("20lives");
+        document.querySelector('#buy20lives .title').innerHTML = langStrs[lang]["buy"]+ product20.title.replace(/ *\([^)]*\) */g, "");
+        document.querySelector('#buy20lives .price').innerHTML = product20.price
+        document.querySelector('#buy20lives').addEventListener('touchstart',function(){
+            store.order("20lives");
+        },false)
+    }
+    catch(e){}
+    // 50 lives
+    try{
+        var product50 = store.get("50lives");
+        document.querySelector('#buy50lives .title').innerHTML = langStrs[lang]["buy"]+ product50.title.replace(/ *\([^)]*\) */g, "");
+        document.querySelector('#buy50lives .price').innerHTML = product50.price
+        document.querySelector('#buy50lives').addEventListener('touchstart',function(){
+            store.order("50lives");
+        },false)
+    }
+    catch(e){}
+    // 200 lives
+    try{
+        var product200 = store.get("200lives");
+        document.querySelector('#buy200lives .title').innerHTML = langStrs[lang]["buy"]+ product200.title.replace(/ *\([^)]*\) */g, "");
+        document.querySelector('#buy200lives .price').innerHTML = product200.price
+        document.querySelector('#buy200lives').addEventListener('touchstart',function(){
+            store.order("200lives");
+        },false)
+    }
+    catch(e){}
+    // Remove ads
+    try{
+        var removeads = store.get("removeads");
+        document.querySelector('#removeads .title').innerHTML = removeads.title.replace(/ *\([^)]*\) */g, "");
+        document.querySelector('#removeads .price').innerHTML = removeads.price
+        if(removeads.state == store.OWNED){
+            localStorage["showAds"] = "false"
+            document.querySelector('#removeads').classList.add("owned")
+            AdMob.hideBanner();
+            AdMob.removeBanner();
+        }
+        else{
+            document.querySelector('#removeads').addEventListener('touchstart',function(){
+                store.order("removeads");
+            },false)
+        }
+    }
+    catch(e){}
+}
+
+
+// Click
+function click(){
+    lastClickTime = new Date().getTime();
+    // Blue and green buttons just let you go
+    if(colour == 0 || colour == 2){
+        score++
+        if(parseInt(localStorage["highscore"])+1 == score && localStorage["highscore"] != "0"){
+            logMessage(langStrs[lang]["highscore"])
+            playSound("achievement")
+        }
+        playSound("tap")
+        if(score == 25 || score == 50 || (score%100 == 0 && score!=0)){
+            logMessage(score+langStrs[lang]["points"])
+            playSound("achievement")
+        }
+        shuffle()
+    }
+    // Red buttons make you lose
+    else if(colour == 1){
+        lose(langStrs[lang]["notRed"]);
+    }
+    
+}
+
+// Logging messages
+function logMessage(mssg, time){
+    if(time==undefined){
+        time = 1500
+    }
+    var messageDiv = document.getElementById('message')
+    messageDiv.innerHTML = mssg
+    messageDiv.style.color = "rgba(88,88,88,1)"
+    messageDiv.style.top = "8%"
+    setTimeout(function(){
+        var messageDiv = document.getElementById('message')
+        messageDiv.style.color = "rgba(88,88,88,0)"
+        messageDiv.style.top = "-2%"
+        setTimeout(function(){
+            var messageDiv = document.getElementById('message')
+            messageDiv.style.top = "13%"
+        }, 800)
+    }, time)
+}
+
+// Create a new button
+function shuffle(){
+    var x = Math.random();
+    if(blueInRow>5){
+        console.log("Capped blues")
+        x = 0.8;
+    }
+    // Blue
+    if(x < (0.3 + 0.45*Math.exp((-score) / 1200))){ 
+        colour = 0 
+        blueInRow++
+    }
+    // Red
+    else if(x < (0.67 + 0.25*Math.exp((-score) / 900))){
+        blueInRow = 0
+        colour = 1
+        setTimeout(function(){
+            if(playing){
+                colour = 0;
+                update()
+            }
+        }, Math.min(Math.max(460 + 400*Math.exp((-score) / 100) - 30*Math.log(score) + (Math.random()-0.5)*200, 400), 900));
+    }
+    // Green
+    else{ 
+        blueInRow = 0
+        colour = 2
+        setTimeout(function(){ 
+            var t = new Date().getTime();
+            if(t - lastClickTime > Math.max(750 - 4*score, 350)){
+                lose(langStrs[lang]["tooSlow"]);
+            }
+        }, Math.min(460 + 400*Math.exp((-score) / 100) - 30*Math.log(score), 900));
+    }
+    update()
+}
+// Update the screen
+function update(){
+    if(colour == 0){clicker.className = "button round-button blue"}
+    if(colour == 1){clicker.className = "button round-button red"}
+    if(colour == 2){clicker.className = "button round-button green"}
+    if(score == 0){
+        text.innerHTML = langStrs[lang]["textlabel"]
+    }
+    else{
+        text.innerHTML = score;
+    }
+}
+
+// UI
+function lose(reason){
+    if(parseInt(localStorage["highscore"]) < score && localStorage["highscore"] != 0){ // New Highscore
+        document.getElementById('newScore').className = 'highscore'
+        document.getElementById('newScore').innerHTML = langStrs[lang]["shareHighscore"]
+    }
+    else{ //Normal score
+        document.getElementById('newScore').className = 'normalScore'
+        document.getElementById('newScore').innerHTML = langStrs[lang]["shareScore"]
+    }
+    // Update highscore
+    if(localStorage["highscore"] < score){
+        localStorage["highscore"] = score
+    }
+    document.querySelector('#highScoretext span').innerHTML = localStorage["highscore"]
+    playSound("error")
+    playing = false;
+    lostTime = new Date().getTime()
+    console.log("You lost", score)
+    document.body.className = "loser"
+    loserOverlay.querySelector('#loseReason').innerHTML = reason
+    loserOverlay.querySelector('a').innerHTML = score;
+    // Start counting heart down
+    if(canRespawn){
+        heartClippingY = 0;
+        heartRespawn.style['margin-top'] = heartClippingY+"px"
+        heartRespawn.style['background-position-y'] = -heartClippingY+"px"
+        heartRespawn.style['height'] = 100-heartClippingY+"px"
+        document.getElementById("heartExplanation").style.color = "rgba(200,200,200,0.8)"
+        setTimeout(respawnCountdown, 1200)
+    }
+    else{
+        heartClippingY = 100;
+        respawnCountdown();
+    }
+}
+function restart(){
+    var t = new Date().getTime();
+    if((lostTime == undefined || t > lostTime+500) && playing==false){ //So that user doesn't restart unwillingly
+        playing = true;
+        score = 0
+        colour = 0
+        heartClippingY = 0
+        canRespawn = true;
+        update()
+        document.body.className = "playing"
+        numberOfGames++
+        if(localStorage["showAds"] == "true" && numberOfGames%5 == 4){
+            //showInterstitialAd()
+            AdMob.showInterstitial();
+            setTimeout(function(){
+                AdMob.prepareInterstitial( {adId:admobid.interstitial, autoShow:false, isTesting: false} );
+            }, 500)
+            setTimeout(function(){
+                logMessage(langStrs[lang]["removeAds"], 4000)
+            }, 1000)
+        }
+    }
+}
+function menu(event){
+    playing = false;
+    event.stopPropagation();
+    document.body.className = "menu"
+}
+function share(){
+    facebookConnectPlugin.showDialog({
+        method: "share",
+        href: "https://play.google.com/store/apps/details?id=com.clicky.clicky",
+        caption: "Clicky",
+        description: langStrs[lang]["description"],
+        picture: "https://lh6.googleusercontent.com/AJvJVPTZ-l89nHSggNa6gwtDofahCQCQujivDO2et5vi2tNxl4ybOQgLRk7qLXlFOXPMLlEC=w371",
+        share_feedWeb: true, // iOS only
+    }, function(){}, function(){})
+}
+var resCountdown;
+function respawnCountdown(){
+    if(heartClippingY < 95){
+        heartClippingY += 1;
+        heartRespawn.style['margin-top'] = heartClippingY+"px"
+        heartRespawn.style['background-position-y'] = -heartClippingY+"px"
+        heartRespawn.style['height'] = 100-heartClippingY+"px"
+        
+        //heartRespawn.style['clip-path'] = "inset("+heartClippingY+"px 0px 0px 0px)"
+        //heartRespawn.style.webkitClipPath = "inset("+heartClippingY+"px 0px 0px 0px)"
+        //heartRespawn.style['background-position-x'] = x+"px"
+        resCountdown = setTimeout(respawnCountdown, 80)
+    }
+    else{ //You can't respawn anymore
+        //heartRespawn.style['clip-path'] = "inset("+200+"px 0px 0px 0px)"
+        //heartRespawn.style.webkitClipPath = "inset("+200+"px 0px 0px 0px)"
+        heartRespawn.style['margin-top'] = 99+"px"
+        heartRespawn.style['background-position-y'] = -99+"px"
+        heartRespawn.style['height'] = 100-99+"px"
+        canRespawn = false;
+        document.getElementById("heartExplanation").style.color = "rgba(200,200,200,0)"
+    }
+}
+function respawn(event){
+    console.log('respawning')
+    event.stopPropagation();
+    if(parseInt(localStorage["lives"]) > 0){ //Still lives left
+        if(canRespawn){
+            // Continue from whenever we were with blue button
+            playing = true;
+            canRespawn = false
+            colour = 0
+            update()
+            document.body.className = "playing"
+            // Take one life off
+            localStorage["lives"] = parseInt(localStorage["lives"]) - 1
+            livesCounter.querySelector('#livesCounter').innerHTML = localStorage["lives"]
+        }
+    }
+    else{ // Need to buy lives
+        goToStore(undefined,true)
+        heartClippingY = 0
+        clearTimeout(resCountdown)
+        heartRespawn.style['margin-top'] = 0+"px"
+        heartRespawn.style['background-position-y'] = -0+"px"
+        heartRespawn.style['height'] = 100-0+"px"
+    }
+}
+function goToSettings(){
+    document.body.className = "settings"
+    if(localStorage["sound"] == "false"){
+        settingsOverlay.querySelector("#soundButton").className = "offButton"
+    }
+    else{
+        settingsOverlay.querySelector("#soundButton").className = ""
+    }
+}
+function goToStore(event, backToLoser){
+    document.body.className = "store"
+    if(playing){
+        storeOverlay.querySelector('#storeGoToMenu').style.display = "none"
+        storeOverlay.querySelector('#storeGoToGame').style.display = "block"
+        storeOverlay.querySelector('#storeGoToLoser').style.display = "none"
+    }
+    else if(backToLoser != undefined){
+        storeOverlay.querySelector('#storeGoToMenu').style.display = "none"
+        storeOverlay.querySelector('#storeGoToGame').style.display = "none"
+        storeOverlay.querySelector('#storeGoToLoser').style.display = "block"
+    }
+    else{
+        storeOverlay.querySelector('#storeGoToMenu').style.display = "block"
+        storeOverlay.querySelector('#storeGoToGame').style.display = "none"
+        storeOverlay.querySelector('#storeGoToLoser').style.display = "none"
+    }
+    keepRefreshingStore()
+}
+function keepRefreshingStore(){
+    if(document.body.className == "store"){
+        store.refresh()
+        setTimeout(keepRefreshingStore, 1000)
+    }
+    else{
+        store.refresh()
+    }
+}
+function continueGame(){
+    document.body.className = "playing"
+}
+function goToLoser(){
+    document.body.className = "loser"
+}
+function toggleSound(){
+    if(localStorage["sound"] == "false"){
+        localStorage["sound"] = "true"
+    }
+    else{
+        localStorage["sound"] = "false"
+    }
+    goToSettings()
+}
+
+// Sounds
+function playSound(sound){
+    try{
+        if(localStorage["sound"] == "true"){
+            if(sound == "tap"){
+                if(score%2 == 0){
+                    tapSound.seekTo(0)
+                    tapSound.play()
+                } else{
+                    tapSound2.seekTo(0)
+                    tapSound2.play();
+                }
+            }
+            else if(sound =="achievement"){
+                achievementSound.play()
+            }
+            else if(sound == "error"){
+                errorSound.play()
+            }
+            else if(sound == "purchase"){
+                purchaseSound.play()
+            }
+        }
+    }
+    catch(e){}
+}
+
+// High scores
+/*function goToHighscores(){
+    //alert(2)
+    facebookConnectPlugin.login(["user_friends"], function(obj){
+        //alert("Worked1")
+       // localStorage["link"] = "https://graph.facebook.com/oauth/access_token_info?client_id=APPID&access_token="+obj["authResponse"]["accessToken"]
+        //alert(localStorage["link"])
+        //document.getElementById('soundButton').innerHTML=obj["authResponse"]["accessToken"]
+    },
+    function(str){
+        //alert("Didn't work")
+        //alert(str)
+        //navigator.notification.alert("Facebook access is needed to get highscores.", function(){}, "Could not open highscores")
+    })
+}*/
+
+function shareScore(event){
+    event.stopPropagation();
+    facebookConnectPlugin.showDialog({
+        method: "share",
+        href: "https://play.google.com/store/apps/details?id=com.clicky.clicky",
+        caption: langStrs[lang]["shareTitle"],
+        description: langStrs[lang]["shareDescription1"]+score+langStrs[lang]["shareDescription2"],
+        quote: langStrs[lang]["shareDescription1"]+score+langStrs[lang]["shareDescription2"],
+        share_feedWeb: true, // iOS only
+    }, function(){}, function(){})
+}
+
+// Video reward countdown
+var videoTimeLeft = 60
+function videoRewardCountdown(){
+    videoTimeLeft--
+    if(videoTimeLeft>0){
+        document.getElementById('videoCountdown').innerHTML = "(" + videoTimeLeft + "s)"
+        setTimeout(videoRewardCountdown, 1000)
+        document.getElementById('freelife').className="storeButton disabled"
+    }
+    else{
+        document.getElementById('videoCountdown').innerHTML = ""
+        document.getElementById('freelife').className="storeButton"
+    }
+}
+
+// Credits
+function openCredits(){
+    document.body.className = "credits"
+}
+function closeCredits(){
+    document.body.className = "settings"
+}
+

TEMPAT SAMPAH
dev/screen/splashscreen.psd


TEMPAT SAMPAH
dev/screen/splashscreen1280.png


TEMPAT SAMPAH
dev/screen/splashscreen200.png


TEMPAT SAMPAH
dev/screen/splashscreen320.png


TEMPAT SAMPAH
dev/screen/splashscreen480.png


TEMPAT SAMPAH
dev/screen/splashscreen720.png


TEMPAT SAMPAH
dev/screen/splashscreen960.png


TEMPAT SAMPAH
dev/sounds/achievement.mp3


TEMPAT SAMPAH
dev/sounds/chime.wav


TEMPAT SAMPAH
dev/sounds/coin.wav


TEMPAT SAMPAH
dev/sounds/error.mp3


TEMPAT SAMPAH
dev/sounds/error.wav


TEMPAT SAMPAH
dev/sounds/lose.mp3


TEMPAT SAMPAH
dev/sounds/lose.wav


TEMPAT SAMPAH
dev/sounds/oldtap.ogg


TEMPAT SAMPAH
dev/sounds/purchase.mp3


TEMPAT SAMPAH
dev/sounds/purchase.wav


TEMPAT SAMPAH
dev/sounds/tap.aac


+ 27 - 0
dev/sounds/tap.aup

@@ -0,0 +1,27 @@
+<?xml version="1.0" standalone="no" ?>
+<!DOCTYPE project PUBLIC "-//audacityproject-1.3.0//DTD//EN" "http://audacity.sourceforge.net/xml/audacityproject-1.3.0.dtd" >
+<project xmlns="http://audacity.sourceforge.net/xml/" projname="tap_data" version="1.3.0" audacityversion="2.1.3" sel0="0.0000000000" sel1="0.0000000000" vpos="0" h="0.0000000000" zoom="1701.2523904074" rate="44100.0" snapto="off" selectionformat="hh:mm:ss + milliseconds" frequencyformat="Hz" bandwidthformat="octaves">
+	<tags>
+		<tag name="Software" value="Lavf57.73.100"/>
+	</tags>
+	<wavetrack name="tap" channel="0" linked="1" mute="0" solo="0" height="150" minimized="0" isSelected="1" rate="44100" gain="1.0" pan="0.0">
+		<waveclip offset="0.00000000">
+			<sequence maxsamples="262144" sampleformat="262159" numsamples="6636">
+				<waveblock start="0">
+					<simpleblockfile filename="e000064f.au" len="6636" min="-0.43638" max="0.474386" rms="0.062538"/>
+				</waveblock>
+			</sequence>
+			<envelope numpoints="0"/>
+		</waveclip>
+	</wavetrack>
+	<wavetrack name="tap" channel="1" linked="0" mute="0" solo="0" height="150" minimized="0" isSelected="1" rate="44100" gain="1.0" pan="0.0">
+		<waveclip offset="0.00000000">
+			<sequence maxsamples="262144" sampleformat="262159" numsamples="6636">
+				<waveblock start="0">
+					<simpleblockfile filename="e000041d.au" len="6636" min="-0.429397" max="0.462325" rms="0.061663"/>
+				</waveblock>
+			</sequence>
+			<envelope numpoints="0"/>
+		</waveclip>
+	</wavetrack>
+</project>

TEMPAT SAMPAH
dev/sounds/tap.mp3


TEMPAT SAMPAH
dev/sounds/tap.ogg


TEMPAT SAMPAH
dev/sounds/tap.wav


TEMPAT SAMPAH
dev/sounds/tap2.mp3


TEMPAT SAMPAH
dev/sounds/tap2.ogg


TEMPAT SAMPAH
dev/sounds/tap_data/e00/d00/e000041d.au


TEMPAT SAMPAH
dev/sounds/tap_data/e00/d00/e000064f.au


TEMPAT SAMPAH
dev/store/graphic.png


TEMPAT SAMPAH
dev/store/graphic.psd


TEMPAT SAMPAH
dev/store/screenshots/Screenshot_2017-06-16-19-56-43.png


TEMPAT SAMPAH
dev/store/screenshots/Screenshot_2017-06-16-19-57-01.png


TEMPAT SAMPAH
dev/store/screenshots/Screenshot_2017-06-21-14-47-47.png


TEMPAT SAMPAH
dev/store/screenshots/Screenshot_2017-06-21-14-48-44.png


TEMPAT SAMPAH
dev/store/screenshots/greencropped.png


TEMPAT SAMPAH
dev/store/screenshots/screenshotcropped.png


+ 486 - 0
dev/style.css

@@ -0,0 +1,486 @@
+/*Credit
+    http://www.flaticon.com/free-icon/press-button_1402#term=click&page=1&position=18
+http://www.flaticon.com/free-icon/play-arrow_60813#term=right&page=1&position=21
+http://www.flaticon.com/free-icon/like_148836#term=heart&page=1&position=1
+
+https://www.freesound.org/people/jcallison/sounds/258269/
+https://www.freesound.org/people/shinephoenixstormcrow/sounds/337049/
+https://www.freesound.org/people/rhodesmas/sounds/342751/
+https://www.freesound.org/people/acclivity/sounds/18923/
+https://www.freesound.org/people/soundnimja/sounds/173320/
+https://www.freesound.org/people/distillerystudio/sounds/327736/
+https://www.freesound.org/people/original_sound/sounds/366103/
+*/
+
+body {
+    background: rgb(230, 230, 230);
+    -webkit-user-select: none;     
+    -moz-user-select: none; 
+    -ms-user-select: none;
+
+  
+    -o-user-select: none;
+    user-select: none;
+}
+
+/*ROUND BUTTON*/
+.round-button {
+    /*transition: filter .5s;*/
+    /*-webkit-transition: -webkit-filter .5s;*/
+	width:85%;   
+    position: relative;
+    top: 50%;
+    left: 50%;
+    transform: translate(-50%,-60%);
+    -webkit-transform: translate(-50%,-60%);
+}
+.round-button-inside {
+	width: 100%;
+	height:0;
+	padding-bottom: 100%;
+    border-radius: 50%;
+	border:10px solid #cfdcec;
+    overflow:hidden;
+}
+.round-button a {
+    display:block;
+	float:left;
+	width:100%;
+	padding-top:50%;
+    padding-bottom:50%;
+	line-height:1em;
+	margin-top:-0.5em;
+    
+	text-align:center;
+	color:#e2eaf3;
+    font-family:Verdana;
+    font-size:5em;
+    font-weight:bold;
+    text-decoration:none;
+}
+
+/*Blue*/
+.blue .round-button-inside{
+    background: #4679BD; 
+    box-shadow: 0 0 3px gray;
+}
+.blue .round-button-inside:hover {
+    background: #4073B7; 
+}
+/*Red*/
+.red .round-button-inside{
+    background: #c34141; 
+    box-shadow: 0 0 3px gray;
+}
+.red .round-button-inside:hover {
+    background: #be3b3b; 
+}
+/*Green*/
+.green .round-button-inside{
+    background: #46bd5a; 
+    box-shadow: 0 0 3px gray;
+}
+.green .round-button-inside:hover {
+    background: #40b754; 
+}
+
+
+/*TRIANGLE BUTTON*/
+.triangle-button {
+    /*transition: filter .5s;*/
+    /*-webkit-transition: -webkit-filter .5s;*/
+	width:85%;   
+    position: relative;
+    top: 50%;
+    left: 50%;
+    transform: translate(-50%,-60%);
+    -webkit-transform: translate(-50%,-60%);
+}
+.triangle-button-inside {
+	width: 100%;
+	height:0;
+    background-size:100%;
+	padding-bottom: 100%;
+    overflow:hidden;
+}
+.triangle-button a {
+    display:block;
+	float:left;
+	width:100%;
+	padding-top:50%;
+    padding-bottom:50%;
+	line-height:1em;
+	margin-top:-0.5em;
+    
+	text-align:center;
+	color:#e2eaf3;
+    font-family:Verdana;
+    font-size:5em;
+    font-weight:bold;
+    text-decoration:none;
+}
+/*Blue*/
+.blue .triangle-button-inside{
+    background-image: url("img/blueright.png");
+}
+/*Red*/
+.red .triangle-button-inside{
+    background-image: url("img/redright.png");
+}
+/*Green*/
+.green .triangle-button-inside{
+    background-image: url("img/greenright.png");
+}
+
+
+/*Overlay*/
+.overlay{
+    width: 100%;
+    height: 100%;
+    position: absolute;
+    top: 0;
+    bottom: 0;
+    padding: 0;
+    margin: 0;
+    left: 0;
+    right: 0;
+}
+.overlayText {
+    text-align: center;
+    color: rgb(224, 224, 224);
+    font-family: Helvetica;
+    font-size: 3em;
+}
+
+/*Loser*/
+.loser .button {
+    filter: blur(10px);
+    -webkit-filter: blur(10px);   
+}
+.loser #loserOverlay{
+    display: block;
+    opacity: 1;
+}
+#loserOverlay {
+    /*transition: opacity .4s;*/
+    /*-webkit-transition: opacity .4s;*/
+    background: rgba(0, 0, 0, 0.60);
+}
+#loserOverlay #loserText {
+    position: relative;
+    top: 7%;
+}
+#loserOverlay #loserGoToMenu {
+    bottom: 1%;
+    position: absolute;
+    text-align: center;
+    left: 50%;
+    transform: translate(-50%, -50%);
+    -webkit-transform: translate(-50%, -50%);
+}
+#loserOverlay #loserText #loserScore{
+    font-size: .5em;
+    margin-top: 10px;
+}
+#loserOverlay #loserText #loserScore a {
+    font-weight: bold;
+    font-size: 1.1em;
+}
+#loserOverlay #highScoreText {
+    font-size: .4em;
+    color: rgb(200,200,200);
+    margin-top: 5px;
+}
+#loserOverlay{
+    display: none;
+    opacity: 0;
+}
+#heartRespawn {
+    width: 100px;
+    height: 100px;
+    background-position-y: -20px;
+    margin-top: 20px;
+    left: 50%;
+    position: relative;
+    transform: translateX(-50%);
+    -webkit-transform: translateX(-50%);
+    margin-bottom: 20px;
+    background-image: url(img/heart.png);
+    background-size: 100px;
+    background-repeat: no-repeat;   
+}
+#loserOverlay #newScore.highscore{
+    font-size: 0.7em;
+    margin-top: 20px;
+    color: rgba(255, 255, 255, 1);
+    border: 1px solid white;
+    padding: 10px;
+    margin-left: 20px;
+    margin-right: 20px;
+    background: rgba(200,200,200,.2);
+    overflow: hidden;
+    position: relative;
+}
+
+@keyframes sheen {
+  100% {
+    transform: rotateZ(60deg) translate(0, -7em);
+    -webkit-transform: rotateZ(60deg) translate(0, -7em);
+  }
+}
+
+@-webkit-keyframes sheen {
+  100% {
+    transform: rotateZ(60deg) translate(0, -7em);
+    -webkit-transform: rotateZ(60deg) translate(0, -7em);
+  }
+}
+
+#newScore.highscore:after {
+  animation: sheen 5s ease .5s infinite forwards;
+  -webkit-animation: sheen 5s ease .5s infinite forwards;
+  content: '';
+  position: absolute;
+  top: 0;
+  right: 0;
+  bottom: 0;
+  left: 0;
+  background: linear-gradient(to bottom, transparent, rgba(255,255,255,0.15) 35%, transparent);
+  transform: rotateZ(60deg) translate(-1em, 7em);
+  -webkit-transform: rotateZ(60deg) translate(-1em, 7em);
+}
+
+#loserOverlay #newScore.normalScore{
+    font-size: 0.5em;
+    margin-top: 20px;
+    padding: 10px;
+    margin-left: 40px;
+    margin-right: 40px;
+    background: rgba(200,200,200,.1);
+    overflow: hidden;
+    position: relative;
+}
+
+/*Menu*/
+.menu .button {
+    filter: blur(20px);   
+    -webkit-filter: blur(20px);   
+}
+.menu #menuOverlay{
+    display: block;
+    opacity: 1;
+}
+#menuOverlay #menuText {
+    position: relative;
+    top: 16%;
+    text-align: center;
+    color: rgb(224, 224, 224);
+    font-family: Helvetica;
+    font-size: 3em;
+}
+#menuOverlay{
+    background: rgba(0, 0, 0, 0.30);
+}
+#menuOverlay{
+    display: none;
+    opacity: 0;
+}
+
+/*Settings*/
+.settings .button {
+    filter: blur(20px);   
+    -webkit-filter: blur(20px);   
+}
+.settings #settingsOverlay{
+    display: block;
+    opacity: 1;
+}
+#settingsOverlay #settingsText {
+    position: relative;
+    top: 20%;
+    text-align: center;
+    color: rgb(224, 224, 224);
+    font-family: Helvetica;
+    font-size: 3em;
+}
+#settingsOverlay{
+    background: rgba(0, 0, 0, 0.30);
+}
+#settingsOverlay{
+    display: none;
+    opacity: 0;
+}
+#settingsOverlay #settingsGoToMenu {
+    bottom: 1%;
+    position: absolute;
+    text-align: center;
+    left: 50%;
+    transform: translate(-50%, -50%);
+    -webkit-transform: translate(-50%, -50%);
+}
+.offButton{
+    text-decoration:line-through
+}
+
+/*Store*/
+.store .button {
+    filter: blur(20px);   
+    -webkit-filter: blur(20px);   
+}
+.store #storeOverlay{
+    display: block;
+    opacity: 1;
+}
+#storeOverlay .storeButton {
+    position: relative;
+    top: 55px;
+    text-align: center;
+    color: rgb(224, 224, 224);
+    font-family: Helvetica;
+    font-size: 1.7em;
+    border: 2px solid white;
+    margin-left: 20px;
+    margin-right: 20px;
+    margin-top: 15px !important;
+    background: rgba(200,200,200,.1);
+    transition: background 0.5s, color 0.5s, border 0.5s;
+    -webkit-transition: background 0.5s, color 0.5s, border 0.5s;
+}
+#storeOverlay .storeButton.owned {
+    border: 2px solid #d0d0d0 !important;
+    color: rgb(112, 179, 152) !important;
+    background: rgba(200,200,200,0.3) !important;
+}
+#storeOverlay .storeButton.disabled {
+    border: 2px solid #d0d0d0 !important;
+    color: rgba(200, 200, 200, .7) !important;
+    background: rgba(200,200,200,0.3) !important;
+}
+#storeOverlay .storeButton.owned .title:after {
+    content: " (bought)";
+    font-size: .8em;
+    opacity: .7;
+}
+#storeOverlay{
+    background: rgba(0, 0, 0, 0.30);
+}
+#storeOverlay{
+    display: none;
+    opacity: 0;
+}
+#storeOverlay #storeGoToMenu,  #storeOverlay #storeGoToGame, #storeOverlay #storeGoToLoser {
+    bottom: 1%;
+    position: absolute;
+    text-align: center;
+    left: 50%;
+    transform: translate(-50%, -50%);
+    -webkit-transform: translate(-50%, -50%);
+}
+.price {
+    font-size: .8em;
+}
+
+/*Lives counter*/
+#lives{
+    top:15px;
+    right: 15px;
+    position: fixed;
+    z-index:1;
+}
+#livesCounter {
+    color: rgb(180, 180, 180);
+    font-family: Helvetica;
+    font-size: 2.5em;
+    display: inline-block;
+    margin-right: 4px;
+    transform: translateY(-5px);
+    -webkit-transform: translateY(-5px);
+}
+#livesIcon {
+    width: 40px;
+    height: 40px;
+    background-image: url("img/heart.png");
+    background-position: 0px;
+    background-size: 100%;
+    display: inline-block;
+}
+
+/*Messages*/
+#message {
+    color: rgba(88, 88, 88, .0);
+    font-family: Helvetica;
+    font-size: 1.5em;
+    position: fixed;
+    top: 13%;
+    left: 50%;
+    transform: translateX(-50%);
+    -webkit-transform: translateX(-50%);
+    transition: top 0.5s, color 0.5s;
+    -webkit-transition: top 0.5s, color 0.5s;
+    text-align: center;
+    z-index:-1;
+}
+
+/*Credits*/
+.credits #creditsOverlay{
+    display: block;
+    opacity: 1;
+     background: rgba(0, 0, 0, 0.30);
+}
+#creditsOverlay{
+    display: none;
+}
+#creditsOverlay #creditsText {
+     color: rgb(255,255,255);
+    font-family: Helvetica;
+    font-size: 1em;
+    position: fixed;
+    top: 13%;
+    left: 50%;
+    transform: translateX(-50%);
+    -webkit-transform: translateX(-50%);
+    transition: top 0.5s, color 0.5s;
+    -webkit-transition: top 0.5s, color 0.5s;
+    text-align: center;
+    width: 90%;
+    border: 2px solid whitesmoke;
+}
+#creditsOverlay #creditsText div{
+    margin: 10px;
+}
+#creditsOverlay #creditsText a{
+    color: aqua;
+}
+.credits .button {
+    filter: blur(10px);
+    -webkit-filter: blur(10px);   
+}
+
+
+/*Splash screen*/
+.splash #splashScreen {
+    display: block;
+    opacity: 1;
+    background: rgb(230,230,230);
+}
+#splashScreen{
+    display: none;
+    width: 100%;
+    height: 100%;
+    position: absolute;
+    top: 0;
+    bottom: 0;
+    padding: 0;
+    margin: 0;
+    left: 0;
+    right: 0;
+    z-index:5;
+}
+#splashScreen img {
+    top: 50%;
+    width: 90%;
+    position: fixed;
+    transform: translate(-50%, -50%);
+    -webkit-transform: translate(-50%, -50%);
+    left: 50%;
+}

+ 54 - 0
dist/config.xml

@@ -0,0 +1,54 @@
+<?xml version="1.0" encoding="UTF-8"?>
+	<widget xmlns = "http://www.w3.org/ns/widgets"
+		xmlns:gap = "http://phonegap.com/ns/1.0"
+		xmlns:android = "http://schemas.android.com/apk/res/android"
+		id        = "com.clicky.clicky"
+		versionCode="100011"
+		version   = "">
+		<name>Clicky		</name>
+		<description>		</description>
+		<author href="" email="">		</author>
+
+		<platform name="ios">
+            <icon src="clicky/icons/144.png" width="144" height="144" />
+            <icon src="clicky/icons/72.png" width="72" height="72" />
+		</platform>
+		<platform name="android">
+            <config-file target="AndroidManifest.xml" parent="/manifest">
+            </config-file>
+            <icon src="clicky/icons/72.png" qualifier="hdpi" />
+            <icon src="clicky/icons/96.png" qualifier="xhdpi" />
+            <icon src="clicky/icons/144.png" qualifier="xxhdpi" />
+            <icon src="clicky/icons/192.png" qualifier="xxxhdpi" />
+		</platform>
+		<platform name="winphone">
+		</platform>
+		 <icon src="icon.png" />
+        <preference name="android-minSdkVersion" value="15" />
+        <preference name="orientation" value="portrait" />
+        <preference name="AndroidLaunchMode" value="singleTop" />
+        <preference name="permissions" value="none" />
+        <gap:config-file platform="android" parent="/manifest/application">
+            <activity android:launchMode="singleTop" />
+        </gap:config-file>
+        <preference name="android-build-tool" value="gradle" /> 
+        <plugin name="cordova-plugin-facebook4" source="npm" spec="~1.9.0">
+            <param name="APP_ID" value="1713477538946821" />
+            <param name="APP_NAME" value="Clicky" />
+        </plugin>
+        <!--<gap:plugin name="com.phonegap.plugins.facebookconnect" spec="0.8.0">
+            <param name="APP_ID" value="1713477538946821" />
+            <param name="APP_NAME" value="Clicky" />
+        </gap:plugin>-->
+        
+        <gap:plugin name="cc.fovea.cordova.purchase" source="npm" version="6.0.0">
+           <param name="BILLING_KEY" value="MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAkUPUuXRMsIjAA8MB6zXtA+Ry+cfbF08/ZxNiHq/L0bul1Uq8sxVuXRZB55NGM7VwWNeazuMS7+0NX5xVAOYvuZ+j040r5K2t9FE15g8frQe16Ezw1zMhqsAB3jxhY2pCkt1vCGfNbsT5S5+hrAs9X2gDqNHDNdEO2NFSA9+L7nwD9x/15UOp6x3r+suIPgwkbd5V3dFIneZhVPoUlCS8xM67qom//yMPCLCdLNOHYq35LRo4nRdhX3iJjHKJEogOgK8QH8GooIbW/r70f79IONu4wAc2E+74BgkiVs29zwwR6AUFRVPoclD11FBwgdLQN7Z8gxg3iLyKH9nD42s0DwIDAQAB"/>
+        </gap:plugin>
+        <plugin name="org.apache.cordova.media" source="npm" />
+        <plugin name="org.apache.cordova.dialogs" source="npm" />
+        <framework src="com.google.android.gms:play-services-ads:+" />
+
+        <!--<gap:plugin name="phonegap-admob" source="npm"/>-->
+        <gap:plugin name="cordova-plugin-admobpro" source="npm" />
+        <gap:plugin name="cordova-plugin-globalization" source="npm" />
+</widget>

TEMPAT SAMPAH
dist/icons/144.png


TEMPAT SAMPAH
dist/icons/192.png


TEMPAT SAMPAH
dist/icons/512.png


TEMPAT SAMPAH
dist/icons/72.png


TEMPAT SAMPAH
dist/icons/96.png


TEMPAT SAMPAH
dist/img/heart.png


TEMPAT SAMPAH
dist/img/heart.psd


TEMPAT SAMPAH
dist/img/like.png


+ 95 - 0
dist/index.html

@@ -0,0 +1,95 @@
+<html>
+<head>
+<script type="text/javascript" src="cordova.js"></script>
+<script type="text/javascript" src="logic.js" charset="UTF-8"></script>
+<link rel="stylesheet" type="text/css" href="style.css">
+</head>
+<body class="splash">
+<div id="lives">
+<div id="livesCounter">3</div>
+<div id="livesIcon"></div>
+</div>
+<div id="clicker" class="button round-button blue">
+<div class="round-button-inside">
+<a id="textlabel">Click?</a>
+</div></div>
+<div class="overlay" id="loserOverlay">
+<div class="overlayText" id="loserText">
+<div id="heartRespawn"></div>
+<div id="loseReason">You lost!</div>
+<div id="loserScore">You scored <a>0</a> points</div>
+<div id="heartExplanation" style="font-size:.4em;margin-top:40px;color:rgba(200,200,200,0.8);transition:color .4s;-webkit-transition:color .4s">(Tap heart to continue this game)</div>
+<div id="newScore" class="normalScore">Share highscore!</div>
+<div id="highscoreText">Highscore: <span>0</span> points</div>
+</div>
+<div class="overlayText" id="loserGoToMenu">Menu</div>
+</div>
+<div class="overlay" id="menuOverlay">
+<div id="menuText">
+<div id="playButton" style="font-size:2.2em">Play</div>
+<div id="shareButton" style="margin-top:20px">Share</div>
+<div id="storeButton" style="margin-top:15px">Store</div>
+<div id="settingsButton" style="margin-top:15px">Settings</div>
+</div>
+</div>
+<div class="overlay" id="storeOverlay">
+<div id="storeListing">
+<div class="storeButton" id="freelife" style="margin-top:8px">
+<div class="title">1 free life!</div>
+<div class="price" style="display:inline"><span id="watchVideo">Watch video</span> <span id="videoCountdown">(60s)</span></div>
+</div>
+<div class="storeButton" id="buy20lives" style="margin-top:8px">
+<div class="title">Loading...</div>
+<img src="img/heart.png" width="20px" style="display:inline">
+<div class="price" style="display:inline">...</div>
+</div>
+<div class="storeButton" id="buy50lives" style="margin-top:8px">
+<div class="title">Loading...</div>
+<img src="img/heart.png" width="20px" style="display:inline">
+<img src="img/heart.png" width="20px" style="display:inline">
+<div class="price" style="display:inline">...</div>
+</div>
+<div class="storeButton" id="buy200lives" style="margin-top:8px">
+<div class="title">Loading...</div>
+<img src="img/heart.png" width="20px" style="display:inline">
+<img src="img/heart.png" width="20px" style="display:inline">
+<img src="img/heart.png" width="20px" style="display:inline">
+<div class="price" style="display:inline">...</div>
+</div>
+<div class="storeButton" id="removeads" style="margin-top:8px">
+<div class="title">Loading...</div>
+<div class="price" style="display:inline">...</div>
+</div>
+</div>
+<div class="overlayText" id="storeGoToMenu">Menu</div>
+<div class="overlayText" id="storeGoToGame">Back</div>
+<div class="overlayText" id="storeGoToLoser">Back</div>
+</div>
+<div class="overlay" id="settingsOverlay">
+<div id="settingsText">
+<div class="" id="soundButton" style="margin-top:40px">&nbsp Sound &nbsp</div>
+<div class="" id="creditsButton" style="margin-top:40px">Credits</div>
+</div>
+<div class="overlayText" id="settingsGoToMenu">Menu</div>
+</div>
+<div class="overlay" id="creditsOverlay">
+<div id="creditsText">
+<div>This game wouldn't have been possible without:</div>
+</br>
+<div><u>Icons</u></div>
+<div>Hand icon made by <a href="http://www.freepik.com/">Freepik</a> from <a href="http://www.flaticon.com">www.flaticon.com</a></div>
+<div>Heart icon made by <a href="http://www.flaticon.com/authors/madebyoliver">Freepik</a> from <a href="http://www.flaticon.com">www.flaticon.com</a></div>
+</br>
+<div><u>Sounds</u></div>
+<div>Tap sound made by <a href="https://www.freesound.org/people/jcallison/">jcallison</a> from <a href="https://www.freesound.org">www.freesound.org</a></div>
+<div>Achievement sound made by <a href="shinephoenixstormcrow">shinephoenixstormcrow</a> from <a href="https://www.freesound.org">www.freesound.org</a></div>
+<div>Buying sound made by <a href="https://www.freesound.org/people/rhodesmas/">rhodesmas</a> from <a href="https://www.freesound.org">www.freesound.org</a></div>
+<div>Lose sound made by <a href="https://www.freesound.org/people/original_sound/">original_sound</a> from <a href="https://www.freesound.org">www.freesound.org</a></div>
+</div>
+</div>
+<div id="splashScreen">
+<img src="icons/512.png">
+</div>
+<div id="message">20 points!</div>
+</body>
+</html>

File diff ditekan karena terlalu besar
+ 1 - 0
dist/logic.js


TEMPAT SAMPAH
dist/sounds/achievement.mp3


TEMPAT SAMPAH
dist/sounds/error.mp3


TEMPAT SAMPAH
dist/sounds/purchase.mp3


TEMPAT SAMPAH
dist/sounds/tap.ogg


TEMPAT SAMPAH
dist/sounds/tap2.ogg


File diff ditekan karena terlalu besar
+ 1 - 0
dist/style.css