mirror of
https://github.com/sfall-team/sfall.git
synced 2026-07-27 16:52:34 -07:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
42b180e3ff | ||
|
|
7e7e62fde3 | ||
|
|
ecea37543a | ||
|
|
923c344629 | ||
|
|
935b4daff0 | ||
|
|
4c57e1dd8c | ||
|
|
80da1642c3 | ||
|
|
0cd6fa9762 | ||
|
|
cddab3b9ce | ||
|
|
9008a275cd | ||
|
|
538db93ee3 | ||
|
|
653829f0a1 | ||
|
|
a005e3f97a | ||
|
|
ebb530487d | ||
|
|
59654d4277 | ||
|
|
97563ad265 | ||
|
|
7f4abe63fc | ||
|
|
3f04b12e0f | ||
|
|
9c23c10aa9 | ||
|
|
1b71613a10 | ||
|
|
c5bed750af | ||
|
|
480941ff70 | ||
|
|
86ca29a239 | ||
|
|
483103088c | ||
|
|
70f6ef2363 | ||
|
|
c41f5df387 | ||
|
|
a9aeb35017 | ||
|
|
99d931c86c | ||
|
|
081754e9a8 | ||
|
|
64cff4ea2e | ||
|
|
b1fcd52ab0 | ||
|
|
fb5c5977bf | ||
|
|
c6f964c918 | ||
|
|
05d39d7474 | ||
|
|
3dbfa19f0c | ||
|
|
a2cb297b61 | ||
|
|
1351444ebf | ||
|
|
6a65925e83 | ||
|
|
c8050ef6a0 | ||
|
|
5018eb3cca | ||
|
|
3180403494 | ||
|
|
a0d1c2688c | ||
|
|
2c6082ce0c | ||
|
|
2bbf0662e4 | ||
|
|
86258454e7 | ||
|
|
ba006cf3f4 | ||
|
|
be9e33d82d | ||
|
|
6bd178578d | ||
|
|
ef3554c335 | ||
|
|
6ea9d8698d | ||
|
|
137c74648c | ||
|
|
2ad19c7ccc | ||
|
|
c4f083b10a | ||
|
|
e91d15aa7a | ||
|
|
4c7b334847 | ||
|
|
cf433c5634 | ||
|
|
b521c6d509 | ||
|
|
e571b335aa | ||
|
|
0fb7320665 | ||
|
|
1158c37190 | ||
|
|
211fa70bb8 | ||
|
|
7229f956c2 | ||
|
|
f3954a24b4 | ||
|
|
22b9789cd5 | ||
|
|
070ec83490 | ||
|
|
c5e32d4788 | ||
|
|
de7781efc7 | ||
|
|
f76fe4df59 | ||
|
|
1578577392 | ||
|
|
731187431e | ||
|
|
81cb8c7f6c | ||
|
|
59732a09da | ||
|
|
51d50c3061 | ||
|
|
b2892d97dc | ||
|
|
ed8b3b0144 | ||
|
|
d94275d778 | ||
|
|
17fa1c4363 | ||
|
|
ddaee4a78d | ||
|
|
4cb4eab418 | ||
|
|
a5d4daeb4b | ||
|
|
470cd6e6bd | ||
|
|
1788096ae7 | ||
|
|
4893b8f2b5 | ||
|
|
4e7996d436 | ||
|
|
587b8394fb | ||
|
|
8a36bc6764 | ||
|
|
2b128268fa | ||
|
|
7fc4386aa1 | ||
|
|
92db62886c | ||
|
|
e83e4823ab | ||
|
|
e0c1eec3c2 | ||
|
|
db42e1e746 | ||
|
|
a6e9108061 | ||
|
|
f0d43fd95e | ||
|
|
31e63c839f | ||
|
|
57ec274580 | ||
|
|
2b50ddb6a4 | ||
|
|
e5b12a07b1 | ||
|
|
dbd1a2f086 | ||
|
|
323290499e | ||
|
|
6fbc5218fb | ||
|
|
921195c7e1 | ||
|
|
aff4cf868d | ||
|
|
c2b9ac16fc | ||
|
|
49aa88bbd2 | ||
|
|
401d8b4dbb | ||
|
|
334fc1e702 | ||
|
|
3bb2d3080d | ||
|
|
afce69a132 | ||
|
|
8f017afda5 | ||
|
|
26b1f08e1c | ||
|
|
880aac642b | ||
|
|
4dc384ed4d | ||
|
|
56b78815fb | ||
|
|
4fda81e38b | ||
|
|
6c08f928e5 | ||
|
|
de7e275fbd | ||
|
|
9f022b41cd | ||
|
|
5eb36b97bb | ||
|
|
fb5fc0104e | ||
|
|
24aff0c332 | ||
|
|
434cbc20a8 | ||
|
|
06f783c920 | ||
|
|
a930dd3810 | ||
|
|
21d408f18a | ||
|
|
95bb2fd50d | ||
|
|
afc7fcc492 | ||
|
|
bdf807fe4c | ||
|
|
f2b3532a01 | ||
|
|
d013ec53cc | ||
|
|
cc9cb1da26 | ||
|
|
e7370db651 | ||
|
|
3ee295eb9d | ||
|
|
a91b5b1cbb | ||
|
|
830d85e628 | ||
|
|
6e8b3f7c17 | ||
|
|
6c03f928fc | ||
|
|
add8c8db2e | ||
|
|
93fa7c2b54 | ||
|
|
34544bb618 | ||
|
|
8f832d0c54 | ||
|
|
7785c0593a | ||
|
|
704264e1e4 | ||
|
|
0b3e40a249 | ||
|
|
8610dbf590 | ||
|
|
d1f4d764e7 | ||
|
|
954e117a41 | ||
|
|
b81140f67b | ||
|
|
aa80fc0033 | ||
|
|
c34c0b6128 | ||
|
|
8da42e0189 | ||
|
|
ba9be425d7 | ||
|
|
e353f32315 | ||
|
|
d5232fc599 | ||
|
|
da6ac5a774 | ||
|
|
cee4b593ab | ||
|
|
63838d3190 | ||
|
|
0d9703f368 | ||
|
|
950ce4318e | ||
|
|
250e655eea | ||
|
|
e71a90c324 | ||
|
|
bf88379105 | ||
|
|
91313e3251 | ||
|
|
0dbc2fa3e4 | ||
|
|
93ec1e9cd5 | ||
|
|
292d30a84c | ||
|
|
3fd9bae7b7 | ||
|
|
0d072e3bc3 | ||
|
|
114076b6d2 | ||
|
|
57d7ef4930 | ||
|
|
6b7df28247 | ||
|
|
d245920f68 | ||
|
|
f2bb1860e2 | ||
|
|
8a55ac847b | ||
|
|
7276b969cf | ||
|
|
ccf76fdd96 | ||
|
|
d0221513e9 | ||
|
|
8954631c21 | ||
|
|
44cf20503a | ||
|
|
78a1bf9dbd | ||
|
|
db79753e54 | ||
|
|
566944bd99 | ||
|
|
397cb9face | ||
|
|
04d2a110a9 | ||
|
|
9044d6e6f3 | ||
|
|
625d99f2a0 | ||
|
|
58db6c109c | ||
|
|
345d99622f | ||
|
|
db4efc492e | ||
|
|
50cd554110 | ||
|
|
cb3d690a22 | ||
|
|
e338205e49 | ||
|
|
ee09e9e258 | ||
|
|
d4c7737230 | ||
|
|
7b7c3832df | ||
|
|
c0135c6232 | ||
|
|
85d1982236 | ||
|
|
e0491b7211 | ||
|
|
7c13aa2a77 | ||
|
|
3cf5831db9 | ||
|
|
b12bed59ea | ||
|
|
d7c6851175 | ||
|
|
56f8c786ae | ||
|
|
ccf5fea6dd | ||
|
|
58289bfe03 | ||
|
|
e4bdc29e06 | ||
|
|
2de5f520e5 | ||
|
|
47a3c50342 | ||
|
|
22f4dc9785 | ||
|
|
700cf9b344 | ||
|
|
34f83498cb | ||
|
|
564528f53a | ||
|
|
b655afc3e0 | ||
|
|
2b874e2739 | ||
|
|
779739242a | ||
|
|
73d323c4ad | ||
|
|
8aa501fb7c | ||
|
|
2f095dda87 | ||
|
|
89fefa9414 | ||
|
|
675a201652 | ||
|
|
4771f6c3c7 | ||
|
|
905e765d4a | ||
|
|
ef0ca29bb0 | ||
|
|
6ac0d96b20 | ||
|
|
74555dbac4 | ||
|
|
d922640f9a | ||
|
|
a2ddf6b155 | ||
|
|
2f978f4be4 | ||
|
|
4dfd3dd603 | ||
|
|
aa8c925aab | ||
|
|
5e51fa9aad | ||
|
|
4291035fe5 | ||
|
|
1bfee5d9ca | ||
|
|
181c0bd2ad | ||
|
|
d59f62c011 | ||
|
|
c0c80e4f3a | ||
|
|
e73fb2c92a | ||
|
|
4bdb6fb851 | ||
|
|
205ecde005 | ||
|
|
6982251cad | ||
|
|
4b9c3dd5e3 | ||
|
|
96b6c2fe82 | ||
|
|
dd8c6a4ea0 | ||
|
|
f57be30551 | ||
|
|
f55e06ce00 | ||
|
|
2f5b30ac3d | ||
|
|
15f3e6b2a8 | ||
|
|
d2ae2eba86 | ||
|
|
374d94f3c1 | ||
|
|
23f7de29f0 | ||
|
|
ee5a4a964e | ||
|
|
a490b3242c | ||
|
|
4e7396fbe4 | ||
|
|
950747d0c1 | ||
|
|
25796d290f | ||
|
|
7c8ce8b18c | ||
|
|
ae5bfe651d | ||
|
|
1ef913ec73 | ||
|
|
d984241e41 | ||
|
|
a64bcb3baf | ||
|
|
0757d6a7ac | ||
|
|
f202fc0ed4 | ||
|
|
16839b16f9 | ||
|
|
b0a94497fb | ||
|
|
a536357c71 | ||
|
|
39a90427e0 | ||
|
|
9fcb27b364 | ||
|
|
a601ce9886 | ||
|
|
6fbcb82f92 | ||
|
|
89db9cc834 | ||
|
|
7e3fd2551c | ||
|
|
bf60518bf8 | ||
|
|
7bbaaef90b | ||
|
|
a35537feb7 | ||
|
|
9cfa3c0b74 | ||
|
|
c48423ed41 | ||
|
|
e323350738 | ||
|
|
7e4c0307e8 | ||
|
|
d61d5ba7b4 | ||
|
|
fc0529af9d | ||
|
|
9824998756 | ||
|
|
8a1a85645e | ||
|
|
b6e536cd15 | ||
|
|
96e9561b11 | ||
|
|
c46ad732f8 | ||
|
|
0a33ae8a5a | ||
|
|
174575303f | ||
|
|
99db8fdb60 | ||
|
|
9c3826b127 | ||
|
|
39480adc41 | ||
|
|
e9236c6c86 | ||
|
|
2783a45ea5 | ||
|
|
e724f84bc8 | ||
|
|
0111694b67 | ||
|
|
d2fb974849 | ||
|
|
59399edee2 | ||
|
|
f48b6cd4bd | ||
|
|
4c68f6815f | ||
|
|
98aa27d189 | ||
|
|
77487fc173 | ||
|
|
2d33a4e110 | ||
|
|
da3bc9343a | ||
|
|
c4b3423133 | ||
|
|
cbb3e121f4 | ||
|
|
c5c867a817 | ||
|
|
e9b87c51f9 | ||
|
|
77916f90eb | ||
|
|
4cede4cfd7 | ||
|
|
58a8e70fad | ||
|
|
0bbf229b98 | ||
|
|
bffdef164c | ||
|
|
57305e7496 | ||
|
|
30b6e29bb7 | ||
|
|
4f91b5f2c5 | ||
|
|
9c64d28f24 | ||
|
|
a82f42637e | ||
|
|
4254608f89 | ||
|
|
6925a60136 | ||
|
|
d75b2c2447 | ||
|
|
d0b05dc6cd | ||
|
|
db41a5a677 | ||
|
|
c60e1b7d47 | ||
|
|
74aede85ee | ||
|
|
28288343cd | ||
|
|
4c01b8b601 | ||
|
|
27bc142a65 | ||
|
|
f3c48d98e5 | ||
|
|
458a69dc9f | ||
|
|
ce5bff53d3 | ||
|
|
f4aeae315f | ||
|
|
bcbd2ee3eb | ||
|
|
c1c7a39b07 | ||
|
|
1899dbd6e5 | ||
|
|
77503ae554 | ||
|
|
97c78f17de | ||
|
|
c89144dbe7 | ||
|
|
d51b0b0de4 | ||
|
|
90d223173c | ||
|
|
03d7aa3145 | ||
|
|
dfba74d427 | ||
|
|
7c7fad32f6 | ||
|
|
7305e21dba | ||
|
|
cebdc96e28 | ||
|
|
5413155b9d | ||
|
|
df44faea7c | ||
|
|
ae719c7ac3 | ||
|
|
2e7c3f6c36 | ||
|
|
e24b600c79 | ||
|
|
e7dfcb73b3 | ||
|
|
8eef899399 |
@@ -1,51 +0,0 @@
|
||||
name: Build
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- 'develop'
|
||||
- 'github-action'
|
||||
paths:
|
||||
- '.github/workflows/build.yml'
|
||||
- 'action.yml'
|
||||
- 'sfall/**'
|
||||
|
||||
jobs:
|
||||
Build:
|
||||
name: sfall
|
||||
runs-on: windows-latest
|
||||
steps:
|
||||
|
||||
- name: Clone sfall
|
||||
uses: actions/checkout@v2
|
||||
|
||||
# Action is used twice for self-testing only
|
||||
# DevXP build results are intentionally *not* included in artifact
|
||||
|
||||
- name: ReleaseXP build
|
||||
id: build
|
||||
uses: ./
|
||||
with:
|
||||
release-xp: true
|
||||
|
||||
- name: DevXP build
|
||||
uses: ./
|
||||
with:
|
||||
dev-xp: true
|
||||
|
||||
- name: Prepare artifact
|
||||
run: |
|
||||
:
|
||||
mkdir -p ddraw
|
||||
|
||||
cp artifacts/ddraw.ini ddraw
|
||||
cp artifacts/sfall.dat ddraw
|
||||
cp "${{ steps.build.outputs.release-xp }}" ddraw
|
||||
shell: bash
|
||||
|
||||
- name: Upload artifacts
|
||||
uses: actions/upload-artifact@v2
|
||||
with:
|
||||
name: ddraw
|
||||
path: ddraw
|
||||
retention-days: 14
|
||||
@@ -1,34 +0,0 @@
|
||||
name: github pages
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
|
||||
jobs:
|
||||
deploy:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v2
|
||||
|
||||
- name: Setup Python
|
||||
uses: actions/setup-python@v2
|
||||
with:
|
||||
python-version: '3.x'
|
||||
|
||||
- name: Install dependencies
|
||||
run: |
|
||||
sudo apt -y -qq install bundler python3-pip
|
||||
pip3 install ruamel.yaml --user
|
||||
|
||||
- name: Build
|
||||
run: ./docs/generate.sh
|
||||
|
||||
- name: Deploy
|
||||
uses: peaceiris/actions-gh-pages@v3
|
||||
with:
|
||||
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||
publish_dir: ./docs/_site
|
||||
user_name: 'github-actions[bot]'
|
||||
user_email: 'github-actions[bot]@users.noreply.github.com'
|
||||
-232
@@ -1,232 +0,0 @@
|
||||
# Compiled Object files
|
||||
*.slo
|
||||
*.lo
|
||||
*.o
|
||||
*.obj
|
||||
|
||||
# Precompiled Headers
|
||||
*.gch
|
||||
*.pch
|
||||
|
||||
# Compiled Dynamic libraries
|
||||
*.so
|
||||
*.dylib
|
||||
*.dll
|
||||
|
||||
# Fortran module files
|
||||
*.mod
|
||||
|
||||
# Compiled Static libraries
|
||||
*.lai
|
||||
*.la
|
||||
*.a
|
||||
*.lib
|
||||
|
||||
# Executables
|
||||
*.exe
|
||||
*.out
|
||||
*.app
|
||||
|
||||
# NetBeans
|
||||
nbproject/private/
|
||||
build/
|
||||
nbbuild/
|
||||
dist/
|
||||
nbdist/
|
||||
nbactions.xml
|
||||
nb-configuration.xml
|
||||
.nb-gradle/
|
||||
|
||||
|
||||
## Ignore Visual Studio temporary files, build results, and
|
||||
## files generated by popular Visual Studio add-ons.
|
||||
|
||||
# User-specific files
|
||||
*.suo
|
||||
*.user
|
||||
*.userosscache
|
||||
*.sln.docstates
|
||||
*.VC.db
|
||||
*.VC.opendb
|
||||
|
||||
# User-specific files (MonoDevelop/Xamarin Studio)
|
||||
*.userprefs
|
||||
|
||||
# Build results
|
||||
[Dd]ebug/
|
||||
[Dd]ebugPublic/
|
||||
[Dd]evXP
|
||||
[Rr]elease/
|
||||
[Rr]eleases/
|
||||
[Rr]eleaseXP/
|
||||
x64/
|
||||
x86/
|
||||
build/
|
||||
bld/
|
||||
[Bb]in/
|
||||
[Oo]bj/
|
||||
|
||||
# Visual Studio 2015 cache/options directory
|
||||
.vs/
|
||||
|
||||
# MSTest test Results
|
||||
[Tt]est[Rr]esult*/
|
||||
[Bb]uild[Ll]og.*
|
||||
|
||||
# NUNIT
|
||||
*.VisualState.xml
|
||||
TestResult.xml
|
||||
|
||||
# Build Results of an ATL Project
|
||||
[Dd]ebugPS/
|
||||
[Rr]eleasePS/
|
||||
dlldata.c
|
||||
|
||||
# DNX
|
||||
project.lock.json
|
||||
|
||||
*_i.c
|
||||
*_p.c
|
||||
*_i.h
|
||||
*.ilk
|
||||
*.meta
|
||||
*.obj
|
||||
*.pch
|
||||
*.pdb
|
||||
*.pgc
|
||||
*.pgd
|
||||
*.rsp
|
||||
*.sbr
|
||||
*.tlb
|
||||
*.tli
|
||||
*.tlh
|
||||
*.tmp
|
||||
*.tmp_proj
|
||||
*.log
|
||||
*.vspscc
|
||||
*.vssscc
|
||||
.builds
|
||||
*.pidb
|
||||
*.svclog
|
||||
*.scc
|
||||
|
||||
# Chutzpah Test files
|
||||
_Chutzpah*
|
||||
|
||||
# Visual C++ cache files
|
||||
ipch/
|
||||
*.aps
|
||||
*.ncb
|
||||
*.opensdf
|
||||
*.sdf
|
||||
*.cachefile
|
||||
|
||||
# Visual Studio profiler
|
||||
*.psess
|
||||
*.vsp
|
||||
*.vspx
|
||||
|
||||
# ReSharper is a .NET coding add-in
|
||||
_ReSharper*/
|
||||
*.[Rr]e[Ss]harper
|
||||
*.DotSettings.user
|
||||
|
||||
# Web workbench (sass)
|
||||
.sass-cache/
|
||||
|
||||
# Installshield output folder
|
||||
[Ee]xpress/
|
||||
|
||||
# DocProject is a documentation generator add-in
|
||||
DocProject/buildhelp/
|
||||
DocProject/Help/*.HxT
|
||||
DocProject/Help/*.HxC
|
||||
DocProject/Help/*.hhc
|
||||
DocProject/Help/*.hhk
|
||||
DocProject/Help/*.hhp
|
||||
DocProject/Help/Html2
|
||||
DocProject/Help/html
|
||||
|
||||
# Click-Once directory
|
||||
publish/
|
||||
|
||||
# Publish Web Output
|
||||
*.[Pp]ublish.xml
|
||||
*.azurePubxml
|
||||
# TODO: Comment the next line if you want to checkin your web deploy settings
|
||||
# but database connection strings (with potential passwords) will be unencrypted
|
||||
*.pubxml
|
||||
*.publishproj
|
||||
|
||||
# NuGet Packages
|
||||
*.nupkg
|
||||
# The packages folder can be ignored because of Package Restore
|
||||
**/packages/*
|
||||
# except build/, which is used as an MSBuild target.
|
||||
!**/packages/build/
|
||||
# Uncomment if necessary however generally it will be regenerated when needed
|
||||
#!**/packages/repositories.config
|
||||
|
||||
# Windows Azure Build Output
|
||||
csx/
|
||||
*.build.csdef
|
||||
|
||||
# Windows Store app package directory
|
||||
AppPackages/
|
||||
|
||||
# Visual Studio cache files
|
||||
# files ending in .cache can be ignored
|
||||
*.[Cc]ache
|
||||
# but keep track of directories ending in .cache
|
||||
!*.[Cc]ache/
|
||||
|
||||
# Others
|
||||
ClientBin/
|
||||
[Ss]tyle[Cc]op.*
|
||||
~$*
|
||||
*~
|
||||
*.dbmdl
|
||||
*.dbproj.schemaview
|
||||
*.pfx
|
||||
*.publishsettings
|
||||
node_modules/
|
||||
orleans.codegen.cs
|
||||
|
||||
# RIA/Silverlight projects
|
||||
Generated_Code/
|
||||
|
||||
# Backup & report files from converting an old project file
|
||||
# to a newer Visual Studio version. Backup files are not needed,
|
||||
# because we have git ;-)
|
||||
_UpgradeReport_Files/
|
||||
Backup*/
|
||||
UpgradeLog*.XML
|
||||
UpgradeLog*.htm
|
||||
|
||||
# SQL Server files
|
||||
*.mdf
|
||||
*.ldf
|
||||
|
||||
# Business Intelligence projects
|
||||
*.rdl.data
|
||||
*.bim.layout
|
||||
*.bim_*.settings
|
||||
|
||||
# Microsoft Fakes
|
||||
FakesAssemblies/
|
||||
|
||||
# Node.js Tools for Visual Studio
|
||||
.ntvs_analysis.dat
|
||||
|
||||
# Visual Studio 6 build log
|
||||
*.plg
|
||||
|
||||
# Visual Studio 6 workspace options file
|
||||
*.opt
|
||||
sfall/postbuild.cmd
|
||||
|
||||
# jekyll build files
|
||||
docs/_site
|
||||
docs/.sass-cache
|
||||
docs/.jekyll-metadata
|
||||
docs/pages/*.md
|
||||
Generated
-208
@@ -1,208 +0,0 @@
|
||||
namespace FalloutClient {
|
||||
partial class DebugEditor {
|
||||
/// <summary>
|
||||
/// Required designer variable.
|
||||
/// </summary>
|
||||
private System.ComponentModel.IContainer components = null;
|
||||
|
||||
/// <summary>
|
||||
/// Clean up any resources being used.
|
||||
/// </summary>
|
||||
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
|
||||
protected override void Dispose(bool disposing) {
|
||||
if(disposing && (components != null)) {
|
||||
components.Dispose();
|
||||
}
|
||||
base.Dispose(disposing);
|
||||
}
|
||||
|
||||
#region Windows Form Designer generated code
|
||||
|
||||
/// <summary>
|
||||
/// Required method for Designer support - do not modify
|
||||
/// the contents of this method with the code editor.
|
||||
/// </summary>
|
||||
private void InitializeComponent() {
|
||||
this.dataGridView1 = new System.Windows.Forms.DataGridView();
|
||||
this.Column0 = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||
this.Column1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||
this.Column2 = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||
this.Column3 = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||
this.bGlobals = new System.Windows.Forms.Button();
|
||||
this.bMapVars = new System.Windows.Forms.Button();
|
||||
this.bCritters = new System.Windows.Forms.Button();
|
||||
this.bSGlobals = new System.Windows.Forms.Button();
|
||||
this.bArrays = new System.Windows.Forms.Button();
|
||||
this.bEdit = new System.Windows.Forms.Button();
|
||||
this.bCrittersLvar = new System.Windows.Forms.Button();
|
||||
((System.ComponentModel.ISupportInitialize)(this.dataGridView1)).BeginInit();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// dataGridView1
|
||||
//
|
||||
this.dataGridView1.AllowUserToAddRows = false;
|
||||
this.dataGridView1.AllowUserToDeleteRows = false;
|
||||
this.dataGridView1.AllowUserToResizeRows = false;
|
||||
this.dataGridView1.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||
| System.Windows.Forms.AnchorStyles.Left)
|
||||
| System.Windows.Forms.AnchorStyles.Right)));
|
||||
this.dataGridView1.ColumnHeadersHeight = 22;
|
||||
this.dataGridView1.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
|
||||
this.Column0,
|
||||
this.Column1,
|
||||
this.Column2,
|
||||
this.Column3});
|
||||
this.dataGridView1.Location = new System.Drawing.Point(12, 12);
|
||||
this.dataGridView1.MultiSelect = false;
|
||||
this.dataGridView1.Name = "dataGridView1";
|
||||
this.dataGridView1.RowHeadersVisible = false;
|
||||
this.dataGridView1.RowHeadersWidthSizeMode = System.Windows.Forms.DataGridViewRowHeadersWidthSizeMode.DisableResizing;
|
||||
this.dataGridView1.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect;
|
||||
this.dataGridView1.Size = new System.Drawing.Size(561, 354);
|
||||
this.dataGridView1.TabIndex = 0;
|
||||
this.dataGridView1.CellDoubleClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.dataGridView1_CellDoubleClick);
|
||||
this.dataGridView1.CellEndEdit += new System.Windows.Forms.DataGridViewCellEventHandler(this.dataGridView1_CellEndEdit);
|
||||
this.dataGridView1.RowsAdded += new System.Windows.Forms.DataGridViewRowsAddedEventHandler(this.dataGridView1_RowsAdded);
|
||||
//
|
||||
// Column0
|
||||
//
|
||||
this.Column0.HeaderText = "ID";
|
||||
this.Column0.Name = "Column0";
|
||||
this.Column0.ReadOnly = true;
|
||||
this.Column0.Width = 50;
|
||||
//
|
||||
// Column1
|
||||
//
|
||||
this.Column1.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
|
||||
this.Column1.HeaderText = "Name";
|
||||
this.Column1.Name = "Column1";
|
||||
this.Column1.ReadOnly = true;
|
||||
//
|
||||
// Column2
|
||||
//
|
||||
this.Column2.HeaderText = "Value (Int)";
|
||||
this.Column2.Name = "Column2";
|
||||
//
|
||||
// Column3
|
||||
//
|
||||
this.Column3.HeaderText = "Value (Float)";
|
||||
this.Column3.Name = "Column3";
|
||||
//
|
||||
// bGlobals
|
||||
//
|
||||
this.bGlobals.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
|
||||
this.bGlobals.Location = new System.Drawing.Point(12, 372);
|
||||
this.bGlobals.Name = "bGlobals";
|
||||
this.bGlobals.Size = new System.Drawing.Size(100, 23);
|
||||
this.bGlobals.TabIndex = 1;
|
||||
this.bGlobals.Text = "Globals";
|
||||
this.bGlobals.UseVisualStyleBackColor = true;
|
||||
this.bGlobals.Click += new System.EventHandler(this.bGlobals_Click);
|
||||
//
|
||||
// bMapVars
|
||||
//
|
||||
this.bMapVars.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
|
||||
this.bMapVars.Location = new System.Drawing.Point(118, 372);
|
||||
this.bMapVars.Name = "bMapVars";
|
||||
this.bMapVars.Size = new System.Drawing.Size(100, 23);
|
||||
this.bMapVars.TabIndex = 2;
|
||||
this.bMapVars.Text = "Map variables";
|
||||
this.bMapVars.UseVisualStyleBackColor = true;
|
||||
this.bMapVars.Click += new System.EventHandler(this.bMapVars_Click);
|
||||
//
|
||||
// bCritters
|
||||
//
|
||||
this.bCritters.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
|
||||
this.bCritters.Location = new System.Drawing.Point(12, 401);
|
||||
this.bCritters.Name = "bCritters";
|
||||
this.bCritters.Size = new System.Drawing.Size(100, 23);
|
||||
this.bCritters.TabIndex = 3;
|
||||
this.bCritters.Text = "Critters";
|
||||
this.bCritters.UseVisualStyleBackColor = true;
|
||||
this.bCritters.Click += new System.EventHandler(this.bCritters_Click);
|
||||
//
|
||||
// bSGlobals
|
||||
//
|
||||
this.bSGlobals.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
|
||||
this.bSGlobals.Location = new System.Drawing.Point(367, 372);
|
||||
this.bSGlobals.Name = "bSGlobals";
|
||||
this.bSGlobals.Size = new System.Drawing.Size(100, 23);
|
||||
this.bSGlobals.TabIndex = 4;
|
||||
this.bSGlobals.Text = "sfall globals";
|
||||
this.bSGlobals.UseVisualStyleBackColor = true;
|
||||
this.bSGlobals.Click += new System.EventHandler(this.bSGlobals_Click);
|
||||
//
|
||||
// bArrays
|
||||
//
|
||||
this.bArrays.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
|
||||
this.bArrays.Location = new System.Drawing.Point(473, 372);
|
||||
this.bArrays.Name = "bArrays";
|
||||
this.bArrays.Size = new System.Drawing.Size(100, 23);
|
||||
this.bArrays.TabIndex = 5;
|
||||
this.bArrays.Text = "sfall arrays";
|
||||
this.bArrays.UseVisualStyleBackColor = true;
|
||||
this.bArrays.Click += new System.EventHandler(this.bArrays_Click);
|
||||
//
|
||||
// bEdit
|
||||
//
|
||||
this.bEdit.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
|
||||
this.bEdit.Location = new System.Drawing.Point(473, 401);
|
||||
this.bEdit.Name = "bEdit";
|
||||
this.bEdit.Size = new System.Drawing.Size(100, 23);
|
||||
this.bEdit.TabIndex = 6;
|
||||
this.bEdit.Text = "Edit";
|
||||
this.bEdit.UseVisualStyleBackColor = true;
|
||||
this.bEdit.Click += new System.EventHandler(this.bEdit_Click);
|
||||
//
|
||||
// bCrittersLvar
|
||||
//
|
||||
this.bCrittersLvar.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
|
||||
this.bCrittersLvar.Enabled = false;
|
||||
this.bCrittersLvar.Location = new System.Drawing.Point(118, 401);
|
||||
this.bCrittersLvar.Name = "bCrittersLvar";
|
||||
this.bCrittersLvar.Size = new System.Drawing.Size(100, 23);
|
||||
this.bCrittersLvar.TabIndex = 7;
|
||||
this.bCrittersLvar.Text = "Local variables";
|
||||
this.bCrittersLvar.UseVisualStyleBackColor = true;
|
||||
this.bCrittersLvar.Click += new System.EventHandler(this.bCrittersLvar_Click);
|
||||
//
|
||||
// DebugEditor
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.ClientSize = new System.Drawing.Size(585, 436);
|
||||
this.Controls.Add(this.bCrittersLvar);
|
||||
this.Controls.Add(this.bEdit);
|
||||
this.Controls.Add(this.bArrays);
|
||||
this.Controls.Add(this.bSGlobals);
|
||||
this.Controls.Add(this.bCritters);
|
||||
this.Controls.Add(this.bMapVars);
|
||||
this.Controls.Add(this.bGlobals);
|
||||
this.Controls.Add(this.dataGridView1);
|
||||
this.MinimumSize = new System.Drawing.Size(450, 300);
|
||||
this.Name = "DebugEditor";
|
||||
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
|
||||
this.Text = "sfall Debug Editor";
|
||||
this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.DebugEditor_FormClosing);
|
||||
((System.ComponentModel.ISupportInitialize)(this.dataGridView1)).EndInit();
|
||||
this.ResumeLayout(false);
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private System.Windows.Forms.DataGridView dataGridView1;
|
||||
private System.Windows.Forms.Button bGlobals;
|
||||
private System.Windows.Forms.Button bMapVars;
|
||||
private System.Windows.Forms.Button bCritters;
|
||||
private System.Windows.Forms.Button bSGlobals;
|
||||
private System.Windows.Forms.Button bArrays;
|
||||
private System.Windows.Forms.Button bEdit;
|
||||
private System.Windows.Forms.DataGridViewTextBoxColumn Column0;
|
||||
private System.Windows.Forms.DataGridViewTextBoxColumn Column1;
|
||||
private System.Windows.Forms.DataGridViewTextBoxColumn Column2;
|
||||
private System.Windows.Forms.DataGridViewTextBoxColumn Column3;
|
||||
private System.Windows.Forms.Button bCrittersLvar;
|
||||
|
||||
}
|
||||
}
|
||||
@@ -1,385 +0,0 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Drawing;
|
||||
using System.Text;
|
||||
using System.Windows.Forms;
|
||||
using File = System.IO.File;
|
||||
using StreamReader = System.IO.StreamReader;
|
||||
using MemoryStream = System.IO.MemoryStream;
|
||||
using BinaryReader = System.IO.BinaryReader;
|
||||
using BinaryWriter = System.IO.BinaryWriter;
|
||||
|
||||
namespace FalloutClient {
|
||||
|
||||
public partial class DebugEditor : Form
|
||||
{
|
||||
[System.Runtime.InteropServices.StructLayout(System.Runtime.InteropServices.LayoutKind.Explicit)]
|
||||
private struct ByteConverter {
|
||||
[System.Runtime.InteropServices.FieldOffset(0)]
|
||||
private int i;
|
||||
[System.Runtime.InteropServices.FieldOffset(0)]
|
||||
private float f;
|
||||
|
||||
public int GetAsInt(float f) {
|
||||
this.f = f;
|
||||
return i;
|
||||
}
|
||||
public float GetAsFloat(int i) {
|
||||
this.i = i;
|
||||
return f;
|
||||
}
|
||||
public byte[] GetAsBytes(ulong ul) {
|
||||
byte[] b = new byte[8];
|
||||
for (int i = 0; i < 8; i++) b[i] = (byte)((ul & ((ulong)0xff << (i * 8))) >> (i * 8));
|
||||
return b;
|
||||
}
|
||||
}
|
||||
|
||||
private static ByteConverter converter = new ByteConverter();
|
||||
|
||||
private enum Mode { Globals, MapVars, SGlobals, Arrays, Critters, LocalVars }
|
||||
|
||||
private readonly EditorConnection connection;
|
||||
private Mode mode;
|
||||
|
||||
private readonly Dictionary<int, string> GlobNames = new Dictionary<int, string>();
|
||||
private readonly Dictionary<uint, string> CritNames = new Dictionary<uint, string>();
|
||||
|
||||
private void Redraw() {
|
||||
bCrittersLvar.Enabled = false;
|
||||
bEdit.Enabled = false;
|
||||
Column2.ReadOnly = false;
|
||||
Column3.ReadOnly = false;
|
||||
Column2.HeaderText = "Value (Int)";
|
||||
Column3.HeaderText = "Value (Float)";
|
||||
dataGridView1.SelectionMode = DataGridViewSelectionMode.CellSelect;
|
||||
dataGridView1.SuspendLayout();
|
||||
dataGridView1.Rows.Clear();
|
||||
switch (mode) {
|
||||
case Mode.Globals:
|
||||
for (int i = 0; i < connection.Globals.Length; i++) {
|
||||
string name = GlobNames.ContainsKey(i) ? GlobNames[i] : "";
|
||||
dataGridView1.Rows.Add(i, name, connection.Globals[i], converter.GetAsFloat(connection.Globals[i]));
|
||||
}
|
||||
break;
|
||||
case Mode.MapVars:
|
||||
for (int i = 0; i < connection.MapVars.Length; i++) {
|
||||
dataGridView1.Rows.Add(i, "", connection.MapVars[i], converter.GetAsFloat(connection.MapVars[i]));
|
||||
}
|
||||
break;
|
||||
case Mode.SGlobals:
|
||||
for (int i = 0; i < connection.SGlobalKeys.Length; i++) {
|
||||
string s = connection.SGlobalKeys[i] > 0xffffffff
|
||||
? new string(System.Text.ASCIIEncoding.ASCII.GetChars(converter.GetAsBytes(connection.SGlobalKeys[i])))
|
||||
: (connection.SGlobalKeys[i].ToString());
|
||||
dataGridView1.Rows.Add(s, "", connection.sGlobals[i], converter.GetAsFloat(connection.sGlobals[i]));
|
||||
}
|
||||
break;
|
||||
case Mode.Arrays:
|
||||
dataGridView1.SelectionMode = DataGridViewSelectionMode.FullRowSelect;
|
||||
Column2.ReadOnly = true;
|
||||
Column3.ReadOnly = true;
|
||||
Column2.HeaderText = "Array size";
|
||||
Column3.HeaderText = "Array flags";
|
||||
bEdit.Enabled = true;
|
||||
for (int i = 0; i < connection.Arrays.Length; i++) {
|
||||
bool isMap = connection.ArrayIsMap[i];
|
||||
int arrlen = connection.ArrayLengths[i];
|
||||
if (isMap) arrlen /= 2;
|
||||
dataGridView1.Rows.Add(connection.Arrays[i], isMap ? "Map" : "", arrlen, "0x" + connection.ArrayFlag[i].ToString("x").ToUpper());
|
||||
}
|
||||
break;
|
||||
case Mode.Critters:
|
||||
dataGridView1.SelectionMode = DataGridViewSelectionMode.FullRowSelect;
|
||||
Column2.ReadOnly = true;
|
||||
Column3.ReadOnly = true;
|
||||
Column2.HeaderText = "PID";
|
||||
Column3.HeaderText = "Pointer";
|
||||
bEdit.Enabled = true;
|
||||
bCrittersLvar.Enabled = true;
|
||||
for (int i = 0; i < connection.Critters.Length / 2; i++) {
|
||||
uint modcrit = (connection.Critters[i, 0] & 0xfffff);
|
||||
string name = CritNames.ContainsKey(modcrit) ? CritNames[modcrit] : "";
|
||||
dataGridView1.Rows.Add(i + 1, name, connection.Critters[i, 0].ToString("x").ToUpper(), connection.Critters[i, 1].ToString());
|
||||
}
|
||||
break;
|
||||
}
|
||||
dataGridView1.ResumeLayout();
|
||||
}
|
||||
|
||||
internal DebugEditor(EditorConnection connection) {
|
||||
InitializeComponent();
|
||||
this.connection = connection;
|
||||
mode = Mode.Globals;
|
||||
if (File.Exists(".\\data\\data\\vault13.gam")) {
|
||||
StreamReader sr=new StreamReader(".\\data\\data\\vault13.gam");
|
||||
int gvar = 0;
|
||||
while (!sr.EndOfStream) {
|
||||
string line = sr.ReadLine().TrimStart();
|
||||
if (line.StartsWith("GVAR_")) GlobNames[gvar++] = line.Remove(line.IndexOf(':')).TrimEnd();
|
||||
}
|
||||
sr.Close();
|
||||
} else if (File.Exists("globals.txt")) {
|
||||
StreamReader sr = new StreamReader("globals.txt");
|
||||
while (!sr.EndOfStream) {
|
||||
string[] line = sr.ReadLine().Split(' ');
|
||||
GlobNames[int.Parse(line[0])] = line[1];
|
||||
}
|
||||
sr.Close();
|
||||
}
|
||||
if (File.Exists("critters.txt")) {
|
||||
StreamReader sr = new StreamReader("critters.txt");
|
||||
while (!sr.EndOfStream) {
|
||||
string line = sr.ReadLine();
|
||||
CritNames[uint.Parse(line.Remove(line.IndexOf(' ')))] = line.Substring(line.IndexOf(' ') + 1);
|
||||
}
|
||||
sr.Close();
|
||||
}
|
||||
Redraw();
|
||||
}
|
||||
|
||||
private void DebugEditor_FormClosing(object sender, FormClosingEventArgs e) {
|
||||
connection.WriteDataType(DataTypeSend.Exit);
|
||||
connection.Close();
|
||||
}
|
||||
|
||||
private void bGlobals_Click(object sender, EventArgs e) {
|
||||
mode = Mode.Globals;
|
||||
Redraw();
|
||||
}
|
||||
|
||||
private void bMapVars_Click(object sender, EventArgs e) {
|
||||
mode = Mode.MapVars;
|
||||
Redraw();
|
||||
}
|
||||
|
||||
private void bSGlobals_Click(object sender, EventArgs e) {
|
||||
mode = Mode.SGlobals;
|
||||
Redraw();
|
||||
}
|
||||
|
||||
private void bArrays_Click(object sender, EventArgs e) {
|
||||
mode = Mode.Arrays;
|
||||
Redraw();
|
||||
}
|
||||
|
||||
private void bCritters_Click(object sender, EventArgs e) {
|
||||
mode = Mode.Critters;
|
||||
Redraw();
|
||||
}
|
||||
|
||||
private void dataGridView1_CellEndEdit(object sender, DataGridViewCellEventArgs e) {
|
||||
int[] array = null;
|
||||
DataTypeSend dts;
|
||||
switch (mode) {
|
||||
case Mode.Globals:
|
||||
array = connection.Globals;
|
||||
dts = DataTypeSend.SetGlobal;
|
||||
break;
|
||||
case Mode.MapVars:
|
||||
array = connection.MapVars;
|
||||
dts = DataTypeSend.SetMapVar;
|
||||
break;
|
||||
case Mode.SGlobals:
|
||||
array = connection.sGlobals;
|
||||
dts = DataTypeSend.SetSGlobal;
|
||||
break;
|
||||
default:
|
||||
return;
|
||||
}
|
||||
if (e.ColumnIndex == 2) {
|
||||
string str = dataGridView1.Rows[e.RowIndex].Cells[e.ColumnIndex].Value.ToString();
|
||||
int val;
|
||||
if (str == null || !int.TryParse(str, out val)) {
|
||||
dataGridView1.Rows[e.RowIndex].Cells[e.ColumnIndex].Value = array[e.RowIndex];
|
||||
} else {
|
||||
array[e.RowIndex] = val;
|
||||
connection.WriteDataType(dts);
|
||||
connection.WriteInt(e.RowIndex);
|
||||
connection.WriteInt(val);
|
||||
}
|
||||
} else {
|
||||
string str = dataGridView1.Rows[e.RowIndex].Cells[e.ColumnIndex].Value.ToString();
|
||||
float val;
|
||||
if (str == null || !float.TryParse(str, out val)) {
|
||||
dataGridView1.Rows[e.RowIndex].Cells[e.ColumnIndex].Value = array[e.RowIndex];
|
||||
} else {
|
||||
array[e.RowIndex] = converter.GetAsInt(val);
|
||||
connection.WriteDataType(dts);
|
||||
connection.WriteInt(e.RowIndex);
|
||||
connection.WriteInt(converter.GetAsInt(val));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void bEdit_Click(object sender, EventArgs e) {
|
||||
if (dataGridView1.SelectedRows.Count == 0) return;
|
||||
int i = (int)dataGridView1.SelectedRows[0].Tag;
|
||||
switch (mode) {
|
||||
case Mode.Arrays: {
|
||||
DataType[] types = new DataType[connection.ArrayLengths[i]];
|
||||
int[] lenType = new int[connection.ArrayLengths[i]];
|
||||
string[] strings = new string[connection.ArrayLengths[i]];
|
||||
connection.WriteDataType(DataTypeSend.GetArray); // code
|
||||
connection.WriteInt(i); // index
|
||||
int lenData = 0;
|
||||
for (int j = 0; j < strings.Length; j++) {
|
||||
types[j] = (DataType)connection.ReadInt();
|
||||
lenType[j] = connection.ReadInt(); // len data of type
|
||||
lenData += lenType[j];
|
||||
}
|
||||
byte[] buf = connection.ReadBytes(lenData); // read data
|
||||
BinaryReader br = new BinaryReader(new MemoryStream(buf));
|
||||
for (int j = 0; j < strings.Length; j++) {
|
||||
switch (types[j]) {
|
||||
case DataType.None:
|
||||
br.BaseStream.Position += 4;
|
||||
break;
|
||||
case DataType.Int:
|
||||
strings[j] = br.ReadInt32().ToString();
|
||||
break;
|
||||
case DataType.Float:
|
||||
strings[j] = br.ReadSingle().ToString();
|
||||
break;
|
||||
case DataType.String:
|
||||
byte[] bytes = br.ReadBytes(lenType[j]);
|
||||
strings[j] = System.Text.Encoding.ASCII.GetString(bytes, 0, Array.IndexOf<byte>(bytes, 0));
|
||||
break;
|
||||
}
|
||||
}
|
||||
br.Close();
|
||||
strings = EditorWindow.ShowEditor(this, null, types, strings, connection.ArrayIsMap[i]);
|
||||
if (strings != null) { // save
|
||||
MemoryStream ms = new MemoryStream(lenData);
|
||||
BinaryWriter bw = new BinaryWriter(ms);
|
||||
for (int j = 0; j < strings.Length; j++) {
|
||||
switch (types[j]) {
|
||||
case DataType.None:
|
||||
bw.BaseStream.Position += 4;
|
||||
break;
|
||||
case DataType.Int:
|
||||
bw.Write(int.Parse(strings[j]));
|
||||
break;
|
||||
case DataType.Float:
|
||||
bw.Write(float.Parse(strings[j]));
|
||||
break;
|
||||
case DataType.String:
|
||||
byte[] bytes = System.Text.Encoding.ASCII.GetBytes(strings[j]);
|
||||
if (bytes.Length < lenType[j])
|
||||
bw.Write(bytes);
|
||||
else
|
||||
bw.Write(bytes, 0, lenType[j] - 1);
|
||||
bw.Write((byte)0);
|
||||
break;
|
||||
}
|
||||
}
|
||||
// send data to sfall
|
||||
connection.WriteDataType(DataTypeSend.SetArray);
|
||||
connection.WriteInt(i); // index
|
||||
connection.WriteInt(lenData);
|
||||
connection.WriteBytes(ms.GetBuffer(), 0, lenData);
|
||||
bw.Close();
|
||||
}
|
||||
}
|
||||
break;
|
||||
case Mode.Critters: {
|
||||
DataType[] types = new DataType[33];
|
||||
string[] strings = new string[33];
|
||||
string[] names = new string[33];
|
||||
connection.WriteDataType(DataTypeSend.RetrieveCritter);
|
||||
connection.WriteInt(i);
|
||||
BinaryReader br = new BinaryReader(new System.IO.MemoryStream(connection.ReadBytes(33 * 4)));
|
||||
for (int j = 0; j < 33; j++) {
|
||||
types[j] = DataType.Int;
|
||||
strings[j] = br.ReadInt32().ToString();
|
||||
}
|
||||
br.Close();
|
||||
names[0] = " ID";
|
||||
names[1] = " Tile";
|
||||
names[6] = " Current frame";
|
||||
names[7] = " Rotation";
|
||||
names[8] = " FID";
|
||||
names[9] = " Flags";
|
||||
names[10] = " Elevation";
|
||||
names[11] = " Inventory count";
|
||||
names[13] = " Inventory pointer";
|
||||
names[14] = " Reaction";
|
||||
names[15] = " Combat state";
|
||||
names[16] = " Current AP";
|
||||
names[17] = " Combat flags";
|
||||
names[18] = " Last Turn Damage";
|
||||
names[19] = " AI Packet";
|
||||
names[20] = " Team";
|
||||
names[21] = " Who hit me";
|
||||
names[22] = " HP";
|
||||
names[23] = " Rads";
|
||||
names[24] = " Poison";
|
||||
names[25] = " Proto ID";
|
||||
names[26] = " Combat ID";
|
||||
names[29] = " Outline flags";
|
||||
names[30] = " Script ID";
|
||||
names[32] = " Script index";
|
||||
strings = EditorWindow.ShowEditor(this, names, types, strings);
|
||||
if (strings != null) {
|
||||
MemoryStream ms = new MemoryStream(33 * 4);
|
||||
BinaryWriter bw = new BinaryWriter(ms);
|
||||
for (int j = 0; j < 33; j++) bw.Write(int.Parse(strings[j]));
|
||||
connection.WriteDataType(DataTypeSend.SetCritter);
|
||||
connection.WriteInt(i);
|
||||
connection.WriteBytes(ms.GetBuffer(), 0, 33 * 4);
|
||||
bw.Close();
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
private void bCrittersLvar_Click(object sender, EventArgs e) {
|
||||
if (dataGridView1.SelectedRows.Count == 0) return;
|
||||
int i = (int)dataGridView1.SelectedRows[0].Tag;
|
||||
|
||||
connection.WriteDataType(DataTypeSend.RetrieveCritter);
|
||||
connection.WriteInt(i);
|
||||
BinaryReader br = new BinaryReader(new System.IO.MemoryStream(connection.ReadBytes(33 * 4)));
|
||||
br.BaseStream.Position = 30 * 4;
|
||||
int sid = br.ReadInt32();
|
||||
br.Close();
|
||||
if (sid != -1) {
|
||||
connection.WriteDataType(DataTypeSend.GetLocal);
|
||||
connection.WriteInt(sid);
|
||||
int totalVar = connection.ReadInt();
|
||||
string[] values = new string[totalVar];
|
||||
if (totalVar > 0) {
|
||||
br = new BinaryReader(new System.IO.MemoryStream(connection.ReadBytes(totalVar * 4)));
|
||||
for (int j = 0; j < totalVar; j++) {
|
||||
values[j] = br.ReadInt32().ToString();
|
||||
}
|
||||
br.Close();
|
||||
}
|
||||
values = EditorWindow.ShowEditor(this, values);
|
||||
if (values != null) {
|
||||
int countVar = values.Length;
|
||||
MemoryStream ms = new MemoryStream(countVar * 4);
|
||||
BinaryWriter bw = new BinaryWriter(ms);
|
||||
for (int j = 0; j < countVar; j++) bw.Write(int.Parse(values[j]));
|
||||
connection.WriteDataType(DataTypeSend.SetLocal);
|
||||
connection.WriteInt(sid);
|
||||
connection.WriteInt(countVar);
|
||||
connection.WriteBytes(ms.GetBuffer(), 0, countVar * 4);
|
||||
bw.Close();
|
||||
}
|
||||
} else {
|
||||
MessageBox.Show("This critter has no script attached.");
|
||||
}
|
||||
}
|
||||
|
||||
private void dataGridView1_CellDoubleClick(object sender, DataGridViewCellEventArgs e) {
|
||||
bEdit.PerformClick();
|
||||
}
|
||||
|
||||
private void dataGridView1_RowsAdded(object sender, DataGridViewRowsAddedEventArgs e) {
|
||||
dataGridView1.Rows[e.RowIndex].Tag = e.RowIndex;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,132 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<metadata name="Column0.UserAddedColumn" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>True</value>
|
||||
</metadata>
|
||||
<metadata name="Column1.UserAddedColumn" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>True</value>
|
||||
</metadata>
|
||||
<metadata name="Column2.UserAddedColumn" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>True</value>
|
||||
</metadata>
|
||||
<metadata name="Column3.UserAddedColumn" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>True</value>
|
||||
</metadata>
|
||||
</root>
|
||||
@@ -1,113 +0,0 @@
|
||||
using System;
|
||||
using System.Net.Sockets;
|
||||
using System.IO;
|
||||
|
||||
namespace FalloutClient {
|
||||
|
||||
class EditorConnection
|
||||
{
|
||||
private TcpClient client;
|
||||
private NetworkStream stream;
|
||||
private BinaryReader br;
|
||||
private BinaryWriter bw;
|
||||
|
||||
public readonly int[] Globals;
|
||||
public readonly int[] MapVars;
|
||||
public readonly uint[,] Critters;
|
||||
public readonly ulong[] SGlobalKeys;
|
||||
public readonly int[] sGlobals;
|
||||
public readonly uint[] Arrays;
|
||||
public readonly int[] ArrayLengths;
|
||||
public readonly int[] ArrayFlag;
|
||||
public readonly bool[] ArrayIsMap;
|
||||
|
||||
public EditorConnection() {
|
||||
System.Threading.Thread.Sleep(1000);
|
||||
client = new TcpClient("127.0.0.1", 4245);
|
||||
stream = client.GetStream();
|
||||
br = new BinaryReader(stream);
|
||||
bw = new BinaryWriter(stream);
|
||||
Globals = new int[br.ReadInt32()];
|
||||
MapVars = new int[br.ReadInt32()];
|
||||
SGlobalKeys = new ulong[br.ReadInt32()];
|
||||
sGlobals = new int[SGlobalKeys.Length];
|
||||
Arrays = new uint[br.ReadInt32()];
|
||||
ArrayLengths = new int[Arrays.Length];
|
||||
ArrayFlag = new int[Arrays.Length];
|
||||
ArrayIsMap = new bool[Arrays.Length];
|
||||
Critters = new uint[br.ReadInt32(), 2];
|
||||
|
||||
for (int i = 0; i < Globals.Length; i++) Globals[i] = br.ReadInt32();
|
||||
for (int i = 0; i < MapVars.Length; i++) MapVars[i] = br.ReadInt32();
|
||||
for (int i = 0; i < sGlobals.Length; i++) {
|
||||
SGlobalKeys[i] = br.ReadUInt64();
|
||||
sGlobals[i] = br.ReadInt32();
|
||||
br.ReadInt32();
|
||||
}
|
||||
for (int i = 0; i < Arrays.Length; i++) {
|
||||
Arrays[i] = br.ReadUInt32();
|
||||
ArrayIsMap[i] = (br.ReadInt32() != 0);
|
||||
ArrayLengths[i] = br.ReadInt32();
|
||||
ArrayFlag[i] = br.ReadInt32();
|
||||
}
|
||||
for (int i = 0; i < Critters.Length / 2; i++) {
|
||||
Critters[i, 0] = br.ReadUInt32();
|
||||
Critters[i, 1] = br.ReadUInt32();
|
||||
}
|
||||
}
|
||||
|
||||
public void Close() {
|
||||
stream.Close();
|
||||
client.Close();
|
||||
stream = null;
|
||||
client = null;
|
||||
}
|
||||
|
||||
public void WriteDataType(DataTypeSend type) {
|
||||
stream.WriteByte((byte)type);
|
||||
//bw.Write((byte)type);
|
||||
}
|
||||
|
||||
public void WriteByte(byte b) { bw.Write(b); }
|
||||
public void WriteInt16(short value) { bw.Write(value); }
|
||||
public void WriteInt(int value) { bw.Write(value); }
|
||||
public void WriteBytes(byte[] buf) { bw.Write(buf); }
|
||||
|
||||
public void WriteBytes(byte[] buf, int start, int len) {
|
||||
bw.Write(buf, start, len);
|
||||
}
|
||||
|
||||
public void Read(byte[] buffer) {
|
||||
int upto = 0;
|
||||
while (upto < buffer.Length) {
|
||||
upto += stream.Read(buffer, upto, buffer.Length - upto);
|
||||
}
|
||||
}
|
||||
public void Read(byte[] buffer, int offset, int length) {
|
||||
int upto = 0;
|
||||
//System.Diagnostics.Debug.WriteLine("Read - offset: "+offset+" length: "+length);
|
||||
while (upto < length) {
|
||||
upto += stream.Read(buffer, offset + upto, length - upto);
|
||||
}
|
||||
}
|
||||
public int ReadByte() {
|
||||
//System.Diagnostics.Debug.WriteLine("Read byte");
|
||||
return stream.ReadByte();
|
||||
}
|
||||
public int ReadShort() {
|
||||
//System.Diagnostics.Debug.WriteLine("Read short");
|
||||
return br.ReadInt16();
|
||||
}
|
||||
public int ReadInt() {
|
||||
//System.Diagnostics.Debug.WriteLine("Read int");
|
||||
return br.ReadInt32();
|
||||
}
|
||||
public uint ReadUInt() {
|
||||
//System.Diagnostics.Debug.WriteLine("Read uint");
|
||||
return br.ReadUInt32();
|
||||
}
|
||||
public byte[] ReadBytes(int count) {
|
||||
return br.ReadBytes(count);
|
||||
}
|
||||
}
|
||||
}
|
||||
Generated
-146
@@ -1,146 +0,0 @@
|
||||
namespace FalloutClient {
|
||||
partial class EditorWindow {
|
||||
/// <summary>
|
||||
/// Required designer variable.
|
||||
/// </summary>
|
||||
private System.ComponentModel.IContainer components = null;
|
||||
|
||||
/// <summary>
|
||||
/// Clean up any resources being used.
|
||||
/// </summary>
|
||||
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
|
||||
protected override void Dispose(bool disposing) {
|
||||
if(disposing && (components != null)) {
|
||||
components.Dispose();
|
||||
}
|
||||
base.Dispose(disposing);
|
||||
}
|
||||
|
||||
#region Windows Form Designer generated code
|
||||
|
||||
/// <summary>
|
||||
/// Required method for Designer support - do not modify
|
||||
/// the contents of this method with the code editor.
|
||||
/// </summary>
|
||||
private void InitializeComponent() {
|
||||
this.bSave = new System.Windows.Forms.Button();
|
||||
this.bCancel = new System.Windows.Forms.Button();
|
||||
this.dataGridView1 = new System.Windows.Forms.DataGridView();
|
||||
this.Column1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||
this.Column2 = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||
this.Column3 = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||
this.checkBox = new System.Windows.Forms.CheckBox();
|
||||
((System.ComponentModel.ISupportInitialize)(this.dataGridView1)).BeginInit();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// bSave
|
||||
//
|
||||
this.bSave.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
|
||||
this.bSave.Location = new System.Drawing.Point(12, 336);
|
||||
this.bSave.Name = "bSave";
|
||||
this.bSave.Size = new System.Drawing.Size(75, 23);
|
||||
this.bSave.TabIndex = 0;
|
||||
this.bSave.Text = "Save";
|
||||
this.bSave.UseVisualStyleBackColor = true;
|
||||
this.bSave.Click += new System.EventHandler(this.bSave_Click);
|
||||
//
|
||||
// bCancel
|
||||
//
|
||||
this.bCancel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
|
||||
this.bCancel.Location = new System.Drawing.Point(371, 336);
|
||||
this.bCancel.Name = "bCancel";
|
||||
this.bCancel.Size = new System.Drawing.Size(75, 23);
|
||||
this.bCancel.TabIndex = 1;
|
||||
this.bCancel.Text = "Cancel";
|
||||
this.bCancel.UseVisualStyleBackColor = true;
|
||||
this.bCancel.Click += new System.EventHandler(this.bCancel_Click);
|
||||
//
|
||||
// dataGridView1
|
||||
//
|
||||
this.dataGridView1.AllowUserToAddRows = false;
|
||||
this.dataGridView1.AllowUserToDeleteRows = false;
|
||||
this.dataGridView1.AllowUserToResizeRows = false;
|
||||
this.dataGridView1.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||
| System.Windows.Forms.AnchorStyles.Left)
|
||||
| System.Windows.Forms.AnchorStyles.Right)));
|
||||
this.dataGridView1.ColumnHeadersHeight = 22;
|
||||
this.dataGridView1.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
|
||||
this.Column1,
|
||||
this.Column2,
|
||||
this.Column3});
|
||||
this.dataGridView1.Location = new System.Drawing.Point(12, 12);
|
||||
this.dataGridView1.MultiSelect = false;
|
||||
this.dataGridView1.Name = "dataGridView1";
|
||||
this.dataGridView1.RowHeadersVisible = false;
|
||||
this.dataGridView1.RowHeadersWidthSizeMode = System.Windows.Forms.DataGridViewRowHeadersWidthSizeMode.DisableResizing;
|
||||
this.dataGridView1.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.CellSelect;
|
||||
this.dataGridView1.Size = new System.Drawing.Size(434, 318);
|
||||
this.dataGridView1.TabIndex = 2;
|
||||
this.dataGridView1.CellEndEdit += new System.Windows.Forms.DataGridViewCellEventHandler(this.dataGridView1_CellEndEdit);
|
||||
//
|
||||
// Column1
|
||||
//
|
||||
this.Column1.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
|
||||
this.Column1.HeaderText = "Element";
|
||||
this.Column1.Name = "Column1";
|
||||
this.Column1.ReadOnly = true;
|
||||
this.Column1.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
|
||||
//
|
||||
// Column2
|
||||
//
|
||||
this.Column2.HeaderText = "Type";
|
||||
this.Column2.Name = "Column2";
|
||||
this.Column2.ReadOnly = true;
|
||||
this.Column2.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
|
||||
this.Column2.Width = 75;
|
||||
//
|
||||
// Column3
|
||||
//
|
||||
this.Column3.HeaderText = "Value";
|
||||
this.Column3.Name = "Column3";
|
||||
this.Column3.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
|
||||
this.Column3.Width = 150;
|
||||
//
|
||||
// checkBox
|
||||
//
|
||||
this.checkBox.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
|
||||
this.checkBox.AutoSize = true;
|
||||
this.checkBox.Location = new System.Drawing.Point(103, 341);
|
||||
this.checkBox.Name = "checkBox";
|
||||
this.checkBox.Size = new System.Drawing.Size(91, 17);
|
||||
this.checkBox.TabIndex = 3;
|
||||
this.checkBox.Text = "Values in Hex";
|
||||
this.checkBox.UseVisualStyleBackColor = true;
|
||||
this.checkBox.Click += new System.EventHandler(this.checkBox_Click);
|
||||
//
|
||||
// EditorWindow
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.ClientSize = new System.Drawing.Size(458, 371);
|
||||
this.Controls.Add(this.checkBox);
|
||||
this.Controls.Add(this.dataGridView1);
|
||||
this.Controls.Add(this.bCancel);
|
||||
this.Controls.Add(this.bSave);
|
||||
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.SizableToolWindow;
|
||||
this.MinimumSize = new System.Drawing.Size(300, 200);
|
||||
this.Name = "EditorWindow";
|
||||
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
|
||||
this.Text = "Edit Values";
|
||||
((System.ComponentModel.ISupportInitialize)(this.dataGridView1)).EndInit();
|
||||
this.ResumeLayout(false);
|
||||
this.PerformLayout();
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private System.Windows.Forms.Button bSave;
|
||||
private System.Windows.Forms.Button bCancel;
|
||||
private System.Windows.Forms.DataGridView dataGridView1;
|
||||
private System.Windows.Forms.DataGridViewTextBoxColumn Column1;
|
||||
private System.Windows.Forms.DataGridViewTextBoxColumn Column2;
|
||||
private System.Windows.Forms.DataGridViewTextBoxColumn Column3;
|
||||
private System.Windows.Forms.CheckBox checkBox;
|
||||
}
|
||||
}
|
||||
@@ -1,127 +0,0 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Windows.Forms;
|
||||
|
||||
namespace FalloutClient {
|
||||
|
||||
public enum DataType : int { None = 0, Int = 1, Float = 2, String = 3 }
|
||||
|
||||
public partial class EditorWindow : Form
|
||||
{
|
||||
private readonly DataType[] types = null;
|
||||
private string[] values;
|
||||
private bool save;
|
||||
private static bool valueInHex = false;
|
||||
|
||||
private void ConvertValues(bool toHex) {
|
||||
for (int i = 0; i < values.Length; i++) {
|
||||
if (toHex) {
|
||||
if (types == null || types[i] == DataType.Int) {
|
||||
int val = int.Parse(values[i]);
|
||||
values[i] = "0x" + val.ToString("x").ToUpper();
|
||||
}
|
||||
} else {
|
||||
if (types == null || types[i] == DataType.Int) {
|
||||
values[i] = Convert.ToInt32(values[i], 16).ToString();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private EditorWindow(string[] names, DataType[] types, string[] values, bool isMap) {
|
||||
this.types = types;
|
||||
this.values = values;
|
||||
|
||||
InitializeComponent();
|
||||
checkBox.Checked = EditorWindow.valueInHex;
|
||||
dataGridView1.SuspendLayout();
|
||||
if (valueInHex) ConvertValues(true);
|
||||
if (names == null)
|
||||
for (int i = 0; i < types.Length; i++) {
|
||||
string element = i.ToString();
|
||||
if (isMap && (i % 2) == 0) element += " - Key";
|
||||
dataGridView1.Rows.Add(element, types[i].ToString(), values[i]);
|
||||
}
|
||||
else
|
||||
for (int i = 0; i < types.Length; i++) dataGridView1.Rows.Add("[0x" + (i * 4).ToString("x").ToUpper() + "]" + names[i], types[i].ToString(), values[i]);
|
||||
dataGridView1.ResumeLayout();
|
||||
}
|
||||
|
||||
public static string[] ShowEditor(DebugEditor form, string[] names, DataType[] types, string[] values, bool isMap = false) {
|
||||
EditorWindow editor = new EditorWindow(names, types, values, isMap);
|
||||
editor.ShowDialog();
|
||||
if (editor.save) {
|
||||
if (valueInHex) editor.ConvertValues(false);
|
||||
return editor.values;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
private EditorWindow(string[] values) {
|
||||
this.values = values;
|
||||
InitializeComponent();
|
||||
checkBox.Checked = EditorWindow.valueInHex;
|
||||
dataGridView1.SuspendLayout();
|
||||
if (valueInHex) ConvertValues(true);
|
||||
for (int i = 0; i < values.Length; i++) {
|
||||
dataGridView1.Rows.Add(i.ToString(), "Int", values[i]);
|
||||
}
|
||||
dataGridView1.ResumeLayout();
|
||||
}
|
||||
|
||||
public static string[] ShowEditor(DebugEditor form, string[] lvalues) {
|
||||
EditorWindow editor = new EditorWindow(lvalues);
|
||||
editor.ShowDialog();
|
||||
if (editor.save) {
|
||||
if (valueInHex) editor.ConvertValues(false);
|
||||
return editor.values;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
private bool CheckInput(DataType type, string str) {
|
||||
switch (type) {
|
||||
case DataType.Int:
|
||||
if (valueInHex) {
|
||||
try {
|
||||
Convert.ToInt32(str, 16);
|
||||
return true;
|
||||
} catch (Exception) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
int i;
|
||||
return int.TryParse(str, out i);
|
||||
case DataType.Float:
|
||||
float f;
|
||||
return float.TryParse(str, out f);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
private void dataGridView1_CellEndEdit(object sender, DataGridViewCellEventArgs e) {
|
||||
string str = (string)dataGridView1.Rows[e.RowIndex].Cells[e.ColumnIndex].Value;
|
||||
if (str != null && CheckInput(((types != null) ? types[e.RowIndex] : DataType.Int), str))
|
||||
values[e.RowIndex] = str;
|
||||
else
|
||||
dataGridView1.Rows[e.RowIndex].Cells[e.ColumnIndex].Value = values[e.RowIndex];
|
||||
}
|
||||
|
||||
private void bCancel_Click(object sender, EventArgs e) {
|
||||
Close();
|
||||
}
|
||||
|
||||
private void bSave_Click(object sender, EventArgs e) {
|
||||
save = true;
|
||||
Close();
|
||||
}
|
||||
|
||||
private void checkBox_Click(object sender, EventArgs e) {
|
||||
valueInHex = checkBox.Checked;
|
||||
ConvertValues(valueInHex);
|
||||
for (int i = 0; i < values.Length; i++) {
|
||||
dataGridView1.Rows[i].Cells[2].Value = values[i];
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,138 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<metadata name="Column1.UserAddedColumn" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>True</value>
|
||||
</metadata>
|
||||
<metadata name="Column2.UserAddedColumn" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>True</value>
|
||||
</metadata>
|
||||
<metadata name="Column3.UserAddedColumn" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>True</value>
|
||||
</metadata>
|
||||
<metadata name="Column1.UserAddedColumn" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>True</value>
|
||||
</metadata>
|
||||
<metadata name="Column2.UserAddedColumn" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>True</value>
|
||||
</metadata>
|
||||
<metadata name="Column3.UserAddedColumn" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>True</value>
|
||||
</metadata>
|
||||
</root>
|
||||
@@ -1,37 +0,0 @@
|
||||
using System;
|
||||
using System.Windows.Forms;
|
||||
using System.IO;
|
||||
|
||||
namespace FalloutClient {
|
||||
static class Program {
|
||||
/// <summary>
|
||||
/// The main entry point for the application.
|
||||
/// </summary>
|
||||
[STAThread]
|
||||
static void Main(string[] args) {
|
||||
Application.EnableVisualStyles();
|
||||
Application.SetCompatibleTextRenderingDefault(false);
|
||||
|
||||
if (args.Length == 1 && args[0] == "-debugedit") {
|
||||
Application.Run(new DebugEditor(new EditorConnection()));
|
||||
} else {
|
||||
MessageBox.Show("The debug editor can only be run from the game.\n" +
|
||||
"Use the key assigned to the DebugEditorKey option in ddraw.ini to run the debugger.",
|
||||
"sfall Debug Editor", MessageBoxButtons.OK, MessageBoxIcon.Stop);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
enum DataTypeSend {
|
||||
SetGlobal = 0,
|
||||
SetMapVar = 1,
|
||||
RetrieveCritter = 2,
|
||||
SetCritter = 3,
|
||||
SetSGlobal = 4,
|
||||
GetArray = 9,
|
||||
SetArray = 10,
|
||||
GetLocal = 11,
|
||||
SetLocal = 12,
|
||||
Exit = 254
|
||||
}
|
||||
}
|
||||
@@ -1,33 +0,0 @@
|
||||
using System.Reflection;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
// General Information about an assembly is controlled through the following
|
||||
// set of attributes. Change these attribute values to modify the information
|
||||
// associated with an assembly.
|
||||
[assembly: AssemblyTitle("sfall Debug Editor")]
|
||||
[assembly: AssemblyDescription("")]
|
||||
[assembly: AssemblyConfiguration("")]
|
||||
[assembly: AssemblyCompany("")]
|
||||
[assembly: AssemblyProduct("sfall")]
|
||||
[assembly: AssemblyCopyright("Copyright © 2019")]
|
||||
[assembly: AssemblyTrademark("")]
|
||||
[assembly: AssemblyCulture("")]
|
||||
|
||||
// Setting ComVisible to false makes the types in this assembly not visible
|
||||
// to COM components. If you need to access a type in this assembly from
|
||||
// COM, set the ComVisible attribute to true on that type.
|
||||
[assembly: ComVisible(false)]
|
||||
|
||||
// The following GUID is for the ID of the typelib if this project is exposed to COM
|
||||
[assembly: Guid("6b3c8cd6-54f0-4f35-a87e-50f760ad36fd")]
|
||||
|
||||
// Version information for an assembly consists of the following four values:
|
||||
//
|
||||
// Major Version
|
||||
// Minor Version
|
||||
// Build Number
|
||||
// Revision
|
||||
//
|
||||
[assembly: AssemblyVersion("4.1.9.0")]
|
||||
[assembly: AssemblyFileVersion("4.1.9.0")]
|
||||
@@ -1,3 +0,0 @@
|
||||
Apparently this project was intended as some kind of Multiplayer module for Fallout 2.
|
||||
|
||||
Now it only works as a supplement for sfall debugging mode. It shows a lists of: game objects, sfall globals, arrays, etc (in a separate window). Primarily focused on debugging sfall-enabled scripts.
|
||||
@@ -1,106 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="4.0">
|
||||
<PropertyGroup>
|
||||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
||||
<ProductVersion>9.0.21022</ProductVersion>
|
||||
<SchemaVersion>2.0</SchemaVersion>
|
||||
<ProjectGuid>{80ED0DCE-100E-4EC9-A79D-2FBFA4CAD1E3}</ProjectGuid>
|
||||
<OutputType>WinExe</OutputType>
|
||||
<AppDesignerFolder>Properties</AppDesignerFolder>
|
||||
<RootNamespace>FalloutClient</RootNamespace>
|
||||
<AssemblyName>FalloutDebug</AssemblyName>
|
||||
<FileUpgradeFlags>
|
||||
</FileUpgradeFlags>
|
||||
<OldToolsVersion>3.5</OldToolsVersion>
|
||||
<UpgradeBackupLocation>
|
||||
</UpgradeBackupLocation>
|
||||
<TargetFrameworkVersion>v2.0</TargetFrameworkVersion>
|
||||
<PublishUrl>publish\</PublishUrl>
|
||||
<Install>true</Install>
|
||||
<InstallFrom>Disk</InstallFrom>
|
||||
<UpdateEnabled>false</UpdateEnabled>
|
||||
<UpdateMode>Foreground</UpdateMode>
|
||||
<UpdateInterval>7</UpdateInterval>
|
||||
<UpdateIntervalUnits>Days</UpdateIntervalUnits>
|
||||
<UpdatePeriodically>false</UpdatePeriodically>
|
||||
<UpdateRequired>false</UpdateRequired>
|
||||
<MapFileExtensions>true</MapFileExtensions>
|
||||
<ApplicationRevision>0</ApplicationRevision>
|
||||
<ApplicationVersion>1.0.0.%2a</ApplicationVersion>
|
||||
<IsWebBootstrapper>false</IsWebBootstrapper>
|
||||
<UseApplicationTrust>false</UseApplicationTrust>
|
||||
<BootstrapperEnabled>false</BootstrapperEnabled>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||
<DebugSymbols>true</DebugSymbols>
|
||||
<DebugType>full</DebugType>
|
||||
<Optimize>false</Optimize>
|
||||
<OutputPath>bin\Debug\</OutputPath>
|
||||
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||
<DebugType>none</DebugType>
|
||||
<Optimize>true</Optimize>
|
||||
<OutputPath>bin\Release\</OutputPath>
|
||||
<DefineConstants>TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
<CheckForOverflowUnderflow>true</CheckForOverflowUnderflow>
|
||||
<DebugSymbols>false</DebugSymbols>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Drawing" />
|
||||
<Reference Include="System.Windows.Forms" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="DebugEditor.cs">
|
||||
<SubType>Form</SubType>
|
||||
</Compile>
|
||||
<Compile Include="DebugEditor.Designer.cs">
|
||||
<DependentUpon>DebugEditor.cs</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="EditorConnection.cs" />
|
||||
<Compile Include="EditorWindow.cs">
|
||||
<SubType>Form</SubType>
|
||||
</Compile>
|
||||
<Compile Include="EditorWindow.Designer.cs">
|
||||
<DependentUpon>EditorWindow.cs</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Program.cs" />
|
||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||
<EmbeddedResource Include="DebugEditor.resx">
|
||||
<DependentUpon>DebugEditor.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="EditorWindow.resx">
|
||||
<DependentUpon>EditorWindow.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<BootstrapperPackage Include="Microsoft.Net.Client.3.5">
|
||||
<Visible>False</Visible>
|
||||
<ProductName>.NET Framework 3.5 SP1 Client Profile</ProductName>
|
||||
<Install>false</Install>
|
||||
</BootstrapperPackage>
|
||||
<BootstrapperPackage Include="Microsoft.Net.Framework.3.5.SP1">
|
||||
<Visible>False</Visible>
|
||||
<ProductName>.NET Framework 3.5 SP1</ProductName>
|
||||
<Install>false</Install>
|
||||
</BootstrapperPackage>
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
|
||||
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
|
||||
Other similar extension points exist, see Microsoft.Common.targets.
|
||||
<Target Name="BeforeBuild">
|
||||
</Target>
|
||||
<Target Name="AfterBuild">
|
||||
</Target>
|
||||
-->
|
||||
<PropertyGroup>
|
||||
<PostBuildEvent>
|
||||
</PostBuildEvent>
|
||||
</PropertyGroup>
|
||||
</Project>
|
||||
@@ -1,19 +0,0 @@
|
||||
Microsoft Visual Studio Solution File, Format Version 11.00
|
||||
# Visual Studio 2010
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SfallDebugEditor", "SfallDebugEditor.csproj", "{80ED0DCE-100E-4EC9-A79D-2FBFA4CAD1E3}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|Any CPU = Debug|Any CPU
|
||||
Release|Any CPU = Release|Any CPU
|
||||
EndGlobalSection
|
||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||
{80ED0DCE-100E-4EC9-A79D-2FBFA4CAD1E3}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{80ED0DCE-100E-4EC9-A79D-2FBFA4CAD1E3}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{80ED0DCE-100E-4EC9-A79D-2FBFA4CAD1E3}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{80ED0DCE-100E-4EC9-A79D-2FBFA4CAD1E3}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
EndGlobalSection
|
||||
EndGlobal
|
||||
@@ -1,17 +0,0 @@
|
||||
# sfall
|
||||
[](https://github.com/phobos2077/sfall/actions/workflows/gh-pages.yml)
|
||||
|
||||
A set of engine modifications for the classic game Fallout 2 in form of a DLL, which modifies executable in memory without changing anything in EXE file itself.
|
||||
|
||||
**Engine modifications include:**
|
||||
- Better support for modern operating systems
|
||||
- Externalizing many settings like starting map and game time, skills, perks, critical hit tables, books, etc.
|
||||
- Bug fixes
|
||||
- Many additional features for users, such as item highlight button, party member control, etc.
|
||||
- Extended scripting capabilities for modders (many new opcodes to control sfall features as well as previously unavailable vanilla engine functions)
|
||||
|
||||
|
||||
Original author: timeslip
|
||||
|
||||
Original description: A set of engine modifications for the classic game Fallout 2 by Interplay. Includes fixes for bugs in the original engine, allows fallout to run correctly on modern operating systems, and adds additional features for modders.
|
||||
|
||||
-138
@@ -1,138 +0,0 @@
|
||||
name: 'sfall'
|
||||
description: 'Builds sfall binaries'
|
||||
author: '@wipe2238'
|
||||
|
||||
###
|
||||
#
|
||||
# Example:
|
||||
#
|
||||
# - name: Build sfall
|
||||
# id: sfall
|
||||
# uses: phobos2077/sfall@develop
|
||||
# with:
|
||||
# release-xp: true
|
||||
#
|
||||
# - name: Copy sfall to mod directory
|
||||
# run: copy "${{ steps.sfall.outputs.release-xp }}" "my/mod/directory/ddraw.dll"
|
||||
#
|
||||
###
|
||||
|
||||
# While both inputs are marked as required, users needs to set only one of them (at minimum) to 'true' for action to work
|
||||
inputs:
|
||||
|
||||
release-xp:
|
||||
description: 'Set to true to enable building with ReleaseXP configuration'
|
||||
required: true
|
||||
|
||||
dev-xp:
|
||||
description: 'Set to true to enable building with DevXP configuration'
|
||||
required: true
|
||||
|
||||
# Outputs are always using Windows directory separator (`\`)
|
||||
outputs:
|
||||
|
||||
release-xp:
|
||||
description: 'Full path to ddraw.dll built with ReleaseXP configuration'
|
||||
value: ${{ steps.build-release-xp.outputs.ddraw-dll }}
|
||||
|
||||
dev-xp:
|
||||
description: 'Full path to ddraw.dll built with DevXP configuration'
|
||||
value: ${{ steps.build-dev-xp.outputs.ddraw-dll }}
|
||||
dev-xp-pdb:
|
||||
description: 'Full path to ddraw.pdb built with DevXP configuration'
|
||||
value: ${{ steps.build-dev-xp.outputs.ddraw-pdb }}
|
||||
|
||||
runs:
|
||||
using: 'composite'
|
||||
steps:
|
||||
|
||||
# Quick check for things which should never happen
|
||||
- name: Sanity checks
|
||||
run: |
|
||||
if [[ "${{ runner.os }}" != "Windows" ]]; then
|
||||
echo "[ERROR] This action can only be used on Windows"
|
||||
exit 1
|
||||
elif [[ "${{ inputs.release-xp }}" != "true" ]] && [[ "${{ inputs.dev-xp }}" != "true" ]]; then
|
||||
echo "[ERROR] At least one of following inputs must be set to 'true' -- 'release-xp', 'dev-xp'"
|
||||
exit 1
|
||||
#
|
||||
elif [[ ! -d "$(cygpath --unix "$GITHUB_ACTION_PATH/sfall/")" ]]; then
|
||||
echo "[ERROR] Solution directory not found -- 'sfall\\'"
|
||||
exit 1
|
||||
elif [[ ! -f "$(cygpath --unix "$GITHUB_ACTION_PATH/sfall/ddraw.sln")" ]]; then
|
||||
echo "[ERROR] Solution file not found -- 'sfall\\ddraw.sln'"
|
||||
exit 1
|
||||
fi
|
||||
#
|
||||
shell: bash
|
||||
|
||||
# DXSDK directory must be prepared only once, in case action is used N times
|
||||
# Using `.lib` suffix to make sure directory is ignored by git in exotic scenarios
|
||||
# Using `::set-output` to make sure workflow environment remains unchanged
|
||||
- name: Prepare DXSDK directory
|
||||
id: dxsdk
|
||||
run: |
|
||||
DXSDK_DIR="$GITHUB_ACTION_PATH/sfall/DXSDK.lib"
|
||||
if [[ ! -d "$DXSDK_DIR" ]]; then
|
||||
echo "::group::Prepare DXSDK directory"
|
||||
#
|
||||
git clone --quiet https://github.com/NovaRain/DXSDK_Collection.git "$DXSDK_DIR"
|
||||
cp "$DXSDK_DIR/DXSDK_Aug2007/Lib/x86/dinput.lib" "$DXSDK_DIR/DXSDK_Jun2010/Lib/x86/"
|
||||
#
|
||||
echo "::endgroup::"
|
||||
fi
|
||||
echo "::set-output name=dir::$(cygpath --windows "$DXSDK_DIR/DXSDK_Jun2010/")"
|
||||
shell: bash
|
||||
|
||||
# MSBuild is not in PATH on Windows machines
|
||||
# Using `::set-output` to make sure workflow environment remains unchanged
|
||||
- name: Prepare MSBuild
|
||||
id: msbuild
|
||||
run: |
|
||||
echo "::group::Prepare MSBuild"
|
||||
|
||||
MSBUILD_EXE="$("/c/Program Files (x86)/Microsoft Visual Studio/Installer/vswhere.exe" -latest -requires Microsoft.Component.MSBuild -find MSBuild/**/Bin/MSBuild.exe)"
|
||||
echo "::set-output name=exe::$MSBUILD_EXE"
|
||||
|
||||
echo "::endgroup::"
|
||||
shell: bash
|
||||
|
||||
# Creating empty `PostBuild.cmd` to avoid false-positive build error
|
||||
- name: Build ReleaseXP
|
||||
id: build-release-xp
|
||||
run: |
|
||||
if [[ "${{ inputs.release-xp }}" == "true" ]]; then
|
||||
echo ::group::Build ReleaseXP
|
||||
|
||||
#
|
||||
echo "@echo off" > "$GITHUB_ACTION_PATH/sfall/PostBuild.cmd"
|
||||
"${{ steps.msbuild.outputs.exe }}" "$GITHUB_ACTION_PATH/sfall/ddraw.sln" -p:Configuration=ReleaseXP -p:Platform=Win32 -p:PlatformToolset=v140_xp
|
||||
#
|
||||
echo "::set-output name=ddraw-dll::$(cygpath --windows "$GITHUB_ACTION_PATH/sfall/ReleaseXP/ddraw.dll")"
|
||||
|
||||
echo "::endgroup::"
|
||||
fi
|
||||
env:
|
||||
DXSDK_DIR: ${{ steps.dxsdk.outputs.dir }}
|
||||
shell: bash
|
||||
|
||||
# Creating empty `PostBuild.cmd` to avoid false-positive build error
|
||||
- name: Build DevXP
|
||||
id: build-dev-xp
|
||||
run: |
|
||||
:
|
||||
if [[ "${{ inputs.dev-xp }}" == "true" ]]; then
|
||||
echo "::group::Build DevXP"
|
||||
|
||||
#
|
||||
echo "@echo off" > "$GITHUB_ACTION_PATH/sfall/PostBuild.cmd"
|
||||
"${{ steps.msbuild.outputs.exe }}" "$GITHUB_ACTION_PATH/sfall/ddraw.sln" -p:Configuration=DevXP -p:Platform=Win32 -p:PlatformToolset=v140_xp
|
||||
#
|
||||
echo "::set-output name=ddraw-dll::$(cygpath --windows "$GITHUB_ACTION_PATH/sfall/DevXP/ddraw.dll")"
|
||||
echo "::set-output name=ddraw-pdb::$(cygpath --windows "$GITHUB_ACTION_PATH/sfall/DevXP/ddraw.pdb")"
|
||||
|
||||
echo "::endgroup::"
|
||||
fi
|
||||
env:
|
||||
DXSDK_DIR: ${{ steps.dxsdk.outputs.dir }}
|
||||
shell: bash
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user