mirror of
https://github.com/infinitefusion/infinitefusion-e18.git
synced 2026-11-03 00:06:01 +00:00
Release 6.9.0
This commit is contained in:
-12
@@ -1,12 +0,0 @@
|
|||||||
Graphics/CustomBattlers/local_sprites/*
|
|
||||||
Graphics/Battlers/Shiny/*
|
|
||||||
|
|
||||||
Graphics/CustomBattlers/spritesheets/*
|
|
||||||
Graphics/CustomBattlers/*
|
|
||||||
Data/VERSION
|
|
||||||
infinitefusion.sh
|
|
||||||
.gitignore
|
|
||||||
Game.rxproj
|
|
||||||
.DS_Store
|
|
||||||
PBS/*
|
|
||||||
rpgmaker.sh
|
|
||||||
Generated
-15
@@ -1,15 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<module type="RUBY_MODULE" version="4">
|
|
||||||
<component name="ModuleRunConfigurationManager">
|
|
||||||
<shared />
|
|
||||||
</component>
|
|
||||||
<component name="NewModuleRootManager">
|
|
||||||
<content url="file://$MODULE_DIR$">
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/features" isTestSource="true" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/spec" isTestSource="true" />
|
|
||||||
<sourceFolder url="file://$MODULE_DIR$/test" isTestSource="true" />
|
|
||||||
</content>
|
|
||||||
<orderEntry type="inheritedJdk" />
|
|
||||||
<orderEntry type="sourceFolder" forTests="false" />
|
|
||||||
</component>
|
|
||||||
</module>
|
|
||||||
Generated
-4
@@ -1,4 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<project version="4">
|
|
||||||
<component name="ProjectRootManager" version="2" project-jdk-name="ruby-2.6.10-p210" project-jdk-type="RUBY_SDK" />
|
|
||||||
</project>
|
|
||||||
Generated
-8
@@ -1,8 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<project version="4">
|
|
||||||
<component name="ProjectModuleManager">
|
|
||||||
<modules>
|
|
||||||
<module fileurl="file://$PROJECT_DIR$/.idea/infinitefusion-e18.iml" filepath="$PROJECT_DIR$/.idea/infinitefusion-e18.iml" />
|
|
||||||
</modules>
|
|
||||||
</component>
|
|
||||||
</project>
|
|
||||||
Generated
-6
@@ -1,6 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<project version="4">
|
|
||||||
<component name="VcsDirectoryMappings">
|
|
||||||
<mapping directory="" vcs="Git" />
|
|
||||||
</component>
|
|
||||||
</project>
|
|
||||||
Generated
-76
@@ -1,76 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<project version="4">
|
|
||||||
<component name="ChangeListManager">
|
|
||||||
<list default="true" id="59b847cf-c39b-4afd-803a-38eea744d77a" name="Changes" comment="">
|
|
||||||
<change beforePath="$PROJECT_DIR$/Data/Map237.rxdata" beforeDir="false" afterPath="$PROJECT_DIR$/Data/Map237.rxdata" afterDir="false" />
|
|
||||||
<change beforePath="$PROJECT_DIR$/Data/Map276.rxdata" beforeDir="false" afterPath="$PROJECT_DIR$/Data/Map276.rxdata" afterDir="false" />
|
|
||||||
<change beforePath="$PROJECT_DIR$/Data/Map277.rxdata" beforeDir="false" afterPath="$PROJECT_DIR$/Data/Map277.rxdata" afterDir="false" />
|
|
||||||
<change beforePath="$PROJECT_DIR$/Data/MapInfos.rxdata" beforeDir="false" afterPath="$PROJECT_DIR$/Data/MapInfos.rxdata" afterDir="false" />
|
|
||||||
<change beforePath="$PROJECT_DIR$/Data/Scripts/004_Game classes/002_Game_System.rb" beforeDir="false" afterPath="$PROJECT_DIR$/Data/Scripts/004_Game classes/002_Game_System.rb" afterDir="false" />
|
|
||||||
<change beforePath="$PROJECT_DIR$/Data/Scripts/DownloadedSettings.rb" beforeDir="false" afterPath="$PROJECT_DIR$/Data/Scripts/DownloadedSettings.rb" afterDir="false" />
|
|
||||||
<change beforePath="$PROJECT_DIR$/Data/System.rxdata" beforeDir="false" afterPath="$PROJECT_DIR$/Data/System.rxdata" afterDir="false" />
|
|
||||||
<change beforePath="$PROJECT_DIR$/Data/sprites/BASE_SPRITES" beforeDir="false" afterPath="$PROJECT_DIR$/Data/sprites/BASE_SPRITES" afterDir="false" />
|
|
||||||
<change beforePath="$PROJECT_DIR$/Data/sprites/CUSTOM_SPRITES" beforeDir="false" afterPath="$PROJECT_DIR$/Data/sprites/CUSTOM_SPRITES" afterDir="false" />
|
|
||||||
</list>
|
|
||||||
<option name="SHOW_DIALOG" value="false" />
|
|
||||||
<option name="HIGHLIGHT_CONFLICTS" value="true" />
|
|
||||||
<option name="HIGHLIGHT_NON_ACTIVE_CHANGELIST" value="false" />
|
|
||||||
<option name="LAST_RESOLUTION" value="IGNORE" />
|
|
||||||
</component>
|
|
||||||
<component name="Git.Settings">
|
|
||||||
<option name="RECENT_GIT_ROOT_PATH" value="$PROJECT_DIR$" />
|
|
||||||
</component>
|
|
||||||
<component name="GitHubPullRequestSearchHistory"><![CDATA[{
|
|
||||||
"lastFilter": {
|
|
||||||
"state": "OPEN",
|
|
||||||
"assignee": "infinitefusion"
|
|
||||||
}
|
|
||||||
}]]></component>
|
|
||||||
<component name="GithubPullRequestsUISettings"><![CDATA[{
|
|
||||||
"selectedUrlAndAccountId": {
|
|
||||||
"url": "https://github.com/infinitefusion/infinitefusion-e18.git",
|
|
||||||
"accountId": "2b6eb7d6-790c-4e30-967d-bfb420050830"
|
|
||||||
}
|
|
||||||
}]]></component>
|
|
||||||
<component name="ProjectColorInfo"><![CDATA[{
|
|
||||||
"associatedIndex": 2
|
|
||||||
}]]></component>
|
|
||||||
<component name="ProjectId" id="2vRvDbTuifxaPtCcwMIlmzF9kqX" />
|
|
||||||
<component name="ProjectViewState">
|
|
||||||
<option name="hideEmptyMiddlePackages" value="true" />
|
|
||||||
<option name="showLibraryContents" value="true" />
|
|
||||||
</component>
|
|
||||||
<component name="PropertiesComponent"><![CDATA[{
|
|
||||||
"keyToString": {
|
|
||||||
"RunOnceActivity.ShowReadmeOnStart": "true",
|
|
||||||
"RunOnceActivity.git.unshallow": "true",
|
|
||||||
"git-widget-placeholder": "develop-6.6",
|
|
||||||
"last_opened_file_path": "/Users/chardub/Documents/infinitefusion/infinitefusion-release/infinitefusion-e18",
|
|
||||||
"nodejs_package_manager_path": "npm",
|
|
||||||
"vue.rearranger.settings.migration": "true"
|
|
||||||
}
|
|
||||||
}]]></component>
|
|
||||||
<component name="SharedIndexes">
|
|
||||||
<attachedChunks>
|
|
||||||
<set>
|
|
||||||
<option value="bundled-js-predefined-d6986cc7102b-822845ee3bb5-JavaScript-RM-243.23654.167" />
|
|
||||||
</set>
|
|
||||||
</attachedChunks>
|
|
||||||
</component>
|
|
||||||
<component name="SpellCheckerSettings" RuntimeDictionaries="0" Folders="0" CustomDictionaries="0" DefaultDictionary="application-level" UseSingleDictionary="true" transferred="true" />
|
|
||||||
<component name="SpringUtil" SPRING_PRE_LOADER_OPTION="true" RAKE_SPRING_PRE_LOADER_OPTION="true" RAILS_SPRING_PRE_LOADER_OPTION="true" />
|
|
||||||
<component name="TaskManager">
|
|
||||||
<task active="true" id="Default" summary="Default task">
|
|
||||||
<changelist id="59b847cf-c39b-4afd-803a-38eea744d77a" name="Changes" comment="" />
|
|
||||||
<created>1744120584178</created>
|
|
||||||
<option name="number" value="Default" />
|
|
||||||
<option name="presentableId" value="Default" />
|
|
||||||
<updated>1744120584178</updated>
|
|
||||||
<workItem from="1744120585282" duration="16000" />
|
|
||||||
</task>
|
|
||||||
<servers />
|
|
||||||
</component>
|
|
||||||
<component name="TypeScriptGeneratedFilesManager">
|
|
||||||
<option name="version" value="3" />
|
|
||||||
</component>
|
|
||||||
</project>
|
|
||||||
Vendored
BIN
Binary file not shown.
Vendored
BIN
Binary file not shown.
Binary file not shown.
Binary file not shown.
Vendored
BIN
Binary file not shown.
Vendored
BIN
Binary file not shown.
Vendored
BIN
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Vendored
BIN
Binary file not shown.
Generated
+8
@@ -0,0 +1,8 @@
|
|||||||
|
# Default ignored files
|
||||||
|
/shelf/
|
||||||
|
/workspace.xml
|
||||||
|
# Datasource local storage ignored files
|
||||||
|
/../../../../../../../../../../../:\Users\charl\Documents\Jeux\rpgmaker\infinitefusion\dev\infinitefusion-e18\Data\.idea/dataSources/
|
||||||
|
/dataSources.local.xml
|
||||||
|
# Editor-based HTTP Client requests
|
||||||
|
/httpRequests/
|
||||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Vendored
BIN
Binary file not shown.
@@ -0,0 +1,2 @@
|
|||||||
|
.idea
|
||||||
|
LocalSettings.rb
|
||||||
@@ -5,14 +5,15 @@
|
|||||||
#==============================================================================#
|
#==============================================================================#
|
||||||
module Settings
|
module Settings
|
||||||
# The version of your game. It has to adhere to the MAJOR.MINOR.PATCH format.
|
# The version of your game. It has to adhere to the MAJOR.MINOR.PATCH format.
|
||||||
GAME_VERSION_NUMBER = "6.8.3"
|
GAME_VERSION_NUMBER = "6.9"
|
||||||
LATEST_GAME_RELEASE = "6.8"
|
LATEST_GAME_RELEASE = "6.9.0"
|
||||||
|
|
||||||
HOENN_VERSION_NUMBER = "1.1.0"
|
HOENN_VERSION_NUMBER = "1.3"
|
||||||
HOENN_LATEST_GAME_RELEASE = "1.1.0"
|
HOENN_LATEST_GAME_RELEASE = "1.2.0"
|
||||||
|
|
||||||
SNOW_DAY = false
|
SNOW_DAY = true
|
||||||
|
|
||||||
|
EXPERIMENTAL_FEATURES = false
|
||||||
KANTO = GAME_ID == :IF_KANTO
|
KANTO = GAME_ID == :IF_KANTO
|
||||||
HOENN = GAME_ID == :IF_HOENN
|
HOENN = GAME_ID == :IF_HOENN
|
||||||
|
|
||||||
@@ -36,7 +37,7 @@ module Settings
|
|||||||
ANIMATE_REFLECTIONS = false # GAME_ID == :IF_HOENN #true
|
ANIMATE_REFLECTIONS = false # GAME_ID == :IF_HOENN #true
|
||||||
USE_REFLECTIONS = false
|
USE_REFLECTIONS = false
|
||||||
# Infinite fusion settings
|
# Infinite fusion settings
|
||||||
NB_POKEMON = 576
|
NB_POKEMON = 582
|
||||||
TRANSFER_BOX_DISCLAIMER_MESSAGE = ""
|
TRANSFER_BOX_DISCLAIMER_MESSAGE = ""
|
||||||
CUSTOM_BASE_SPRITES_FOLDER = "Graphics/CustomBattlers/local_sprites/BaseSprites/"
|
CUSTOM_BASE_SPRITES_FOLDER = "Graphics/CustomBattlers/local_sprites/BaseSprites/"
|
||||||
CUSTOM_BATTLERS_FOLDER = "Graphics/CustomBattlers/"
|
CUSTOM_BATTLERS_FOLDER = "Graphics/CustomBattlers/"
|
||||||
@@ -47,9 +48,13 @@ module Settings
|
|||||||
DOWNLOADED_SPRITES_FOLDER = "Graphics/temp/"
|
DOWNLOADED_SPRITES_FOLDER = "Graphics/temp/"
|
||||||
DEFAULT_SPRITE_PATH = "Graphics/Battlers/Special/000.png"
|
DEFAULT_SPRITE_PATH = "Graphics/Battlers/Special/000.png"
|
||||||
CREDITS_FILE_PATH = "Data/sprites/Sprite_Credits.csv"
|
CREDITS_FILE_PATH = "Data/sprites/Sprite_Credits.csv"
|
||||||
|
|
||||||
VERSION_FILE_PATH = "Data/VERSION"
|
VERSION_FILE_PATH = "Data/VERSION"
|
||||||
CUSTOM_SPRITES_FILE_PATH = "Data/sprites/CUSTOM_SPRITES"
|
CUSTOM_SPRITES_FILE_PATH = "Data/sprites/CUSTOM_SPRITES"
|
||||||
BASE_SPRITES_FILE_PATH = "Data/sprites/BASE_SPRITES"
|
BASE_SPRITES_FILE_PATH = "Data/sprites/BASE_SPRITES"
|
||||||
|
REFERENCES_FILE_PATH = "Data/sprites/SELECTED_REFERENCES"
|
||||||
|
|
||||||
|
|
||||||
CUSTOM_DEX_ENTRIES_PATH = "Data/pokedex/dex.json"
|
CUSTOM_DEX_ENTRIES_PATH = "Data/pokedex/dex.json"
|
||||||
AI_DEX_ENTRIES_PATH = "Data/pokedex/generated_entries.json"
|
AI_DEX_ENTRIES_PATH = "Data/pokedex/generated_entries.json"
|
||||||
POKEDEX_ENTRIES_PATH = "Data/pokedex/all_entries.json"
|
POKEDEX_ENTRIES_PATH = "Data/pokedex/all_entries.json"
|
||||||
@@ -115,11 +120,6 @@ module Settings
|
|||||||
WIKI_URL = "https://infinitefusion.fandom.com/"
|
WIKI_URL = "https://infinitefusion.fandom.com/"
|
||||||
FAQ_URL = "https://hackmd.io/@PIF-Staff/PIF-Hoenn-FAQ"
|
FAQ_URL = "https://hackmd.io/@PIF-Staff/PIF-Hoenn-FAQ"
|
||||||
|
|
||||||
AI_ENTRIES_URL = "https://ai-entries.pkmninfinitefusion.workers.dev/"
|
|
||||||
AI_ENTRIES_RATE_MAX_NB_REQUESTS = 10 # Nb. requests allowed in each time window
|
|
||||||
AI_ENTRIES_RATE_TIME_WINDOW = 120 # In seconds
|
|
||||||
AI_ENTRIES_RATE_LOG_FILE = 'Data/pokedex/dex_rate_limit.log' # Path to the log file
|
|
||||||
|
|
||||||
CUSTOMSPRITES_RATE_MAX_NB_REQUESTS = 15 # Nb. requests allowed in each time window
|
CUSTOMSPRITES_RATE_MAX_NB_REQUESTS = 15 # Nb. requests allowed in each time window
|
||||||
CUSTOMSPRITES_ENTRIES_RATE_TIME_WINDOW = 120 # In seconds
|
CUSTOMSPRITES_ENTRIES_RATE_TIME_WINDOW = 120 # In seconds
|
||||||
CUSTOMSPRITES_RATE_LOG_FILE = 'Data/sprites/sprites_rate_limit.log' # Path to the log file
|
CUSTOMSPRITES_RATE_LOG_FILE = 'Data/sprites/sprites_rate_limit.log' # Path to the log file
|
||||||
@@ -279,7 +279,7 @@ module Settings
|
|||||||
#=============================================================================
|
#=============================================================================
|
||||||
|
|
||||||
# The number of steps allowed before a Safari Zone game is over (0=infinite).
|
# The number of steps allowed before a Safari Zone game is over (0=infinite).
|
||||||
SAFARI_STEPS = 600
|
SAFARI_STEPS = Settings::KANTO ? 600 : -1
|
||||||
# The number of seconds a Bug Catching Contest lasts for (0=infinite).
|
# The number of seconds a Bug Catching Contest lasts for (0=infinite).
|
||||||
BUG_CONTEST_TIME = 20 * 60 # 20 minutes
|
BUG_CONTEST_TIME = 20 * 60 # 20 minutes
|
||||||
|
|
||||||
@@ -312,7 +312,7 @@ module Settings
|
|||||||
BADGE_FOR_FLY = 3
|
BADGE_FOR_FLY = 3
|
||||||
BADGE_FOR_STRENGTH = 5
|
BADGE_FOR_STRENGTH = 5
|
||||||
BADGE_FOR_DIVE = 9
|
BADGE_FOR_DIVE = 9
|
||||||
BADGE_FOR_WATERFALL = 9
|
BADGE_FOR_WATERFALL = 10
|
||||||
BADGE_FOR_TELEPORT = 1
|
BADGE_FOR_TELEPORT = 1
|
||||||
BADGE_FOR_BOUNCE = 8
|
BADGE_FOR_BOUNCE = 8
|
||||||
BADGE_FOR_ROCKCLIMB = 16
|
BADGE_FOR_ROCKCLIMB = 16
|
||||||
@@ -562,6 +562,8 @@ module Settings
|
|||||||
ANGRY_ANIMATION_ID = 24
|
ANGRY_ANIMATION_ID = 24
|
||||||
ANGRY_SHORT_ANIMATION_ID = 34
|
ANGRY_SHORT_ANIMATION_ID = 34
|
||||||
|
|
||||||
|
STEAM_ANIMATION = 38
|
||||||
|
|
||||||
FUSE_ANIMATION_ID = 33
|
FUSE_ANIMATION_ID = 33
|
||||||
|
|
||||||
# ID of the animation played when a patch of grass rustles due to using the
|
# ID of the animation played when a patch of grass rustles due to using the
|
||||||
@@ -584,6 +586,7 @@ module Settings
|
|||||||
CUT_TREE_ANIMATION_ID = 19
|
CUT_TREE_ANIMATION_ID = 19
|
||||||
ROCK_SMASH_ANIMATION_ID = 20
|
ROCK_SMASH_ANIMATION_ID = 20
|
||||||
|
|
||||||
|
ANIMATION_OW_ATTACK = 14
|
||||||
#=============================================================================
|
#=============================================================================
|
||||||
|
|
||||||
# An array of available languages in the game, and their corresponding message
|
# An array of available languages in the game, and their corresponding message
|
||||||
@@ -591,15 +594,17 @@ module Settings
|
|||||||
# from.
|
# from.
|
||||||
LANGUAGES = {
|
LANGUAGES = {
|
||||||
:IF_KANTO => [
|
:IF_KANTO => [
|
||||||
["English", "english.dat"],
|
["English", "english.dat", :ENGLISH],
|
||||||
["Français", "french.dat"],
|
["Français", "french.dat", :FRENCH],
|
||||||
["中文", "chinese.dat"]
|
["Français (Québec)", "french.dat", :FRENCH_QC],
|
||||||
|
["中文", "chinese.dat", :CHINESE]
|
||||||
],
|
],
|
||||||
:IF_HOENN => [
|
:IF_HOENN => [
|
||||||
["English", "english.dat"],
|
["English", "english.dat", :ENGLISH],
|
||||||
["Français", "french.dat"],
|
["Français", "french.dat",:FRENCH],
|
||||||
#["Español", "spanish.dat"],
|
["Français (Québec)", "french.dat", :FRENCH_QC],
|
||||||
["中文", "chinese.dat"]
|
#["Español", "spanish.dat", :SPANISH],
|
||||||
|
["中文", "chinese.dat", :CHINESE]
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -2,7 +2,22 @@ module Encryption
|
|||||||
ENCRYPTION_KEY = [0x4A, 0x8F, 0x2C, 0xE1, 0x73, 0xB5, 0x96, 0x0D,
|
ENCRYPTION_KEY = [0x4A, 0x8F, 0x2C, 0xE1, 0x73, 0xB5, 0x96, 0x0D,
|
||||||
0x5E, 0xA2, 0x3F, 0xC7, 0x81, 0x14, 0x6B, 0xD9]
|
0x5E, 0xA2, 0x3F, 0xC7, 0x81, 0x14, 0x6B, 0xD9]
|
||||||
|
|
||||||
|
CHUNK_SIZE = 1 << 20
|
||||||
|
|
||||||
def self.xor(data)
|
def self.xor(data)
|
||||||
data.bytes.each_with_index.map { |b, i| b ^ ENCRYPTION_KEY[i % ENCRYPTION_KEY.length] }.pack("C*")
|
key = ENCRYPTION_KEY.pack("C*")
|
||||||
|
@full_chunk_key ||= (key * (CHUNK_SIZE / key.length)).unpack1("H*").to_i(16)
|
||||||
|
full_chunk_key = @full_chunk_key
|
||||||
|
result = String.new(capacity: data.bytesize, encoding: Encoding::BINARY)
|
||||||
|
offset = 0
|
||||||
|
while offset < data.bytesize
|
||||||
|
chunk = data.byteslice(offset, CHUNK_SIZE)
|
||||||
|
size = chunk.bytesize
|
||||||
|
chunk_key = size == CHUNK_SIZE ? full_chunk_key : (key * (size / key.length + 1)).byteslice(0, size).unpack1("H*").to_i(16)
|
||||||
|
xored = chunk.unpack1("H*").to_i(16) ^ chunk_key
|
||||||
|
result << [xored.to_s(16).rjust(size * 2, "0")].pack("H*")
|
||||||
|
offset += CHUNK_SIZE
|
||||||
|
end
|
||||||
|
return result
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
@@ -39,7 +39,7 @@ end
|
|||||||
module Kernel
|
module Kernel
|
||||||
def echo(string)
|
def echo(string)
|
||||||
return unless $DEBUG
|
return unless $DEBUG
|
||||||
printf(string.is_a?(String) ? string : string.inspect)
|
printf("%s", string.is_a?(String) ? string : string.inspect)
|
||||||
end
|
end
|
||||||
|
|
||||||
def echoln(string)
|
def echoln(string)
|
||||||
|
|||||||
@@ -1,11 +1,20 @@
|
|||||||
def pbAddScriptTexts(items, script)
|
def pbAddScriptTexts(items, script)
|
||||||
script.force_encoding(Encoding::UTF_8)
|
script.force_encoding(Encoding::UTF_8)
|
||||||
|
|
||||||
script.scan(/(?:_I|sign)\s*\(\s*\"((?:[^\\\"]*\\\"?)*[^\"]*)\"/) do |s|
|
script.scan(/(?:_I|sign)\s*\(\s*\"((?:[^\\\"]*\\\"?)*[^\"]*)\"/) do |s|
|
||||||
string = s[0]
|
string = s[0]
|
||||||
string.gsub!(/\\\"/, "\"")
|
string.gsub!(/\\\"/, "\"")
|
||||||
string.gsub!(/\\\\/, "\\")
|
string.gsub!(/\\\\/, "\\")
|
||||||
items.push(string)
|
items.push(string)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
# extract pbTrainerBattle(..., "TrainerName", "LoseText", ...) in PIF1
|
||||||
|
script.scan(/pbTrainerBattle\s*\(\s*[^,]+,\s*"[^"]*"\s*,\s*"([^"]*)"/) do |s|
|
||||||
|
string = s[0]
|
||||||
|
string.gsub!(/\\\"/, "\"")
|
||||||
|
string.gsub!(/\\\\/, "\\")
|
||||||
|
items.push(string)
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
def pbAddRgssScriptTexts(items, script)
|
def pbAddRgssScriptTexts(items, script)
|
||||||
@@ -509,7 +518,6 @@ class Messages
|
|||||||
end
|
end
|
||||||
|
|
||||||
def extract(outfile)
|
def extract(outfile)
|
||||||
# return if !@messages
|
|
||||||
origMessages = Messages.new("Data/messages.dat")
|
origMessages = Messages.new("Data/messages.dat")
|
||||||
File.open(outfile, "wb") { |f|
|
File.open(outfile, "wb") { |f|
|
||||||
f.write(0xef.chr)
|
f.write(0xef.chr)
|
||||||
@@ -517,12 +525,18 @@ class Messages
|
|||||||
f.write(0xbf.chr)
|
f.write(0xbf.chr)
|
||||||
f.write("# To localize this text for a particular language, please\r\n")
|
f.write("# To localize this text for a particular language, please\r\n")
|
||||||
f.write("# translate every second line of this file.\r\n")
|
f.write("# translate every second line of this file.\r\n")
|
||||||
if origMessages.messages[0]
|
|
||||||
for i in 0...origMessages.messages[0].length
|
# Map messages use the newly collected messages in @messages.
|
||||||
msgs = origMessages.messages[0][i]
|
# This includes text extracted from map events, such as
|
||||||
|
# pbTrainerBattle(..., "Trainer", "LoseText", ...).
|
||||||
|
if @messages && @messages[0]
|
||||||
|
for i in 0...@messages[0].length
|
||||||
|
msgs = @messages[0][i]
|
||||||
Messages.writeObject(f, msgs, "Map#{i}", origMessages)
|
Messages.writeObject(f, msgs, "Map#{i}", origMessages)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
# Keep the original behavior for non-map message sections.
|
||||||
for i in 1...origMessages.messages.length
|
for i in 1...origMessages.messages.length
|
||||||
msgs = origMessages.messages[i]
|
msgs = origMessages.messages[i]
|
||||||
Messages.writeObject(f, msgs, i, origMessages)
|
Messages.writeObject(f, msgs, i, origMessages)
|
||||||
@@ -534,7 +548,7 @@ class Messages
|
|||||||
@messages = [] if !@messages
|
@messages = [] if !@messages
|
||||||
arr = []
|
arr = []
|
||||||
for i in 0...array.length
|
for i in 0...array.length
|
||||||
arr[i] = (array[i]) ? array[i] : ""
|
arr[i] = (array[i] == "") ? nil : array[i]
|
||||||
end
|
end
|
||||||
@messages[type] = arr
|
@messages[type] = arr
|
||||||
end
|
end
|
||||||
@@ -543,7 +557,8 @@ class Messages
|
|||||||
@messages = [] if !@messages
|
@messages = [] if !@messages
|
||||||
arr = (@messages[type]) ? @messages[type] : []
|
arr = (@messages[type]) ? @messages[type] : []
|
||||||
for i in 0...array.length
|
for i in 0...array.length
|
||||||
arr[i] = (array[i]) ? array[i] : (arr[i]) ? arr[i] : ""
|
arr[i] = array[i] if array[i]
|
||||||
|
arr[i] = nil if arr[i] == ""
|
||||||
end
|
end
|
||||||
@messages[type] = arr
|
@messages[type] = arr
|
||||||
end
|
end
|
||||||
@@ -751,6 +766,10 @@ module MessageTypes
|
|||||||
@@messages.loadMessageFile(filename)
|
@@messages.loadMessageFile(filename)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def self.loadFallbackMessageFile(filename)
|
||||||
|
@@messagesFallback.loadMessageFile(filename)
|
||||||
|
end
|
||||||
|
|
||||||
def self.get(type, id)
|
def self.get(type, id)
|
||||||
ret = @@messages.get(type, id)
|
ret = @@messages.get(type, id)
|
||||||
if ret == ""
|
if ret == ""
|
||||||
|
|||||||
@@ -8,18 +8,18 @@ module Input
|
|||||||
AUX1 = L
|
AUX1 = L
|
||||||
AUX2 = R
|
AUX2 = R
|
||||||
|
|
||||||
unless defined?(update_KGC_ScreenCapture)
|
# unless defined?(update_KGC_ScreenCapture)
|
||||||
class << Input
|
# class << Input
|
||||||
alias update_KGC_ScreenCapture update
|
# alias update_KGC_ScreenCapture update
|
||||||
end
|
# end
|
||||||
end
|
# end
|
||||||
|
|
||||||
def self.update
|
# def self.update
|
||||||
update_KGC_ScreenCapture
|
# update_KGC_ScreenCapture
|
||||||
if trigger?(Input::F8)
|
# if trigger?(Input::F8)
|
||||||
pbScreenCapture
|
# pbScreenCapture
|
||||||
end
|
# end
|
||||||
end
|
# end
|
||||||
end
|
end
|
||||||
|
|
||||||
module Mouse
|
module Mouse
|
||||||
|
|||||||
@@ -128,6 +128,7 @@ class SpriteAnimation
|
|||||||
end
|
end
|
||||||
|
|
||||||
def effect?
|
def effect?
|
||||||
|
return false unless @_animation_duration
|
||||||
return @_animation_duration > 0
|
return @_animation_duration > 0
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
@@ -126,6 +126,16 @@ module Game
|
|||||||
pokemon.exp_when_fused_body=nil
|
pokemon.exp_when_fused_body=nil
|
||||||
pokemon.exp_gained_since_fused=nil
|
pokemon.exp_gained_since_fused=nil
|
||||||
pokemon.level = 5
|
pokemon.level = 5
|
||||||
|
|
||||||
|
if pokemon.original_body
|
||||||
|
pokemon.original_body.level = 5
|
||||||
|
pokemon.original_body.exp_gained_with_player = 0
|
||||||
|
end
|
||||||
|
|
||||||
|
if pokemon.original_head
|
||||||
|
pokemon.original_head.level = 5
|
||||||
|
pokemon.original_head.exp_gained_with_player = 0
|
||||||
|
end
|
||||||
pokemon.pif_sprite =nil
|
pokemon.pif_sprite =nil
|
||||||
|
|
||||||
pokemon.owner.id = $Trainer.id
|
pokemon.owner.id = $Trainer.id
|
||||||
|
|||||||
@@ -145,10 +145,15 @@ class Scene_Map
|
|||||||
$game_temp.in_menu = true
|
$game_temp.in_menu = true
|
||||||
$game_player.straighten
|
$game_player.straighten
|
||||||
$game_map.update
|
$game_map.update
|
||||||
|
if $PokemonTemp.overworld_safari
|
||||||
|
caught_pokemon_icons = displayCaughtPokemonIcons
|
||||||
|
end
|
||||||
|
|
||||||
sscene = PokemonPauseMenu_Scene.new
|
sscene = PokemonPauseMenu_Scene.new
|
||||||
sscreen = PokemonPauseMenu.new(sscene)
|
sscreen = PokemonPauseMenu.new(sscene)
|
||||||
sscreen.pbStartPokemonMenu
|
sscreen.pbStartPokemonMenu
|
||||||
$game_temp.in_menu = false
|
$game_temp.in_menu = false
|
||||||
|
caught_pokemon_icons.dispose if $PokemonTemp.overworld_safari
|
||||||
end
|
end
|
||||||
|
|
||||||
def call_debug
|
def call_debug
|
||||||
|
|||||||
@@ -415,6 +415,7 @@ class Interpreter
|
|||||||
end
|
end
|
||||||
|
|
||||||
def pbPushThisBoulder
|
def pbPushThisBoulder
|
||||||
|
pbSEPlay("strength")
|
||||||
pbPushThisEvent if $PokemonMap.strengthUsed
|
pbPushThisEvent if $PokemonMap.strengthUsed
|
||||||
return true
|
return true
|
||||||
end
|
end
|
||||||
|
|||||||
@@ -523,6 +523,14 @@ class Game_Map
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def set_tile(x, y, layer, id = 0)
|
||||||
|
self.data[x, y, layer] = id
|
||||||
|
end
|
||||||
|
|
||||||
|
def erase_tile(x, y, layer)
|
||||||
|
set_tile(x, y, layer, 0)
|
||||||
|
end
|
||||||
|
|
||||||
def refresh
|
def refresh
|
||||||
for event in @events.values
|
for event in @events.values
|
||||||
event.refresh
|
event.refresh
|
||||||
|
|||||||
@@ -202,10 +202,10 @@ class PokemonMapFactory
|
|||||||
return true if thisEvent.through
|
return true if thisEvent.through
|
||||||
if thisEvent==$game_player
|
if thisEvent==$game_player
|
||||||
if !($DEBUG && Input.press?(Input::CTRL))
|
if !($DEBUG && Input.press?(Input::CTRL))
|
||||||
return false if !map.passableStrict?(x,y,0,thisEvent)
|
return false if !map.playerPassable?(x,y,0,thisEvent)
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
return false if !map.passableStrict?(x,y,0,thisEvent)
|
return false if !map.playerPassable?(x,y,0,thisEvent)
|
||||||
end
|
end
|
||||||
for event in map.events.values
|
for event in map.events.values
|
||||||
next if event == thisEvent || !event.at_coordinate?(x, y)
|
next if event == thisEvent || !event.at_coordinate?(x, y)
|
||||||
|
|||||||
@@ -23,6 +23,8 @@ class Game_Character
|
|||||||
attr_accessor :animation_id
|
attr_accessor :animation_id
|
||||||
attr_accessor :transparent
|
attr_accessor :transparent
|
||||||
attr_reader :move_speed
|
attr_reader :move_speed
|
||||||
|
attr_accessor :move_speed_override
|
||||||
|
|
||||||
attr_accessor :walk_anime
|
attr_accessor :walk_anime
|
||||||
attr_writer :bob_height
|
attr_writer :bob_height
|
||||||
attr_accessor :under_everything # under even grass
|
attr_accessor :under_everything # under even grass
|
||||||
@@ -34,6 +36,8 @@ class Game_Character
|
|||||||
attr_accessor :shadow_offset
|
attr_accessor :shadow_offset
|
||||||
attr_accessor :animation_speed
|
attr_accessor :animation_speed
|
||||||
attr_accessor :step_anime
|
attr_accessor :step_anime
|
||||||
|
|
||||||
|
attr_accessor :can_hop_cliff
|
||||||
def initialize(map = nil)
|
def initialize(map = nil)
|
||||||
@map = map
|
@map = map
|
||||||
@id = 0
|
@id = 0
|
||||||
@@ -89,6 +93,8 @@ class Game_Character
|
|||||||
@forced_bush_depth = nil
|
@forced_bush_depth = nil
|
||||||
@shadow_offset =0
|
@shadow_offset =0
|
||||||
@animation_speed = nil #override if the animation speed needs to be different from move speed
|
@animation_speed = nil #override if the animation speed needs to be different from move speed
|
||||||
|
@move_speed_override = nil
|
||||||
|
@can_hop_cliff = false
|
||||||
end
|
end
|
||||||
|
|
||||||
def at_coordinate?(check_x, check_y)
|
def at_coordinate?(check_x, check_y)
|
||||||
@@ -242,7 +248,7 @@ class Game_Character
|
|||||||
this_map = (self.map.valid?(@x, @y)) ? [self.map, @x, @y] : $MapFactory.getNewMap(@x, @y)
|
this_map = (self.map.valid?(@x, @y)) ? [self.map, @x, @y] : $MapFactory.getNewMap(@x, @y)
|
||||||
if this_map[0].deepBush?(this_map[1], this_map[2]) && self.map.deepBush?(xbehind, ybehind)
|
if this_map[0].deepBush?(this_map[1], this_map[2]) && self.map.deepBush?(xbehind, ybehind)
|
||||||
@bush_depth = Game_Map::TILE_HEIGHT
|
@bush_depth = Game_Map::TILE_HEIGHT
|
||||||
elsif !moving? && this_map[0].bush?(this_map[1], this_map[2])
|
elsif this_map[0].bush?(this_map[1], this_map[2])
|
||||||
@bush_depth = 12
|
@bush_depth = 12
|
||||||
else
|
else
|
||||||
@bush_depth = 0
|
@bush_depth = 0
|
||||||
@@ -690,6 +696,10 @@ class Game_Character
|
|||||||
@x += (dir == 4) ? -1 : (dir == 6) ? 1 : 0
|
@x += (dir == 4) ? -1 : (dir == 6) ? 1 : 0
|
||||||
@y += (dir == 8) ? -1 : (dir == 2) ? 1 : 0
|
@y += (dir == 8) ? -1 : (dir == 2) ? 1 : 0
|
||||||
increase_steps
|
increase_steps
|
||||||
|
elsif @can_hop_cliff && (pbFacingTerrainTag.is_cliff || terrain_tag.is_cliff)
|
||||||
|
@through = true
|
||||||
|
jump_forward(1)
|
||||||
|
@through = false
|
||||||
else
|
else
|
||||||
check_event_trigger_touch(dir)
|
check_event_trigger_touch(dir)
|
||||||
end
|
end
|
||||||
@@ -1286,9 +1296,21 @@ class Game_Character
|
|||||||
@stopped_this_frame = false
|
@stopped_this_frame = false
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def play_step_animation(nb_times)
|
||||||
|
return if @lock_pattern
|
||||||
|
return if @step_anime_once
|
||||||
|
@step_anime_once = true
|
||||||
|
@step_animation_nb_times = nb_times
|
||||||
|
@step_animation_current_time = 0
|
||||||
|
@step_anime_once_frame_count = 0
|
||||||
|
@old_step_anime = @step_anime
|
||||||
|
@step_anime = true
|
||||||
|
@pattern = 0
|
||||||
|
@anime_count = 0
|
||||||
|
end
|
||||||
|
|
||||||
def update_pattern
|
def update_pattern
|
||||||
return if @lock_pattern
|
return if @lock_pattern
|
||||||
# return if @jump_count > 0 # Don't animate if jumping on the spot
|
|
||||||
# Character has stopped moving, return to original pattern
|
# Character has stopped moving, return to original pattern
|
||||||
if @moved_last_frame && !@moved_this_frame && !@step_anime
|
if @moved_last_frame && !@moved_this_frame && !@step_anime
|
||||||
@pattern = @original_pattern
|
@pattern = @original_pattern
|
||||||
@@ -1301,21 +1323,33 @@ class Game_Character
|
|||||||
@anime_count = 0
|
@anime_count = 0
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
# Calculate how many frames each pattern should display for, i.e. the time
|
# Calculate how many frames each pattern should display for
|
||||||
# it takes to move half a tile (or a whole tile if cycling). We assume the
|
|
||||||
# game uses square tiles.
|
|
||||||
real_speed = (jumping?) ? jump_speed_real : move_speed_real
|
real_speed = (jumping?) ? jump_speed_real : move_speed_real
|
||||||
if @animation_speed
|
if @animation_speed
|
||||||
base = Game_Map::REAL_RES_X / 2.0
|
base = Game_Map::REAL_RES_X / 2.0
|
||||||
frames_per_pattern = base / @animation_speed
|
frames_per_pattern = base / @animation_speed
|
||||||
else
|
else
|
||||||
frames_per_pattern = Game_Map::REAL_RES_X / (real_speed * 2.0)
|
frames_per_pattern = Game_Map::REAL_RES_X / (real_speed * 2.0)
|
||||||
frames_per_pattern *= 2 if move_speed >= 5 # Cycling speed or faster
|
frames_per_pattern *= 2 if move_speed >= 5
|
||||||
end
|
end
|
||||||
return if @anime_count < frames_per_pattern
|
return if @anime_count < frames_per_pattern
|
||||||
# Advance to the next animation frame
|
# Advance to the next animation frame
|
||||||
@pattern = (@pattern + 1) % 4
|
@pattern = (@pattern + 1) % 4
|
||||||
@anime_count -= frames_per_pattern
|
@anime_count -= frames_per_pattern
|
||||||
|
advance_step_animation_once if @step_anime_once
|
||||||
|
end
|
||||||
|
|
||||||
|
def advance_step_animation_once
|
||||||
|
@step_anime_once_frame_count += 1
|
||||||
|
|
||||||
|
total_frames = @step_animation_nb_times * 4
|
||||||
|
if @step_anime_once_frame_count % 4 == 0
|
||||||
|
@pattern = 0 #loop
|
||||||
|
end
|
||||||
|
return if @step_anime_once_frame_count < total_frames
|
||||||
|
@pattern = 0
|
||||||
|
@step_anime = @old_step_anime
|
||||||
|
@step_anime_once = false
|
||||||
end
|
end
|
||||||
|
|
||||||
# def distance_from_player
|
# def distance_from_player
|
||||||
@@ -1330,6 +1364,13 @@ class Game_Character
|
|||||||
return (dx + dy) - 1
|
return (dx + dy) - 1
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def distance_from_target(target)
|
||||||
|
return Float::INFINITY if self.map_id != $game_map.map_id
|
||||||
|
dx = (@x - target.x).abs
|
||||||
|
dy = (@y - target.y).abs
|
||||||
|
return (dx + dy) - 1
|
||||||
|
end
|
||||||
|
|
||||||
def move_diagonal_freeform(distance_horizontal, distance_vertical, speed)
|
def move_diagonal_freeform(distance_horizontal, distance_vertical, speed)
|
||||||
real_dx = distance_horizontal * Game_Map::REAL_RES_X
|
real_dx = distance_horizontal * Game_Map::REAL_RES_X
|
||||||
real_dy = distance_vertical * Game_Map::REAL_RES_Y
|
real_dy = distance_vertical * Game_Map::REAL_RES_Y
|
||||||
|
|||||||
@@ -10,6 +10,8 @@ class Game_Event < Game_Character
|
|||||||
attr_reader :page
|
attr_reader :page
|
||||||
attr_reader :on_bridge
|
attr_reader :on_bridge
|
||||||
attr_accessor :refresh_hue
|
attr_accessor :refresh_hue
|
||||||
|
attr_accessor :is_rival_following
|
||||||
|
attr_accessor :forced_bush_depth
|
||||||
|
|
||||||
def initialize(map_id, event, map=nil)
|
def initialize(map_id, event, map=nil)
|
||||||
super(map)
|
super(map)
|
||||||
@@ -38,6 +40,9 @@ class Game_Event < Game_Character
|
|||||||
if @event.name[/forced_z\s*=\s*(-?\d+)/i]
|
if @event.name[/forced_z\s*=\s*(-?\d+)/i]
|
||||||
@forced_z = $1.to_i
|
@forced_z = $1.to_i
|
||||||
end
|
end
|
||||||
|
if @event.name.include?("under_player")
|
||||||
|
@under_player = true
|
||||||
|
end
|
||||||
if @event.name.include?("on_bridge")
|
if @event.name.include?("on_bridge")
|
||||||
@on_bridge = true
|
@on_bridge = true
|
||||||
end
|
end
|
||||||
@@ -45,6 +50,11 @@ class Game_Event < Game_Character
|
|||||||
refresh
|
refresh
|
||||||
end
|
end
|
||||||
|
|
||||||
|
# def forced_bush_depth=(value)
|
||||||
|
# @bush_depth = value
|
||||||
|
# update
|
||||||
|
# end
|
||||||
|
|
||||||
def through
|
def through
|
||||||
return true if @on_bridge && $PokemonGlobal.bridge <= 0
|
return true if @on_bridge && $PokemonGlobal.bridge <= 0
|
||||||
return @through
|
return @through
|
||||||
@@ -65,11 +75,23 @@ class Game_Event < Game_Character
|
|||||||
@starting = true if @list.size > 1
|
@starting = true if @list.size > 1
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def name=(value)
|
||||||
|
@event.name = value
|
||||||
|
end
|
||||||
|
|
||||||
def erase
|
def erase
|
||||||
@erased = true
|
@erased = true
|
||||||
refresh
|
refresh
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def despawn #Should only ever be called on dynamically created events
|
||||||
|
erase
|
||||||
|
$game_map.events.delete(@id)
|
||||||
|
$PokemonTemp.tempEvents&.each { |_, events| events.delete(self) }
|
||||||
|
$PokemonTemp.tempEvents&.delete_if { |_, v| v.empty? }
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
def erase_route
|
def erase_route
|
||||||
@route_erased = true
|
@route_erased = true
|
||||||
refresh
|
refresh
|
||||||
@@ -236,6 +258,9 @@ class Game_Event < Game_Character
|
|||||||
@interpreter = nil
|
@interpreter = nil
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
|
if @forced_bush_depth && @page&.graphic&.character_name == "shadow_event" #hardcoded hack for ninjakids that hide in the water...
|
||||||
|
@forced_bush_depth = false
|
||||||
|
end
|
||||||
@tile_id = @page.graphic.tile_id
|
@tile_id = @page.graphic.tile_id
|
||||||
@character_name = @page.graphic.character_name
|
@character_name = @page.graphic.character_name
|
||||||
@character_hue = @page.graphic.character_hue if @refresh_hue
|
@character_hue = @page.graphic.character_hue if @refresh_hue
|
||||||
@@ -315,4 +340,8 @@ class Game_Event < Game_Character
|
|||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
|
def is_on_water
|
||||||
|
return self.terrain_tag.can_surf
|
||||||
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
|
|||||||
@@ -74,6 +74,8 @@ class Game_Player < Game_Character
|
|||||||
if $game_player.pbTerrainTag.ice
|
if $game_player.pbTerrainTag.ice
|
||||||
reset_bike_speed
|
reset_bike_speed
|
||||||
self.move_speed = 4
|
self.move_speed = 4
|
||||||
|
elsif $game_player.move_speed_override
|
||||||
|
self.move_speed = $game_player.move_speed_override
|
||||||
elsif !@move_route_forcing && $PokemonGlobal
|
elsif !@move_route_forcing && $PokemonGlobal
|
||||||
if $PokemonGlobal.bicycle
|
if $PokemonGlobal.bicycle
|
||||||
self.move_speed = current_bicycle_speed
|
self.move_speed = current_bicycle_speed
|
||||||
|
|||||||
@@ -74,9 +74,7 @@ def moveFancy(follower,direction)
|
|||||||
newY = follower.y + deltaY
|
newY = follower.y + deltaY
|
||||||
# Move if new position is the player's, or the new position is passable,
|
# Move if new position is the player's, or the new position is passable,
|
||||||
# or the current position is not passable
|
# or the current position is not passable
|
||||||
if ($game_player.x==newX && $game_player.y==newY) ||
|
if can_move_to_new_position(newX,newY,follower)
|
||||||
pbTestPass(follower,newX,newY,0) ||
|
|
||||||
!pbTestPass(follower,follower.x,follower.y,0)
|
|
||||||
oldThrough=follower.through
|
oldThrough=follower.through
|
||||||
follower.through=true
|
follower.through=true
|
||||||
case direction
|
case direction
|
||||||
@@ -89,6 +87,13 @@ def moveFancy(follower,direction)
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def can_move_to_new_position(newX,newY, follower)
|
||||||
|
return true if ($game_player.x==newX && $game_player.y==newY)
|
||||||
|
return true if pbTestPass(follower,newX,newY,0)
|
||||||
|
return true unless !pbTestPass(follower,follower.x,follower.y,0)
|
||||||
|
return false
|
||||||
|
end
|
||||||
|
|
||||||
# Same map only
|
# Same map only
|
||||||
def jumpFancy(follower,direction,leader)
|
def jumpFancy(follower,direction,leader)
|
||||||
deltaX=(direction == 6 ? 2 : (direction == 4 ? -2 : 0))
|
deltaX=(direction == 6 ? 2 : (direction == 4 ? -2 : 0))
|
||||||
|
|||||||
@@ -44,12 +44,11 @@ class BushBitmap
|
|||||||
ret = Bitmap.new(bitmap.width, bitmap.height)
|
ret = Bitmap.new(bitmap.width, bitmap.height)
|
||||||
charheight = ret.height
|
charheight = ret.height
|
||||||
cy = charheight - depth - 2
|
cy = charheight - depth - 2
|
||||||
y = charheight
|
|
||||||
if cy >= 0
|
if cy >= 0
|
||||||
ret.blt(0, y, bitmap, Rect.new(0, y, ret.width, cy))
|
ret.blt(0, 0, bitmap, Rect.new(0, 0, ret.width, cy))
|
||||||
ret.blt(0, y + cy, bitmap, Rect.new(0, y + cy, ret.width, 2), 170)
|
ret.blt(0, cy, bitmap, Rect.new(0, cy, ret.width, 2), 170)
|
||||||
end
|
end
|
||||||
ret.blt(0, y + cy + 2, bitmap, Rect.new(0, y + cy + 2, ret.width, 2), 85) if cy + 2 >= 0
|
ret.blt(0, cy + 2, bitmap, Rect.new(0, cy + 2, ret.width, 2), 85) if cy + 2 >= 0
|
||||||
return ret
|
return ret
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
@@ -263,7 +262,8 @@ class Sprite_Character < RPG::Sprite
|
|||||||
self.bitmap = (@charbitmapAnimated) ? @charbitmap.bitmap : @charbitmap
|
self.bitmap = (@charbitmapAnimated) ? @charbitmap.bitmap : @charbitmap
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
@bushbitmap = BushBitmap.new(@charbitmap, (@tile_id >= 384), bushdepth) if !@bushbitmap
|
source = (@character == $game_player) ? getClothedPlayerSprite() : (@charbitmapAnimated ? @charbitmap.bitmap : @charbitmap)
|
||||||
|
@bushbitmap = BushBitmap.new(source, (@tile_id >= 384), bushdepth) if !@bushbitmap
|
||||||
self.bitmap = @bushbitmap.bitmap
|
self.bitmap = @bushbitmap.bitmap
|
||||||
end
|
end
|
||||||
self.visible = !@character.transparent
|
self.visible = !@character.transparent
|
||||||
|
|||||||
@@ -25,7 +25,7 @@ class Particle_Engine
|
|||||||
"flare" => Particle_Engine::Flare,
|
"flare" => Particle_Engine::Flare,
|
||||||
"splash" => Particle_Engine::Splash,
|
"splash" => Particle_Engine::Splash,
|
||||||
# By Peter O.
|
# By Peter O.
|
||||||
"starteleport" => Particle_Engine::StarTeleport
|
"starteleport" => Particle_Engine::StarTeleport,
|
||||||
}
|
}
|
||||||
end
|
end
|
||||||
|
|
||||||
@@ -373,14 +373,12 @@ end
|
|||||||
class Particle_Engine::Smoke < ParticleEffect_Event
|
class Particle_Engine::Smoke < ParticleEffect_Event
|
||||||
def initialize(event, viewport)
|
def initialize(event, viewport)
|
||||||
super
|
super
|
||||||
setParameters([0, 0, 0, 80, 20, 0.5, -64,
|
setParameters([0, 0, 0, 30, 20, 0.5, -64,
|
||||||
Graphics.height, -64, Graphics.width, 0.5, 0.10, -5, -15, 5, 80])
|
Graphics.height, -64, Graphics.width, 0.5, 0.05, -5, -15, 5, 80])
|
||||||
initParticles("smoke", 250)
|
initParticles("smoke", 100)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
class Particle_Engine::Teleport < ParticleEffect_Event
|
class Particle_Engine::Teleport < ParticleEffect_Event
|
||||||
def initialize(event, viewport)
|
def initialize(event, viewport)
|
||||||
super
|
super
|
||||||
|
|||||||
@@ -201,6 +201,36 @@ class TilemapRenderer
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#path: 276 -
|
||||||
|
EMPTY_TILE = 0
|
||||||
|
GROUND_SNOW_TILE = 418
|
||||||
|
TILESET_SUPPORTING_SNOW_TREES = [1,2,5,7,8,9,12,13,15,34]
|
||||||
|
SNOW_SUBSTITUTIONS = {
|
||||||
|
#Trees
|
||||||
|
864 =>868, 865=>869,
|
||||||
|
872=>876, 873=>877,
|
||||||
|
880=>884, 881=>885,
|
||||||
|
866=>870, 867=>871,
|
||||||
|
874=>878, 875=>879,
|
||||||
|
#Grass
|
||||||
|
424=> GROUND_SNOW_TILE, 425 => GROUND_SNOW_TILE,426=> GROUND_SNOW_TILE,427=> GROUND_SNOW_TILE,
|
||||||
|
432=> GROUND_SNOW_TILE,433=> GROUND_SNOW_TILE,434=> GROUND_SNOW_TILE,435=> GROUND_SNOW_TILE,
|
||||||
|
440=> GROUND_SNOW_TILE,441=> GROUND_SNOW_TILE,442=> GROUND_SNOW_TILE,443=> GROUND_SNOW_TILE,
|
||||||
|
448=> GROUND_SNOW_TILE,449=> GROUND_SNOW_TILE,450=> GROUND_SNOW_TILE,451=>GROUND_SNOW_TILE,
|
||||||
|
|
||||||
|
# grass details, flowers,
|
||||||
|
1009=>GROUND_SNOW_TILE, 1010=>GROUND_SNOW_TILE,
|
||||||
|
992=>GROUND_SNOW_TILE, 993=>GROUND_SNOW_TILE,
|
||||||
|
|
||||||
|
#Ledges
|
||||||
|
1352=>1357,1353=>1358,1354=>1359,1355=>1350,1356=>1351,
|
||||||
|
1360=>1365, 1361=>1366,1362=>1367,
|
||||||
|
1368 =>1373, 1369=>1374, 1370=>1375,
|
||||||
|
}
|
||||||
|
# SNOW_TREES_TILES = [864,865,872,873,880,881,
|
||||||
|
# 866,867,874,875]
|
||||||
|
|
||||||
|
|
||||||
WIND_TREE_AUTOTILES = {
|
WIND_TREE_AUTOTILES = {
|
||||||
1 => { # Route-field
|
1 => { # Route-field
|
||||||
864 => "tree_sway_single_1",
|
864 => "tree_sway_single_1",
|
||||||
@@ -327,6 +357,20 @@ class TilemapRenderer
|
|||||||
875 => "tree_sway_group_4",
|
875 => "tree_sway_group_4",
|
||||||
},
|
},
|
||||||
|
|
||||||
|
36 => { # Route-tropical
|
||||||
|
832 => "tree_sway_tropical_single_1",
|
||||||
|
833 => "tree_sway_tropical_single_2",
|
||||||
|
840 => "tree_sway_tropical_single_3",
|
||||||
|
841 => "tree_sway_tropical_single_4",
|
||||||
|
848 => "tree_sway_tropical_single_5",
|
||||||
|
889 => "tree_sway_tropical_single_6",
|
||||||
|
|
||||||
|
834 => "tree_sway_tropical_group_1",
|
||||||
|
835 => "tree_sway_tropical_group_2",
|
||||||
|
842 => "tree_sway_tropical_group_3",
|
||||||
|
843 => "tree_sway_tropical_group_4",
|
||||||
|
},
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#=============================================================================
|
#=============================================================================
|
||||||
@@ -694,9 +738,28 @@ class TilemapRenderer
|
|||||||
end
|
end
|
||||||
|
|
||||||
INVISIBLE_WALL_TILE_ID = 384
|
INVISIBLE_WALL_TILE_ID = 384
|
||||||
|
def get_snow_tile_id(tile_id, current_tileset)
|
||||||
|
return tile_id unless Settings::HOENN
|
||||||
|
return tile_id unless TILESET_SUPPORTING_SNOW_TREES.include?(current_tileset)
|
||||||
|
return tile_id unless Settings::SNOW_DAY
|
||||||
|
return tile_id unless SNOW_SUBSTITUTIONS.include?(tile_id)
|
||||||
|
return SNOW_SUBSTITUTIONS[tile_id]
|
||||||
|
end
|
||||||
|
|
||||||
|
def check_hoenn_safari_flowers(tile_id)
|
||||||
|
replacement_tile = EMPTY_TILE
|
||||||
|
safari_flower_tiles = [987,998]
|
||||||
|
return tile_id unless Settings::HOENN
|
||||||
|
return tile_id unless HOENN_SAFARI_MAPS.include?(@current_map_id)
|
||||||
|
return tile_id if $game_switches[SWITCH_SAFARI_FLOWERS_PLANTED]
|
||||||
|
return tile_id unless safari_flower_tiles.include?(tile_id)
|
||||||
|
echoln "deleting flowers!"
|
||||||
|
return replacement_tile
|
||||||
|
end
|
||||||
|
|
||||||
def refresh_tile_bitmap(tile, map, tile_id)
|
def refresh_tile_bitmap(tile, map, tile_id)
|
||||||
tile.tile_id = tile_id
|
tile.tile_id = tile_id
|
||||||
|
original_id = tile_id
|
||||||
if tile_id < TILES_PER_AUTOTILE || (Settings::HOENN && tile_id == INVISIBLE_WALL_TILE_ID)
|
if tile_id < TILES_PER_AUTOTILE || (Settings::HOENN && tile_id == INVISIBLE_WALL_TILE_ID)
|
||||||
tile.set_bitmap("", tile_id, false, false, 0, nil)
|
tile.set_bitmap("", tile_id, false, false, 0, nil)
|
||||||
tile.shows_reflection = false
|
tile.shows_reflection = false
|
||||||
@@ -716,7 +779,6 @@ class TilemapRenderer
|
|||||||
# true_tileset_start_id += single_autotile_count
|
# true_tileset_start_id += single_autotile_count
|
||||||
# end
|
# end
|
||||||
|
|
||||||
filename = nil
|
|
||||||
extra_autotile_hash = get_autotile_overrides(map.tileset_id, map.map_id)
|
extra_autotile_hash = get_autotile_overrides(map.tileset_id, map.map_id)
|
||||||
|
|
||||||
if extra_autotile_hash && extra_autotile_hash[tile_id]
|
if extra_autotile_hash && extra_autotile_hash[tile_id]
|
||||||
@@ -740,6 +802,15 @@ class TilemapRenderer
|
|||||||
filename = map.tileset_name
|
filename = map.tileset_name
|
||||||
tile.set_bitmap(filename, tile_id, false, false, priority, @tilesets[filename])
|
tile.set_bitmap(filename, tile_id, false, false, priority, @tilesets[filename])
|
||||||
end
|
end
|
||||||
|
tile_id = get_snow_tile_id(tile_id,map.tileset_id) #returns the original tile if no snow
|
||||||
|
tile_id = check_hoenn_safari_flowers(tile_id) #Removes flowers in safari if not unlocked all zones
|
||||||
|
if tile_id == EMPTY_TILE
|
||||||
|
tile.set_bitmap("", original_id, false, false, 0, nil)
|
||||||
|
tile.shows_reflection = false
|
||||||
|
tile.underwater_tile = false
|
||||||
|
tile.bridge = false
|
||||||
|
return
|
||||||
|
end
|
||||||
|
|
||||||
tile.shows_reflection = terrain_tag_data&.shows_reflections
|
tile.shows_reflection = terrain_tag_data&.shows_reflections
|
||||||
tile.underwater_tile = terrain_tag_data&.underwater
|
tile.underwater_tile = terrain_tag_data&.underwater
|
||||||
|
|||||||
@@ -431,7 +431,7 @@ end
|
|||||||
|
|
||||||
def pbDisplayCosmeticsMoneyWindow(msgwindow,x=nil,y=nil)
|
def pbDisplayCosmeticsMoneyWindow(msgwindow,x=nil,y=nil)
|
||||||
moneyString = pbGetCosmeticsMoneyString()
|
moneyString = pbGetCosmeticsMoneyString()
|
||||||
goldwindow = Window_AdvancedTextPokemon.new(_INTL("{2}:\n<ar>{1}</ar>", moneyString,COSMETIC_CURRENCY_NAME))
|
goldwindow = Window_AdvancedTextPokemon.new(_INTL("{2}:\n<ar>{1}</ar>", moneyString, get_cosmetic_currency_name))
|
||||||
goldwindow.setSkin("Graphics/Windowskins/goldskin")
|
goldwindow.setSkin("Graphics/Windowskins/goldskin")
|
||||||
goldwindow.resizeToFit(goldwindow.text, Graphics.width)
|
goldwindow.resizeToFit(goldwindow.text, Graphics.width)
|
||||||
goldwindow.width = 160 if goldwindow.width <= 160
|
goldwindow.width = 160 if goldwindow.width <= 160
|
||||||
@@ -648,6 +648,16 @@ def pbMessageDisplay(msgwindow, message, letterbyletter = true, commandProc = ni
|
|||||||
text.gsub!(/\\pog/i, "")
|
text.gsub!(/\\pog/i, "")
|
||||||
text.gsub!(/\\b/i, "<c3=3050C8,D0D0C8>")
|
text.gsub!(/\\b/i, "<c3=3050C8,D0D0C8>")
|
||||||
text.gsub!(/\\r/i, "<c3=E00808,D0D0C8>")
|
text.gsub!(/\\r/i, "<c3=E00808,D0D0C8>")
|
||||||
|
|
||||||
|
text.gsub!("<-","←")
|
||||||
|
text.gsub!("->","→")
|
||||||
|
text.gsub!("<arr_left>","←")
|
||||||
|
text.gsub!("<arr_right>","→")
|
||||||
|
text.gsub!("<arr_down>","↓")
|
||||||
|
text.gsub!("<arr_up>","↑")
|
||||||
|
text.gsub!("<arr_down>","↓")
|
||||||
|
|
||||||
|
|
||||||
text.gsub!(/\\mu\[(.*?)\]/i) do
|
text.gsub!(/\\mu\[(.*?)\]/i) do
|
||||||
$Trainer && isPlayerMale() ? $1 : ""
|
$Trainer && isPlayerMale() ? $1 : ""
|
||||||
end
|
end
|
||||||
@@ -948,6 +958,7 @@ def pbMessage(message, commands = nil, cmdIfCancel = 0, skin = nil, defaultCmd =
|
|||||||
end
|
end
|
||||||
|
|
||||||
def pbMessageNoSound(message, commands = nil, cmdIfCancel = 0, skin = nil, defaultCmd = 0, &block)
|
def pbMessageNoSound(message, commands = nil, cmdIfCancel = 0, skin = nil, defaultCmd = 0, &block)
|
||||||
|
echoln message
|
||||||
ret = 0
|
ret = 0
|
||||||
msgwindow = pbCreateMessageWindow(nil, skin)
|
msgwindow = pbCreateMessageWindow(nil, skin)
|
||||||
if commands
|
if commands
|
||||||
|
|||||||
@@ -264,6 +264,15 @@ GameData::Evolution.register({
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|
||||||
|
GameData::Evolution.register({
|
||||||
|
:id => :ReversersLevel,
|
||||||
|
:parameter => Integer,
|
||||||
|
:level_up_proc => proc { |pkmn, parameter|
|
||||||
|
next pkmn.level >= parameter #TODO
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
GameData::Evolution.register({
|
GameData::Evolution.register({
|
||||||
:id => :Happiness,
|
:id => :Happiness,
|
||||||
:minimum_level => 1, # Needs any level up
|
:minimum_level => 1, # Needs any level up
|
||||||
|
|||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user