rmxp_extractor 1.5 → 1.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: b63899096f9136c36378ef0b363b2cc6d892b4579e20e5351d1fb469fdd82ce8
4
- data.tar.gz: 94609315dc2fd04673a2b45ea18f4592531ab9cd3e04901591805494ecad0cb0
3
+ metadata.gz: e9f2e792fc1cd81d77516c66cfc75fc4166c95eb975bbb6e7b83b022900de43c
4
+ data.tar.gz: bb960e6fcbeb2a796564f49e9ad24b1f88f4cf2090396ef6c17d5f785349b8ea
5
5
  SHA512:
6
- metadata.gz: 5d804f69c513d1b7520cd0c89392a437ee8e4bca412fd09726dc69c869adf265b03b0ce1bfd103b8df510e4f7c52e5b0f895a991ba4d88277795dfdedab85baa
7
- data.tar.gz: db5174d906af588d006f2ede79c747b591f9df54030ba417630729fc83c9624e76d0553973416905411bd2fe9879e0e998e31e9b5b149f0d47caa7d842aeaa05
6
+ metadata.gz: 4b8d7c04cdb9759d940b85362b6f43080f3fafe06e993484d4b56b0dc331d0315fb50e91265be6c13244e27c59438ca00cf2d472fa084a045b962e2dbb67a431
7
+ data.tar.gz: 76ad5fb483596b5a9fa085858d726fede1a2d091dc247b85d17af2b12f0f19d11f6025669f41571cc4edc3b9f347b4f04f2a08fdc21aa584b7dc316ba05b3794
data/CODE_OF_CONDUCT.md CHANGED
@@ -1,74 +1,74 @@
1
- # Contributor Covenant Code of Conduct
2
-
3
- ## Our Pledge
4
-
5
- In the interest of fostering an open and welcoming environment, we as
6
- contributors and maintainers pledge to making participation in our project and
7
- our community a harassment-free experience for everyone, regardless of age, body
8
- size, disability, ethnicity, gender identity and expression, level of experience,
9
- nationality, personal appearance, race, religion, or sexual identity and
10
- orientation.
11
-
12
- ## Our Standards
13
-
14
- Examples of behavior that contributes to creating a positive environment
15
- include:
16
-
17
- * Using welcoming and inclusive language
18
- * Being respectful of differing viewpoints and experiences
19
- * Gracefully accepting constructive criticism
20
- * Focusing on what is best for the community
21
- * Showing empathy towards other community members
22
-
23
- Examples of unacceptable behavior by participants include:
24
-
25
- * The use of sexualized language or imagery and unwelcome sexual attention or
26
- advances
27
- * Trolling, insulting/derogatory comments, and personal or political attacks
28
- * Public or private harassment
29
- * Publishing others' private information, such as a physical or electronic
30
- address, without explicit permission
31
- * Other conduct which could reasonably be considered inappropriate in a
32
- professional setting
33
-
34
- ## Our Responsibilities
35
-
36
- Project maintainers are responsible for clarifying the standards of acceptable
37
- behavior and are expected to take appropriate and fair corrective action in
38
- response to any instances of unacceptable behavior.
39
-
40
- Project maintainers have the right and responsibility to remove, edit, or
41
- reject comments, commits, code, wiki edits, issues, and other contributions
42
- that are not aligned to this Code of Conduct, or to ban temporarily or
43
- permanently any contributor for other behaviors that they deem inappropriate,
44
- threatening, offensive, or harmful.
45
-
46
- ## Scope
47
-
48
- This Code of Conduct applies both within project spaces and in public spaces
49
- when an individual is representing the project or its community. Examples of
50
- representing a project or community include using an official project e-mail
51
- address, posting via an official social media account, or acting as an appointed
52
- representative at an online or offline event. Representation of a project may be
53
- further defined and clarified by project maintainers.
54
-
55
- ## Enforcement
56
-
57
- Instances of abusive, harassing, or otherwise unacceptable behavior may be
58
- reported by contacting the project team at matthew@nowaffles.com. All
59
- complaints will be reviewed and investigated and will result in a response that
60
- is deemed necessary and appropriate to the circumstances. The project team is
61
- obligated to maintain confidentiality with regard to the reporter of an incident.
62
- Further details of specific enforcement policies may be posted separately.
63
-
64
- Project maintainers who do not follow or enforce the Code of Conduct in good
65
- faith may face temporary or permanent repercussions as determined by other
66
- members of the project's leadership.
67
-
68
- ## Attribution
69
-
70
- This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
71
- available at [https://contributor-covenant.org/version/1/4][version]
72
-
73
- [homepage]: https://contributor-covenant.org
74
- [version]: https://contributor-covenant.org/version/1/4/
1
+ # Contributor Covenant Code of Conduct
2
+
3
+ ## Our Pledge
4
+
5
+ In the interest of fostering an open and welcoming environment, we as
6
+ contributors and maintainers pledge to making participation in our project and
7
+ our community a harassment-free experience for everyone, regardless of age, body
8
+ size, disability, ethnicity, gender identity and expression, level of experience,
9
+ nationality, personal appearance, race, religion, or sexual identity and
10
+ orientation.
11
+
12
+ ## Our Standards
13
+
14
+ Examples of behavior that contributes to creating a positive environment
15
+ include:
16
+
17
+ * Using welcoming and inclusive language
18
+ * Being respectful of differing viewpoints and experiences
19
+ * Gracefully accepting constructive criticism
20
+ * Focusing on what is best for the community
21
+ * Showing empathy towards other community members
22
+
23
+ Examples of unacceptable behavior by participants include:
24
+
25
+ * The use of sexualized language or imagery and unwelcome sexual attention or
26
+ advances
27
+ * Trolling, insulting/derogatory comments, and personal or political attacks
28
+ * Public or private harassment
29
+ * Publishing others' private information, such as a physical or electronic
30
+ address, without explicit permission
31
+ * Other conduct which could reasonably be considered inappropriate in a
32
+ professional setting
33
+
34
+ ## Our Responsibilities
35
+
36
+ Project maintainers are responsible for clarifying the standards of acceptable
37
+ behavior and are expected to take appropriate and fair corrective action in
38
+ response to any instances of unacceptable behavior.
39
+
40
+ Project maintainers have the right and responsibility to remove, edit, or
41
+ reject comments, commits, code, wiki edits, issues, and other contributions
42
+ that are not aligned to this Code of Conduct, or to ban temporarily or
43
+ permanently any contributor for other behaviors that they deem inappropriate,
44
+ threatening, offensive, or harmful.
45
+
46
+ ## Scope
47
+
48
+ This Code of Conduct applies both within project spaces and in public spaces
49
+ when an individual is representing the project or its community. Examples of
50
+ representing a project or community include using an official project e-mail
51
+ address, posting via an official social media account, or acting as an appointed
52
+ representative at an online or offline event. Representation of a project may be
53
+ further defined and clarified by project maintainers.
54
+
55
+ ## Enforcement
56
+
57
+ Instances of abusive, harassing, or otherwise unacceptable behavior may be
58
+ reported by contacting the project team at matthew@nowaffles.com. All
59
+ complaints will be reviewed and investigated and will result in a response that
60
+ is deemed necessary and appropriate to the circumstances. The project team is
61
+ obligated to maintain confidentiality with regard to the reporter of an incident.
62
+ Further details of specific enforcement policies may be posted separately.
63
+
64
+ Project maintainers who do not follow or enforce the Code of Conduct in good
65
+ faith may face temporary or permanent repercussions as determined by other
66
+ members of the project's leadership.
67
+
68
+ ## Attribution
69
+
70
+ This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
71
+ available at [https://contributor-covenant.org/version/1/4][version]
72
+
73
+ [homepage]: https://contributor-covenant.org
74
+ [version]: https://contributor-covenant.org/version/1/4/
data/Gemfile CHANGED
@@ -1,13 +1,13 @@
1
- source "https://rubygems.org"
2
-
3
- # Specify your gem's dependencies in rmxp_extractor.gemspec
4
- gemspec
5
-
6
- gem "oj"
7
- gem "ruby-progressbar"
8
- gem "fileutils"
9
- gem "pathname"
10
- gem "zlib"
11
- gem "json"
12
- gem "yaml"
13
- gem "amazing_print"
1
+ source "https://rubygems.org"
2
+
3
+ # Specify your gem's dependencies in rmxp_extractor.gemspec
4
+ gemspec
5
+
6
+ gem "oj"
7
+ gem "ruby-progressbar"
8
+ gem "fileutils"
9
+ gem "pathname"
10
+ gem "zlib"
11
+ gem "json"
12
+ gem "yaml"
13
+ gem "amazing_print"
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- rmxp_extractor (1.5)
4
+ rmxp_extractor (1.7)
5
5
  fileutils
6
6
  json
7
7
  oj
@@ -22,6 +22,7 @@ GEM
22
22
  zlib (2.1.1)
23
23
 
24
24
  PLATFORMS
25
+ x64-mingw-ucrt
25
26
  x86_64-linux
26
27
 
27
28
  DEPENDENCIES
data/LICENSE.txt CHANGED
@@ -1,21 +1,21 @@
1
- The MIT License (MIT)
2
-
3
- Copyright (c) 2021 Speak2Erase
4
-
5
- Permission is hereby granted, free of charge, to any person obtaining a copy
6
- of this software and associated documentation files (the "Software"), to deal
7
- in the Software without restriction, including without limitation the rights
8
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
- copies of the Software, and to permit persons to whom the Software is
10
- furnished to do so, subject to the following conditions:
11
-
12
- The above copyright notice and this permission notice shall be included in
13
- all copies or substantial portions of the Software.
14
-
15
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
- THE SOFTWARE.
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2021 Speak2Erase
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in
13
+ all copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
+ THE SOFTWARE.
data/README.md CHANGED
@@ -1,35 +1,35 @@
1
- # RMXP-Extractor
2
-
3
- A tool designed to dump rxdata to various git compatible formats. Some work better than others, though.
4
- YAML is slow in comparison to JSON. I'd suggest sticking to JSON generally.
5
-
6
- Originally, I used a complex monkey patched system to dump things to a hash that was very slow and imprecise.
7
- Now, it uses some neat tricks to do it relatively efficiently.
8
-
9
- Only problem is, classes dumped or loaded dump their instance variables, meaning that classes are **not** initialized with their default values at all.
10
-
11
- This is important if you are handwriting the config files for whatever reason.
12
-
13
- Pretty print is also a format, but it uses eval for loading. There's likely a better way of doing this out there, but eh, I'm not bothered.
14
- It's fairly readable though.
15
-
16
- There is a minor problem right now with string encoding, especially with oneshot since there's some foul text that's encoded weirdly.
17
- I'll try to fix that later.
18
-
19
- Usage:
20
-
21
- `rmxp_extractor import | export <type> | scripts"`
22
- # Script
23
-
24
- Allows you to export Scripts/xScripts to a specified folder. You can also import said specified folder back into Scripts/xScripts.
25
- The last argument `[x]` is optional. Placing just `x` there will extract Scripts.
26
-
27
- # Is it flawless?
28
-
29
- Running export followed by import should produce an almost identical file with some minor differences.
30
-
31
- As far as I'm aware from my testing, a file diff may say the the two are different, but loading them via marshal provides the exact same instance give or take.
32
- Ruby reports the original and imported instances as being different when loaded from Marshal, but pretty printing each instance to a file shows this is not the case.
33
- RPG Maker XP probably doesn't exactly follow Marshal spec and cuts some corners, which is why the file diff shows up differently.
34
-
35
- A diff check tool is provided if you want to try it yourself.
1
+ # RMXP-Extractor
2
+
3
+ A tool designed to dump rxdata to various git compatible formats. Some work better than others, though.
4
+ YAML is slow in comparison to JSON. I'd suggest sticking to JSON generally.
5
+
6
+ Originally, I used a complex monkey patched system to dump things to a hash that was very slow and imprecise.
7
+ Now, it uses some neat tricks to do it relatively efficiently.
8
+
9
+ Only problem is, classes dumped or loaded dump their instance variables, meaning that classes are **not** initialized with their default values at all.
10
+
11
+ This is important if you are handwriting the config files for whatever reason.
12
+
13
+ Pretty print is also a format, but it uses eval for loading. There's likely a better way of doing this out there, but eh, I'm not bothered.
14
+ It's fairly readable though.
15
+
16
+ There is a minor problem right now with string encoding, especially with oneshot since there's some foul text that's encoded weirdly.
17
+ I'll try to fix that later.
18
+
19
+ Usage:
20
+
21
+ `rmxp_extractor import | export <type> | scripts"`
22
+ # Script
23
+
24
+ Allows you to export Scripts/xScripts to a specified folder. You can also import said specified folder back into Scripts/xScripts.
25
+ The last argument `[x]` is optional. Placing just `x` there will extract Scripts.
26
+
27
+ # Is it flawless?
28
+
29
+ Running export followed by import should produce an almost identical file with some minor differences.
30
+
31
+ As far as I'm aware from my testing, a file diff may say the the two are different, but loading them via marshal provides the exact same instance give or take.
32
+ Ruby reports the original and imported instances as being different when loaded from Marshal, but pretty printing each instance to a file shows this is not the case.
33
+ RPG Maker XP probably doesn't exactly follow Marshal spec and cuts some corners, which is why the file diff shows up differently.
34
+
35
+ A diff check tool is provided if you want to try it yourself.
data/Rakefile CHANGED
@@ -1,6 +1,6 @@
1
- require "bundler/gem_tasks"
2
- require "rspec/core/rake_task"
3
-
4
- RSpec::Core::RakeTask.new(:spec)
5
-
6
- task :default => :spec
1
+ require "bundler/gem_tasks"
2
+ require "rspec/core/rake_task"
3
+
4
+ RSpec::Core::RakeTask.new(:spec)
5
+
6
+ task :default => :spec
data/Scripts/_scripts.txt CHANGED
@@ -1 +1 @@
1
- Main
1
+ Main
data/bin/rmxp_extractor CHANGED
@@ -1,13 +1,13 @@
1
- #!/usr/bin/env ruby
2
-
3
- require "bundler/setup"
4
- require "rmxp_extractor"
5
-
6
- # You can add fixtures and/or initialization code here to make experimenting
7
- # with your gem easier. You can also use a different console, if you like.
8
-
9
- # (If you use this, don't forget to add pry to your Gemfile!)
10
- # require "pry"
11
- # Pry.start
12
-
13
- RMXPExtractor.process ARGV
1
+ #!/usr/bin/env ruby
2
+
3
+ require "bundler/setup"
4
+ require "rmxp_extractor"
5
+
6
+ # You can add fixtures and/or initialization code here to make experimenting
7
+ # with your gem easier. You can also use a different console, if you like.
8
+
9
+ # (If you use this, don't forget to add pry to your Gemfile!)
10
+ # require "pry"
11
+ # Pry.start
12
+
13
+ RMXPExtractor.process ARGV
data/bin/setup CHANGED
@@ -1,8 +1,8 @@
1
- #!/usr/bin/env bash
2
- set -euo pipefail
3
- IFS=$'\n\t'
4
- set -vx
5
-
6
- bundle install
7
-
8
- # Do any other automated setup that you need to do here
1
+ #!/usr/bin/env bash
2
+ set -euo pipefail
3
+ IFS=$'\n\t'
4
+ set -vx
5
+
6
+ bundle install
7
+
8
+ # Do any other automated setup that you need to do here
data/diff_check.rb CHANGED
@@ -1,13 +1,13 @@
1
- require_relative "lib/rmxp_extractor/classnames"
2
- require "amazing_print"
3
-
4
- f = File.open("Data_OLD/Map266.rxdata")
5
- ins1 = Marshal.load(f)
6
-
7
- f2 = File.open("Data/Map266.rxdata")
8
- ins2 = Marshal.load(f2)
9
-
10
- f = File.open("ins1", "w")
11
- f2 = File.open("ins2", "w")
12
- f.puts ins1.ai(plain: true, raw: true, object_id: false)
13
- f2.puts ins2.ai(plain: true, raw: true, object_id: false)
1
+ require_relative "lib/rmxp_extractor/classnames"
2
+ require "amazing_print"
3
+
4
+ f = File.open("Data_OLD/Map266.rxdata")
5
+ ins1 = Marshal.load(f)
6
+
7
+ f2 = File.open("Data/Map266.rxdata")
8
+ ins2 = Marshal.load(f2)
9
+
10
+ f = File.open("ins1", "w")
11
+ f2 = File.open("ins2", "w")
12
+ f.puts ins1.ai(plain: true, raw: true, object_id: false)
13
+ f2.puts ins2.ai(plain: true, raw: true, object_id: false)