cc.Class({
extends: cc.Component, properties: {
musicPlayer: {
default: null,
type: cc.AudioSource
},
dingClip: {
default: null,
url: cc.AudioClip
},
cheeringClip: {
default: null,
url: cc.AudioClip
}
}, // use this for initialization
onLoad: function () {
var self = this;
// play audioSource
self.musicPlayer.play(); // play ding in 1 sec, play cheering in 2 sec
setTimeout(function() {
cc.audioEngine.playEffect(self.dingClip, false);
setTimeout(function() {
cc.audioEngine.playEffect(self.cheeringClip, false);
}, 2000);
}, 1000);
}, // called every frame
update: function (dt) { },
});

ccc this 指针的更多相关文章

  1. HDU 5510---Bazinga(指针模拟)

    题目链接 http://acm.hdu.edu.cn/search.php?action=listproblem Problem Description Ladies and gentlemen, p ...

  2. 《C与指针》第十章练习

    本章问题 1.成员和数组元素有什么区别? answer:Structure members can be all different types;they are accessed by name;a ...

  3. C语言 二级指针内存模型混合实战

    //二级指针内存模型混合实战 #define _CRT_SECURE_NO_WARNINGS #include <stdio.h> #include <stdlib.h> #i ...

  4. C语言 二级指针内存模型③

    //二级指针内存模型③ #define _CRT_SECURE_NO_WARNINGS #include <stdio.h> #include <stdlib.h> #incl ...

  5. C语言 二级指针内存模型①

    //二级指针第一种内存模型 #include<stdio.h> #include<stdlib.h> //说明:①:类似于int a[5]={0},数组名a是一维数组a中首元素 ...

  6. Delphi函数翻译成VC要注意句柄指针传递(传递Handle的时候,必须加上一个指针引用,才能消除编译错误)

    Delphi里做了魔法变化,每个变量名称本身就是指针,因为不怎么需要指针语法.我也不知道是不是因为这个原因引起的Delphi与VC对句柄的不同处理. 这是Delphi的强行关机函数,好用,调用方式:W ...

  7. C语言基础知识点整理(函数/变量/常量/指针/数组/结构体)

    函数 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ...

  8. c/c++ vector,map,set,智能指针,综合运用的小例子

    标准库,智能指针,综合运用的小例子 功能说明:查询单词在文件中出现的次数,如果在同一行出现多次,只算一次. 比如查询单词:你好 输出的结果: 你好 出现了:2次 (行号 2)xxxxxxx 你好 (行 ...

  9. Html5画钟表盘/指针实时跳动

    1.最终效果 时钟.分钟.秒指针连续移动2.完整代码 <!DOCTYPE html> <html xmlns="http://www.w3.org/1999/xhtml&q ...

随机推荐

  1. 【转】Java高手真经全套书籍分享

    (转自:http://blog.sina.com.cn/s/blog_4ec2a8390101cd1n.html) 中文名: Java高手真经 原名: JAVA开发专家 作者: 刘中兵Java研究室 ...

  2. 素数环(dfs+回溯)

    题目描述: 输入正整数n,把整数1,2...n组成一个环,使得相邻两个数和为素数.输出时从整数1开始逆时针排列并且不能重复: 例样输入: 6 例样输出: 1 4 3 2 5 6 1 6 5 2 3 4 ...

  3. [译] 用 Swift 创建自定义的键盘

    本文翻译自 How to make a custom keyboard in iOS 8 using Swift 我将讲解一些关于键盘扩展的基本知识,然后使用iOS 8 提供的新应用扩展API来创建一 ...

  4. js函数的几个特殊点

    在ECMAScript中,Function(函数)类型实际上是对象.每个函数都是Function类型的实例,而且都与其他引用类型一样具有属性和方法.由于函数是对象,因此函数名实际上也是一个指向函数对象 ...

  5. Cannot return from outside a function or method

    最近发现myeclipse10中有几处bug 比如: Cannot return from outside a function or method onClick="return chec ...

  6. Oracle数据库备份与还原操作具体步骤

    Oracle数据库导出操作 导入导出都要进行目录创建与授权. 在pl/sql里面编写也可以 select * from dba_directories(这个是查看创建的目录) drop directo ...

  7. PHP中比较两个时间的大小与日期的差值

    在这里我们全用到时间戳 mktime(hour,minute,second,month,day,year,[is_dst])     其参数可以从右向左省略,任何省略的参数都会被设置成本地日期和时间的 ...

  8. Android性能优化系列 + Android官方培训课程中文版

    Android性能优化典范 - 第6季 http://hukai.me/android-performance-patterns-season-6/   Android性能优化典范 - 第5季 htt ...

  9. Solr auto commit 配置

    为了解决写索引时频繁提交带来的效率问题,考虑使用自动提交. 在solrconfig.xml中增加以下代码: <updateHandler class="solr.DirectUpdat ...

  10. Quartz:Cron Expressions

    原文地址:http://www.quartz-scheduler.net/documentation/quartz-2.x/tutorial/crontrigger.html 注意: 位也可能是7位, ...