摘要: 1 cc.Class({ 2 extends: cc.Component, 3 4 properties: { 5 donghuaNum: 10, // 构建的个数 6 ndDonghuaTemplate: cc.Node // 所要加载的骨骼 7 }, 8 9 // 本脚本需要添加到... 阅读全文
posted @ 2018-10-24 13:25 饭桶大叔 阅读(523) 评论(0) 推荐(0) 编辑
摘要: 1 cc.Class({ 2 extends: cc.Component, 3 4 properties: { 5 ndDonghuaTemplate: cc.Node 6 }, 7 8 onLoad () { 9 var armatureDisplay = this.ndDonghuaTemplate.get... 阅读全文
posted @ 2018-10-23 09:45 饭桶大叔 阅读(594) 评论(0) 推荐(0) 编辑
摘要: 1 package{ 2 //导入包 3 import flash.display.Sprite; 4 import flash.events.Event; 5 import flash.media.Sound; 6 import flash.media.SoundChannel; 7 import flash.net.URLRe... 阅读全文
posted @ 2018-10-08 13:45 饭桶大叔 阅读(400) 评论(0) 推荐(0) 编辑
摘要: 1 import requests 2 import re 3 4 content = requests.get('https://book.douban.com/').text 5 pattem = re.compile('(.*?).*?year">(.*?).*?',re.S) 6 results = re.findall(pattem, content) 7 # prin... 阅读全文
posted @ 2018-09-04 21:30 饭桶大叔 阅读(447) 评论(0) 推荐(0) 编辑
摘要: 1 import os 2 import re 3 4 zifu = [''] 5 count = 0 6 7 def traverse(f): 8 global count 9 fs = os.listdir(f) 10 for f1 in fs: 11 tmp_path = os.path.join(f,f1) 12 ... 阅读全文
posted @ 2018-09-02 12:19 饭桶大叔 阅读(113) 评论(0) 推荐(0) 编辑
摘要: 1 import urllib.request 2 url = "http://www.baidu.com/s?wd=" #get网址格式:“https://www.baidu.com/s?wd=关键字” 3 key="周杰伦" 4 key_code=urllib.request.quote(key) # 汉字编码转化 5 url_all=url+key_code ... 阅读全文
posted @ 2018-08-25 16:49 饭桶大叔 阅读(161) 评论(0) 推荐(0) 编辑
摘要: 1 import pygame 2 import time 3 import random 4 from pygame.locals import * 5 6 7 class Base(object): 8 def __init__(self, screen_temp, x, y, image_name): 9 self.x = x... 阅读全文
posted @ 2018-07-28 22:45 饭桶大叔 阅读(314) 评论(0) 推荐(0) 编辑
摘要: 1 import os 2 import re 3 4 zifu = [''] 5 count = 0 6 rootdir = 'D:\\LittleWorld\\src\\audio\\common' 7 list = os.listdir(rootdir) #列出文件夹下所有的目录与文件 8 for i in range(0,len... 阅读全文
posted @ 2018-07-28 13:16 饭桶大叔 阅读(2466) 评论(0) 推荐(0) 编辑
摘要: 1 class Person(object): 2 """人的类""" 3 def __init__(self,name): 4 super(Person,self).__init__() 5 self.name = name 6 self.gun = None # 用来保存枪对象的引用 7 ... 阅读全文
posted @ 2018-07-25 07:30 饭桶大叔 阅读(2110) 评论(0) 推荐(0) 编辑
摘要: 1 # 用来存储名片的列表 2 card_infors = [] 3 4 5 def print_menu(): 6 # 1. 打印功能提示 7 print("=" * 50) 8 print(" 名片管理系统") 9 print("1. 增加一个新名片") 10 print("2. 删除一个名称") 11 ... 阅读全文
posted @ 2018-07-22 20:11 饭桶大叔 阅读(1858) 评论(0) 推荐(0) 编辑