This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/**************************************************************************** | |
Copyright (c) 2010-2012 cocos2d-x.org | |
Copyright (c) 2008-2010 Ricardo Quesada | |
Copyright (c) 2011 Zynga Inc. | |
http://www.cocos2d-x.org | |
Permission is hereby granted, free of charge, to any person obtaining a copy | |
of this software and associated documentation files (the "Software"), to deal | |
in the Software without restriction, including without limitation the rights |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require("jsb.js"); | |
try { | |
director = cc.Director.getInstance(); | |
winSize = director.getWinSize(); | |
centerPos = cc.p(winSize.width / 2, winSize.height / 2); | |
var IconSprite = cc.Sprite.extend({ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
adb shell screencap -p /sdcard/screen$1.png | |
adb pull /sdcard/screen$1.png | |
adb shell rm /sdcard/screen$1.png |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require("jsb.js"); | |
try { | |
director = cc.Director.getInstance(); | |
winSize = director.getWinSize(); | |
centerPos = cc.p( winSize.width/2, winSize.height/2 ); | |
var Person = cc.Node.extend({ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require("jsb.js"); | |
try { | |
director = cc.Director.getInstance(); | |
winSize = director.getWinSize(); | |
centerPos = cc.p( winSize.width/2, winSize.height/2 ); | |
var GameLayer = cc.Layer.extend({ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def add_resources(proj): | |
test01 = proj.get_or_create_group("test01") | |
resources = proj.get_or_create_group("Resources", parent=test01) | |
# res = proj.get_or_create_group("res", parent=resources) | |
proj.add_folder("test01/Resources/res", parent=resources) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from mod_pbxproj import XcodeProject | |
if __name__ == '__main__': | |
proj = XcodeProject.Load('test01.xcodeproj/project.pbxproj') | |
test01 = proj.get_or_create_group("test01") | |
resources = proj.get_or_create_group("Resources", parent=test01) | |
proj.add_file("hoge/a.txt", parent=resources) | |
proj.backup() | |
proj.save() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<dict> | |
<key>name</key> | |
<string>Block Cursor</string> | |
<key>scope</key> | |
<string>block_cursor</string> | |
<key>settings</key> | |
<dict> | |
<key>foreground</key> | |
<string>#FFFFFF</string> | |
<key>background</key> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var Seasons = function(){ | |
this.name = "keisuke hata"; | |
} | |
Seasons.prototype.sayHello = function() { | |
print("こんにちは!!"); | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//------------------------------------------------------------------ | |
// | |
// JavaScript sample | |
// | |
//------------------------------------------------------------------ | |
// | |
// For a more complete sample, see "JS Watermelon With Me" bundled with cocos2d-iphone | |
// |