Commit 2a2cbaa9 authored by 神楽坂玲奈's avatar 神楽坂玲奈

0.8.2

parent cd38339e
......@@ -14,22 +14,22 @@ def list(path)
next if file == "." or file == ".."
result << "#{path}/#{file}"
result.concat list(result.last) if File.directory? result.last
end
end rescue p $!
result
end
spec = Gem::Specification.new do |s|
s.name = 'mycard'
s.version = '0.7.4'
s.version = '0.8.2'
s.extra_rdoc_files = ['README.txt', 'LICENSE.txt']
s.summary = 'a card game'
s.description = s.summary
s.author = 'zh99998'
s.email = 'zh99998@gmail.com'
s.homepage = 'http://card.touhou,cc'
s.homepage = 'http://my-card.in'
# s.executables = ['your_executable_here']
s.files = %w(LICENSE.txt README.txt replay)
%w{lib audio data fonts graphics ygocore}.each{|dir|s.files.concat list(dir)}
s.files = %w(LICENSE.txt README.txt config.yml replay)
%w{lib audio data fonts locales graphics ygocore}.each{|dir|s.files.concat list(dir)}
if Windows
s.files += %w(mycard.exe) + list("ruby")
else
......@@ -43,7 +43,7 @@ Gem::PackageTask.new(spec) do |p|
p.gem_spec = spec
if Windows
p.need_zip = true
p.zip_command = '../7z.exe a'
p.zip_command = '7z a'
def p.zip_file
"#{package_name}-win32.7z"
end
......@@ -61,4 +61,4 @@ Rake::RDocTask.new do |rdoc|
rdoc.options << '--line-numbers'
end
CLOBBER.include %w(error-程序出错请到论坛反馈.txt log.log profile.log config.yml doc ygocore/pics) + list('replay') + list('ygocore/replay') + list('.').keep_if{|file|File.basename(file) == "Thumbs.db"} + list("graphics/avatars").keep_if{|file|File.basename(file) =~ /.*_(?:small|middle|large)\.png/} + list("ygocore/deck").keep_if{|file|File.basename(file) != 'sample.ydk'}
CLOBBER.include %w(error-程序出错请到论坛反馈.txt log.log profile.log config.yml doc ygocore/pics) + list('replay') + list('ygocore/replay') + list('.').keep_if{|file|File.basename(file) == "Thumbs.db"} + list("graphics/avatars").reject{|file|File.basename(file) =~ /(?:error|loading)_(?:small|middle|large)\.png/} + list("ygocore/deck").keep_if{|file|File.basename(file) != 'sample.ydk'}
......@@ -16,23 +16,26 @@ class Scene_Lobby < Scene
require_relative 'chatmessage'
require_relative 'scene_duel'
attr_reader :chat_window
def start
WM::set_caption("MyCard v#{Update::Version} - #{$config['game']} - #{$game.user.name}(#{$game.user.id})", "MyCard")
$game.refresh
@background = Graphics.load('lobby', 'background', false)
Surface.blit(@background,0,0,0,0,$screen,0,0)
@userlist = Window_UserList.new(24,204,$game.users)
@roomlist = Window_RoomList.new(320,50,$game.rooms)
@userinfo = Window_UserInfo.new(24,24, $game.user)
@host_window = Window_LobbyButtons.new(678,18)
Surface.blit(@background, 0, 0, 0, 0, $screen, 0, 0)
@userlist = Window_UserList.new(24, 204, $game.users)
@roomlist = Window_RoomList.new(320, 50, $game.rooms)
@userinfo = Window_UserInfo.new(24, 24, $game.user)
@host_window = Window_LobbyButtons.new(678, 18)
@active_window = @roomlist
@chat_window = Window_Chat.new(313,$config['screen']['height'] - 225,698,212)
@chat_window = Window_Chat.new(313, $config['screen']['height'] - 225, 698, 212)
@count = 0
super
end
def bgm
"lobby.ogg"
end
def handle(event)
case event
when Event::KeyDown
......@@ -62,10 +65,12 @@ class Scene_Lobby < Scene
case event
when Game_Event::AllUsers
@userlist.items = $game.users
when Game_Event::AllRooms
@roomlist.items = $game.rooms.find_all{|room|$game.filter[:servers].collect{|server|server.id}.include?(room.server_id)}
when Game_Event::AllServers
@roomlist.items = $game.rooms.find_all{|room|$game.filter[:servers].collect{|server|server.id}.include?(room.server_id)}
when Game_Event::AllRooms, Game_Event::AllServers
@roomlist.items = $game.rooms.find_all { |room|
$game.filter[:servers].collect { |server| server.id }.include?(room.server_id) and
$game.filter[:waiting_only] ? (room.status == :wait) : true and
$game.filter[:normal_only] ? (!room.tag? && (room.ot == 0) && (room.lp = 8000)) : true
}
when Game_Event::Join
join(event.room)
when Game_Event::Watch
......@@ -77,9 +82,11 @@ class Scene_Lobby < Scene
super
end
end
def join(room)
$scene = Scene_Duel.new(room)
end
def update
@chat_window.update
@host_window.update
......@@ -91,6 +98,7 @@ class Scene_Lobby < Scene
@count += 1
super
end
def terminate
unless $scene.is_a? Scene_Lobby or $scene.is_a? Scene_Duel
$game.exit
......
......@@ -2,7 +2,7 @@ require 'open-uri'
require "fileutils"
require_relative 'card'
module Update
Version = '0.8.1'
Version = '0.8.2'
URL = "http://my-card.in/mycard/update.json?version=#{Version}"
class <<self
attr_reader :thumbnails, :images, :status
......
......@@ -77,7 +77,7 @@ class Ygocore < Game
def connect
@recv = Thread.new do
EventMachine::run {
EventMachine::connect "localhost", 9997, Client
EventMachine::connect "mycard-server.my-card.in", 9997, Client
}
end
end
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment