Compare commits

..

1 commit

Author SHA1 Message Date
Nikita_Silantyev
2cd69f14ab
Я немогу 2018-03-20 16:03:32 +03:00
50 changed files with 10040 additions and 10169 deletions

380
.gitignore vendored
View file

@ -1,362 +1,32 @@
## Ignore Visual Studio temporary files, build results, and
## files generated by popular Visual Studio add-ons.
##
## Get latest from https://github.com/github/gitignore/blob/master/VisualStudio.gitignore
# Prerequisites
*.d
# User-specific files
*.rsuser
*.suo
*.user
*.userosscache
*.sln.docstates
# User-specific files (MonoDevelop/Xamarin Studio)
*.userprefs
# Mono auto generated files
mono_crash.*
# Build results
[Dd]ebug/
[Dd]ebugPublic/
[Rr]elease/
[Rr]eleases/
x64/
x86/
[Ww][Ii][Nn]32/
[Aa][Rr][Mm]/
[Aa][Rr][Mm]64/
bld/
[Bb]in/
[Oo]bj/
[Ll]og/
[Ll]ogs/
# Visual Studio 2015/2017 cache/options directory
.vs/
# Uncomment if you have tasks that create the project's static files in wwwroot
#wwwroot/
# Visual Studio 2017 auto generated files
Generated\ Files/
# MSTest test Results
[Tt]est[Rr]esult*/
[Bb]uild[Ll]og.*
# NUnit
*.VisualState.xml
TestResult.xml
nunit-*.xml
# Build Results of an ATL Project
[Dd]ebugPS/
[Rr]eleasePS/
dlldata.c
# Benchmark Results
BenchmarkDotNet.Artifacts/
# .NET Core
project.lock.json
project.fragment.lock.json
artifacts/
# ASP.NET Scaffolding
ScaffoldingReadMe.txt
# StyleCop
StyleCopReport.xml
# Files built by Visual Studio
*_i.c
*_p.c
*_h.h
*.ilk
*.meta
# Compiled Object files
*.slo
*.lo
*.o
*.obj
*.iobj
# Precompiled Headers
*.gch
*.pch
*.pdb
*.ipdb
*.pgc
*.pgd
*.rsp
*.sbr
*.tlb
*.tli
*.tlh
*.tmp
*.tmp_proj
*_wpftmp.csproj
*.log
*.vspscc
*.vssscc
.builds
*.pidb
*.svclog
*.scc
# Chutzpah Test files
_Chutzpah*
# Compiled Dynamic libraries
*.so
*.dylib
*.dll
# Visual C++ cache files
ipch/
*.aps
*.ncb
*.opendb
*.opensdf
*.sdf
*.cachefile
*.VC.db
*.VC.VC.opendb
# Fortran module files
*.mod
*.smod
# Visual Studio profiler
*.psess
*.vsp
*.vspx
*.sap
# Compiled Static libraries
*.lai
*.la
*.a
*.lib
# Visual Studio Trace Files
*.e2e
# TFS 2012 Local Workspace
$tf/
# Guidance Automation Toolkit
*.gpState
# ReSharper is a .NET coding add-in
_ReSharper*/
*.[Rr]e[Ss]harper
*.DotSettings.user
# TeamCity is a build add-in
_TeamCity*
# DotCover is a Code Coverage Tool
*.dotCover
# AxoCover is a Code Coverage Tool
.axoCover/*
!.axoCover/settings.json
# Coverlet is a free, cross platform Code Coverage Tool
coverage*.json
coverage*.xml
coverage*.info
# Visual Studio code coverage results
*.coverage
*.coveragexml
# NCrunch
_NCrunch_*
.*crunch*.local.xml
nCrunchTemp_*
# MightyMoose
*.mm.*
AutoTest.Net/
# 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
# Note: 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
# Microsoft Azure Web App publish settings. Comment the next line if you want to
# checkin your Azure Web App publish settings, but sensitive information contained
# in these scripts will be unencrypted
PublishScripts/
# NuGet Packages
*.nupkg
# NuGet Symbol Packages
*.snupkg
# The packages folder can be ignored because of Package Restore
**/[Pp]ackages/*
# except build/, which is used as an MSBuild target.
!**/[Pp]ackages/build/
# Uncomment if necessary however generally it will be regenerated when needed
#!**/[Pp]ackages/repositories.config
# NuGet v3's project.json files produces more ignorable files
*.nuget.props
*.nuget.targets
# Microsoft Azure Build Output
csx/
*.build.csdef
# Microsoft Azure Emulator
ecf/
rcf/
# Windows Store app package directories and files
AppPackages/
BundleArtifacts/
Package.StoreAssociation.xml
_pkginfo.txt
*.appx
*.appxbundle
*.appxupload
# 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/
~$*
*~
*.dbmdl
*.dbproj.schemaview
*.jfm
*.pfx
*.publishsettings
orleans.codegen.cs
# Including strong name files can present a security risk
# (https://github.com/github/gitignore/pull/2483#issue-259490424)
#*.snk
# Since there are multiple workflows, uncomment next line to ignore bower_components
# (https://github.com/github/gitignore/pull/1529#issuecomment-104372622)
#bower_components/
# 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
ServiceFabricBackup/
*.rptproj.bak
# SQL Server files
*.mdf
*.ldf
*.ndf
# Business Intelligence projects
*.rdl.data
*.bim.layout
*.bim_*.settings
*.rptproj.rsuser
*- [Bb]ackup.rdl
*- [Bb]ackup ([0-9]).rdl
*- [Bb]ackup ([0-9][0-9]).rdl
# Microsoft Fakes
FakesAssemblies/
# GhostDoc plugin setting file
*.GhostDoc.xml
# Node.js Tools for Visual Studio
.ntvs_analysis.dat
node_modules/
# Visual Studio 6 build log
*.plg
# Visual Studio 6 workspace options file
*.opt
# Visual Studio 6 auto-generated workspace file (contains which files were open etc.)
*.vbw
# Visual Studio LightSwitch build output
**/*.HTMLClient/GeneratedArtifacts
**/*.DesktopClient/GeneratedArtifacts
**/*.DesktopClient/ModelManifest.xml
**/*.Server/GeneratedArtifacts
**/*.Server/ModelManifest.xml
_Pvt_Extensions
# Paket dependency manager
.paket/paket.exe
paket-files/
# FAKE - F# Make
.fake/
# CodeRush personal settings
.cr/personal
# Python Tools for Visual Studio (PTVS)
__pycache__/
*.pyc
# Cake - Uncomment if you are using it
# tools/**
# !tools/packages.config
# Tabs Studio
*.tss
# Telerik's JustMock configuration file
*.jmconfig
# BizTalk build output
*.btp.cs
*.btm.cs
*.odx.cs
*.xsd.cs
# OpenCover UI analysis results
OpenCover/
# Azure Stream Analytics local run output
ASALocalRun/
# MSBuild Binary and Structured Log
*.binlog
# NVidia Nsight GPU debugger configuration file
*.nvuser
# MFractors (Xamarin productivity tool) working folder
.mfractor/
# Local History for Visual Studio
.localhistory/
# BeatPulse healthcheck temp database
healthchecksdb
# Backup folder for Package Reference Convert tool in Visual Studio 2017
MigrationBackup/
# Ionide (cross platform F# VS Code tools) working folder
.ionide/
# Fody - auto-generated XML schema
FodyWeavers.xsd
# Executables
*.exe
*.out
*.app

View file

@ -1,21 +1,5 @@
# MultRedactor
## Что это?
_MultRedactor_ - удобный графический редактор мультфильмов. Вы создаёте персонажей, задаёте им параметры, а эта программка преобразует всё в исходный код C++, и, по нажатию соответствующей кнопки, скомпилирует его. Правда удобно?
## Как использовать?
1. Запустите приложение.
2. В левой части окна, в поле ввода, напишите название мультфильма.
3. Всё в той же левой части выберите фон.
4. Нажмите кнопку "Добавить персонажа".
5. Выберите вид движения, границы (```x,y``` начала и ```x,y``` конца), тайминг (в секундах) и картинку.
6. Назовите своего персонажа (необязательно) и нажмите кнопку "Сохранить персонажа".
7. Если нужно, добавьте ещё персонажей.
8. Нажмите кнопку "Сохранить мульт", выберите расположение файлов и введите название главного файла. Естественно, нужно нажать "Сохранить".
9. Через некоторое время появится сообщение "Готово!". Нажмите кнопку "Компилировать". В открывшемся окошечке всё и так понятно расписано, здесь пояснять ничего не буду.
10. По окончанию компиляции появится сообщение "Готово!". Да, теперь точно готово. Перейдите в каталог с мультфильмом - там найдёте *.exe-файл. Это готовый мультик.
## TODO
- Написать нормальную инструкцию с картинками
- Доделать код движения персонажей, т.к. сейчас это всё очень криво...
- https://docs.google.com/spreadsheets/d/1ka-DjMCEskMYwHZOzJRvlgEZpGA5g-WNFh_pH3sF3y4/edit#gid=1972460334
# MultRedactor
Редактор мультиков
Задачи
https://docs.google.com/spreadsheets/d/1ka-DjMCEskMYwHZOzJRvlgEZpGA5g-WNFh_pH3sF3y4/edit#gid=1972460334

View file

@ -1,49 +0,0 @@
using System;
using System.IO;
namespace WindowsFormsApplication1
{
public class Circle
{
public static void CreatePerson(string filename, string name, Person p)
{
StreamWriter sw = new StreamWriter(filename, true);
sw.Write(Environment.NewLine);
sw.Write(" Person " + name + ";" + Environment.NewLine);
sw.Write(" " + name + ".texture = txLoadImage(\"Pictures\\\\" + Path.GetFileName(p.address) + "\");" + Environment.NewLine);
sw.Write(Environment.NewLine);
sw.Write(" " + name + ".x = " + p.x1 + "; " + Environment.NewLine);
sw.Write(" " + name + ".y = " + p.y1 + "; " + Environment.NewLine);
sw.Write(" " + name + ".x2 = " + p.x2 + "; " + Environment.NewLine);
sw.Write(" " + name + ".y2 = " + p.y2 + "; " + Environment.NewLine);
sw.Write(" " + name + ".angle = 0;" + Environment.NewLine);
sw.Write(" " + name + ".nomer_kadra = 0;" + Environment.NewLine);
sw.Write(Environment.NewLine);
sw.Close();
}
public static void MovePerson(string filename, string name, Person p)
{
StreamWriter sw = new StreamWriter(filename, true);
sw.Write(" if ((myTime >= " + p.time1 + ") && (myTime <= " + p.time2 + ")) {" + Environment.NewLine);
sw.Write(" " + name + ".angle = " + name + ".angle + 360 / 20 * " + p.circles + " / (" + p.time2 + "-" + p.time1 + ");" + Environment.NewLine);
sw.Write(" " + name + ".x = (" + p.x1 + " + " + p.x2 + ")/2 + (" + p.x1 + " - " + p.x2 + ")/2 * cos (" + name + ".angle * 3.1416 / 180);" + Environment.NewLine);
sw.Write(" " + name + ".y = (" + p.y1 + " + " + p.y2 + ")/2 + (" + p.y1 + " - " + p.y2 + ")/2 * sin (" + name + ".angle * 3.1416 / 180);" + Environment.NewLine);
sw.Write(" txTransparentBlt(txDC(), " + name + ".x, " + name + ".y, " +
p.width + "/" + p.sprite + ", " +
p.height + "," +
name + ".texture, " +
p.width + "/" + p.sprite + " * " + name + ".nomer_kadra, 0, RGB(255, 255, 255));" + Environment.NewLine);
sw.Write(Environment.NewLine);
sw.Write(" " + name + ".nomer_kadra++;" + Environment.NewLine);
sw.Write(Environment.NewLine);
sw.Write(" if (" + name + ".nomer_kadra >= " + p.sprite + ")" + Environment.NewLine);
sw.Write(" {" + Environment.NewLine);
sw.Write(" " + name + ".nomer_kadra = 0;" + Environment.NewLine);
sw.Write(" }" + Environment.NewLine);
sw.Write(" }" + Environment.NewLine);
sw.Write(Environment.NewLine);
sw.Close();
}
}
}

View file

@ -1,142 +0,0 @@
namespace WindowsFormsApplication1
{
partial class CompileForm
{
/// <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.label1 = new System.Windows.Forms.Label();
this.textBox1 = new System.Windows.Forms.TextBox();
this.button1 = new System.Windows.Forms.Button();
this.linkLabel1 = new System.Windows.Forms.LinkLabel();
this.folderBrowserDialog1 = new System.Windows.Forms.FolderBrowserDialog();
this.button2 = new System.Windows.Forms.Button();
this.textBox2 = new System.Windows.Forms.TextBox();
this.label2 = new System.Windows.Forms.Label();
this.SuspendLayout();
//
// label1
//
this.label1.AutoSize = true;
this.label1.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(204)));
this.label1.Location = new System.Drawing.Point(12, 9);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(196, 13);
this.label1.TabIndex = 0;
this.label1.Text = "Полный путь к каталогу MinGW";
//
// textBox1
//
this.textBox1.Location = new System.Drawing.Point(12, 25);
this.textBox1.Name = "textBox1";
this.textBox1.Size = new System.Drawing.Size(196, 20);
this.textBox1.TabIndex = 1;
//
// button1
//
this.button1.Location = new System.Drawing.Point(214, 24);
this.button1.Name = "button1";
this.button1.Size = new System.Drawing.Size(74, 22);
this.button1.TabIndex = 2;
this.button1.Text = "Обзор...";
this.button1.UseVisualStyleBackColor = true;
this.button1.Click += new System.EventHandler(this.button1_Click);
//
// linkLabel1
//
this.linkLabel1.AutoSize = true;
this.linkLabel1.Location = new System.Drawing.Point(12, 48);
this.linkLabel1.Name = "linkLabel1";
this.linkLabel1.Size = new System.Drawing.Size(257, 13);
this.linkLabel1.TabIndex = 3;
this.linkLabel1.TabStop = true;
this.linkLabel1.Text = "У меня нет установленного компилятора MinGW";
this.linkLabel1.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.linkLabel1_LinkClicked);
//
// button2
//
this.button2.Dock = System.Windows.Forms.DockStyle.Bottom;
this.button2.Font = new System.Drawing.Font("Tahoma", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(204)));
this.button2.Location = new System.Drawing.Point(0, 176);
this.button2.Name = "button2";
this.button2.Size = new System.Drawing.Size(300, 28);
this.button2.TabIndex = 4;
this.button2.Text = "Старт!";
this.button2.UseVisualStyleBackColor = true;
this.button2.Click += new System.EventHandler(this.button2_Click);
//
// textBox2
//
this.textBox2.Location = new System.Drawing.Point(12, 85);
this.textBox2.Multiline = true;
this.textBox2.Name = "textBox2";
this.textBox2.ScrollBars = System.Windows.Forms.ScrollBars.Vertical;
this.textBox2.Size = new System.Drawing.Size(276, 82);
this.textBox2.TabIndex = 5;
//
// label2
//
this.label2.AutoSize = true;
this.label2.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(204)));
this.label2.Location = new System.Drawing.Point(12, 69);
this.label2.Name = "label2";
this.label2.Size = new System.Drawing.Size(127, 13);
this.label2.TabIndex = 6;
this.label2.Text = "Вывод компилятора";
//
// CompileForm
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(300, 204);
this.Controls.Add(this.label2);
this.Controls.Add(this.textBox2);
this.Controls.Add(this.button2);
this.Controls.Add(this.linkLabel1);
this.Controls.Add(this.button1);
this.Controls.Add(this.textBox1);
this.Controls.Add(this.label1);
this.MaximizeBox = false;
this.MinimizeBox = false;
this.Name = "CompileForm";
this.Text = "Компилировать";
this.ResumeLayout(false);
this.PerformLayout();
}
#endregion
private System.Windows.Forms.Label label1;
private System.Windows.Forms.TextBox textBox1;
private System.Windows.Forms.Button button1;
private System.Windows.Forms.LinkLabel linkLabel1;
private System.Windows.Forms.FolderBrowserDialog folderBrowserDialog1;
private System.Windows.Forms.Button button2;
private System.Windows.Forms.TextBox textBox2;
private System.Windows.Forms.Label label2;
}
}

View file

@ -1,95 +0,0 @@
using System;
using System.Diagnostics;
using System.IO;
using System.Text;
using System.Threading;
using System.Windows.Forms;
namespace WindowsFormsApplication1
{
public partial class CompileForm : Form
{
private string codeFilename = "";
private string mingwDir = "";
public CompileForm(string _codeFilename)
{
InitializeComponent();
codeFilename = _codeFilename;
}
private void linkLabel1_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
{
if (MessageBox.Show("Для создания *.exe-файла мультфильма нужна специальная программа - компилятор.\n" +
"Мы используем компилятор MinGW. Чтобы его скачать, нажмите OK в этом диалоге,\n" +
"но учтите, что все нужные файлы весят ≈800МиБ!\n\n" +
"После загрузки Вам нужно распаковать архив в удобное Вам место,\n" +
"а затем, в этом окне, выбрать каталог mingw, который теперь лежит в \"удобном Вам месте\".",
"Скачать MinGW", MessageBoxButtons.OKCancel, MessageBoxIcon.Information).ToString() == "OK")
{
Process.Start("https://is.gd/Krp8r4");
}
}
private void button1_Click(object sender, EventArgs e)
{
if (folderBrowserDialog1.ShowDialog().ToString() == "OK")
{
mingwDir = folderBrowserDialog1.SelectedPath;
}
textBox1.Text = mingwDir;
}
private void button2_Click(object sender, EventArgs e)
{
if (mingwDir != "")
{
try
{
textBox2.Text += ("Компиляция " + codeFilename + " в " +
Path.GetFileNameWithoutExtension(codeFilename) + ".exe с помощью " +
mingwDir + "\\bin\\mingw32-g++.exe:" + Environment.NewLine + Environment.NewLine);
new Thread(new ThreadStart(CompilingFunction)).Start();
}
catch (Exception ex)
{
_ = MessageBox.Show("Произошла ошибка!\n" + ex.Message);
}
}
else
{
_ = MessageBox.Show("Сначала укажите каталог с MinGW!", "Ошибка",
MessageBoxButtons.OK, MessageBoxIcon.Error);
}
}
private void CompilingFunction()
{
Process mingwp = new Process();
mingwp.StartInfo = new ProcessStartInfo()
{
FileName = mingwDir + "\\bin\\mingw32-g++.exe",
Arguments = codeFilename + " -o " + Path.GetDirectoryName(codeFilename) + "\\" +
Path.GetFileNameWithoutExtension(codeFilename) + ".exe",
UseShellExecute = false,
WindowStyle = ProcessWindowStyle.Hidden,
StandardOutputEncoding = Encoding.GetEncoding(866),
StandardErrorEncoding = Encoding.GetEncoding(866),
CreateNoWindow = true,
RedirectStandardOutput = true,
RedirectStandardError = true
};
mingwp.OutputDataReceived += new DataReceivedEventHandler(CompilerOutputHandler);
mingwp.ErrorDataReceived += new DataReceivedEventHandler(CompilerOutputHandler);
mingwp.Start();
mingwp.BeginOutputReadLine();
mingwp.BeginErrorReadLine();
mingwp.WaitForExit(20000);
textBox2.Invoke(new Action(() => { textBox2.AppendText("Готово!" + Environment.NewLine); }));
}
private void CompilerOutputHandler(object sendingProcess, DataReceivedEventArgs outputLine)
{
textBox2.Invoke(new Action(() => { textBox2.AppendText(outputLine.Data + Environment.NewLine); }));
}
}
}

View file

@ -1,89 +0,0 @@
using System;
using System.IO;
using System.Windows.Forms;
namespace WindowsFormsApplication1
{
public class Files
{
public static void CreateStruct(string filename)
{
File.WriteAllText(filename, "");
StreamWriter sw = new StreamWriter(filename);
sw.Write("#include \"TXLib.h\"" + Environment.NewLine);
sw.Write( Environment.NewLine);
sw.Write("struct Person" + Environment.NewLine);
sw.Write("{" + Environment.NewLine);
sw.Write(" double x;" + Environment.NewLine);
sw.Write(" double x2;" + Environment.NewLine);
sw.Write(" double y;" + Environment.NewLine);
sw.Write(" double y2;" + Environment.NewLine);
sw.Write(" double angle;" + Environment.NewLine);
sw.Write(" double nomer_kadra;" + Environment.NewLine);
sw.Write(" HDC texture;" + Environment.NewLine);
sw.Write(" int MID_x;" + Environment.NewLine);
sw.Write(" int MID_y;" + Environment.NewLine);
sw.Write(" int rad;" + Environment.NewLine);
sw.Write(" int skorost;" + Environment.NewLine);
sw.Write(" int gr_dvigx;" + Environment.NewLine);
sw.Write(" int gr_dvigy;" + Environment.NewLine);
sw.Write(" int nach_dv;" + Environment.NewLine);
sw.Write(" int ampl_y;" + Environment.NewLine);
sw.Write(" int ampl_x;" + Environment.NewLine);
sw.Write(" double BeginTime;" + Environment.NewLine);
sw.Write(" double EndTime;" + Environment.NewLine);
sw.Write(" double Time;" + Environment.NewLine);
sw.Write("};" + Environment.NewLine);
sw.Write( Environment.NewLine);
sw.Close();
}
public static void OpenMain(string filename, PictureBox PictureBoxBackground, String addressBackground)
{
StreamWriter sw = new StreamWriter(filename, true);
sw.Write("int main()" + Environment.NewLine);
sw.Write("{" + Environment.NewLine);
sw.Write(" txCreateWindow(" +
PictureBoxBackground.Image.Width.ToString() + ", " +
PictureBoxBackground.Image.Height.ToString() + ");" + Environment.NewLine);
sw.Write(" double myTime = 0;" + Environment.NewLine);
sw.Write(" HDC texture = txLoadImage(\"Pictures\\\\" + Path.GetFileName(addressBackground) + "\");" +
Environment.NewLine);
sw.Close();
}
public static void CloseWhile(string filename)
{
StreamWriter sw = new StreamWriter(filename, true);
sw.Write(Environment.NewLine);
sw.Write(" myTime += 0.05;" + Environment.NewLine);
sw.Write(" txSleep(50);" + Environment.NewLine);
sw.Write(" }" + Environment.NewLine);
sw.Close();
}
public static void OpenWhile(string filename, int maxTime)
{
StreamWriter sw = new StreamWriter(filename, true);
sw.Write(Environment.NewLine);
sw.Write(" while (myTime <= " + maxTime + ")" + Environment.NewLine);
sw.Write(" {" + Environment.NewLine);
sw.Write(" txSetColor(TX_RED);" + Environment.NewLine);
sw.Write(" txSetFillColor(TX_RED);" + Environment.NewLine);
sw.Write(" txBitBlt(txDC(), 0, 0, txGetExtentX(), txGetExtentY(), texture, 0, 0);" +
Environment.NewLine);
sw.Close();
}
public static void Ending(string filename, bool autoexit = false)
{
StreamWriter sw = new StreamWriter(filename, true);
sw.Write(" txDeleteDC(texture);" + Environment.NewLine);
if (autoexit)
sw.Write(" txDisableAutoPause();");
sw.Write(" return 0;" + Environment.NewLine);
sw.Write("}" + Environment.NewLine);
sw.Close();
}
}
}

View file

@ -0,0 +1,421 @@
namespace WindowsFormsApplication1
{
partial class MainForm
{
/// <summary>
/// Требуется переменная конструктора.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Освободить все используемые ресурсы.
/// </summary>
/// <param name="disposing">истинно, если управляемый ресурс должен быть удален; иначе ложно.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Код, автоматически созданный конструктором форм Windows
/// <summary>
/// Обязательный метод для поддержки конструктора - не изменяйте
/// содержимое данного метода при помощи редактора кода.
/// </summary>
private void InitializeComponent()
{
this.label1 = new System.Windows.Forms.Label();
this.label2 = new System.Windows.Forms.Label();
this.label3 = new System.Windows.Forms.Label();
this.nazvanieTextBox = new System.Windows.Forms.TextBox();
this.panel1 = new System.Windows.Forms.Panel();
this.label14 = new System.Windows.Forms.Label();
this.dobavitFonButton = new System.Windows.Forms.Button();
this.splitter1 = new System.Windows.Forms.Splitter();
this.panel2 = new System.Windows.Forms.Panel();
this.button3 = new System.Windows.Forms.Button();
this.panel3 = new System.Windows.Forms.Panel();
this.spriteLabel = new System.Windows.Forms.Label();
this.spriteTextBox = new System.Windows.Forms.TextBox();
this.button5 = new System.Windows.Forms.Button();
this.button4 = new System.Windows.Forms.Button();
this.label12 = new System.Windows.Forms.Label();
this.label11 = new System.Windows.Forms.Label();
this.label10 = new System.Windows.Forms.Label();
this.label9 = new System.Windows.Forms.Label();
this.label8 = new System.Windows.Forms.Label();
this.textBox7 = new System.Windows.Forms.TextBox();
this.textBox6 = new System.Windows.Forms.TextBox();
this.textBox5 = new System.Windows.Forms.TextBox();
this.textBox4 = new System.Windows.Forms.TextBox();
this.comboBox2 = new System.Windows.Forms.ComboBox();
this.label7 = new System.Windows.Forms.Label();
this.button2 = new System.Windows.Forms.Button();
this.button1 = new System.Windows.Forms.Button();
this.saveFileDialog1 = new System.Windows.Forms.SaveFileDialog();
this.openFileDialog1 = new System.Windows.Forms.OpenFileDialog();
this.pictureBox1 = new System.Windows.Forms.PictureBox();
this.panel1.SuspendLayout();
this.panel2.SuspendLayout();
this.panel3.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).BeginInit();
this.SuspendLayout();
//
// label1
//
this.label1.AutoSize = true;
this.label1.Font = new System.Drawing.Font("Arial Black", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(204)));
this.label1.Location = new System.Drawing.Point(0, 9);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(224, 23);
this.label1.TabIndex = 0;
this.label1.Text = "Данные о мултфильме:";
this.label1.Click += new System.EventHandler(this.label1_Click);
//
// label2
//
this.label2.AutoSize = true;
this.label2.Location = new System.Drawing.Point(14, 60);
this.label2.Name = "label2";
this.label2.Size = new System.Drawing.Size(136, 13);
this.label2.TabIndex = 1;
this.label2.Text = "Длительность: 35 секунд";
//
// label3
//
this.label3.AutoSize = true;
this.label3.Location = new System.Drawing.Point(14, 86);
this.label3.Name = "label3";
this.label3.Size = new System.Drawing.Size(60, 13);
this.label3.TabIndex = 2;
this.label3.Text = "Название:";
this.label3.Click += new System.EventHandler(this.label3_Click);
//
// nazvanieTextBox
//
this.nazvanieTextBox.Location = new System.Drawing.Point(80, 86);
this.nazvanieTextBox.Name = "nazvanieTextBox";
this.nazvanieTextBox.Size = new System.Drawing.Size(138, 20);
this.nazvanieTextBox.TabIndex = 3;
//
// panel1
//
this.panel1.Controls.Add(this.pictureBox1);
this.panel1.Controls.Add(this.label14);
this.panel1.Controls.Add(this.dobavitFonButton);
this.panel1.Controls.Add(this.label1);
this.panel1.Controls.Add(this.nazvanieTextBox);
this.panel1.Controls.Add(this.label2);
this.panel1.Controls.Add(this.label3);
this.panel1.Dock = System.Windows.Forms.DockStyle.Left;
this.panel1.Location = new System.Drawing.Point(0, 0);
this.panel1.Name = "panel1";
this.panel1.Size = new System.Drawing.Size(227, 296);
this.panel1.TabIndex = 4;
//
// label14
//
this.label14.AutoSize = true;
this.label14.Location = new System.Drawing.Point(14, 114);
this.label14.Name = "label14";
this.label14.Size = new System.Drawing.Size(77, 13);
this.label14.TabIndex = 11;
this.label14.Text = "Выбрать фон:";
//
// dobavitFonButton
//
this.dobavitFonButton.Location = new System.Drawing.Point(17, 130);
this.dobavitFonButton.Name = "dobavitFonButton";
this.dobavitFonButton.Size = new System.Drawing.Size(116, 24);
this.dobavitFonButton.TabIndex = 10;
this.dobavitFonButton.Text = "Добавить";
this.dobavitFonButton.UseVisualStyleBackColor = true;
this.dobavitFonButton.Click += new System.EventHandler(this.button6_Click);
//
// splitter1
//
this.splitter1.Location = new System.Drawing.Point(227, 0);
this.splitter1.Name = "splitter1";
this.splitter1.Size = new System.Drawing.Size(3, 296);
this.splitter1.TabIndex = 5;
this.splitter1.TabStop = false;
//
// panel2
//
this.panel2.Controls.Add(this.button3);
this.panel2.Controls.Add(this.panel3);
this.panel2.Controls.Add(this.button2);
this.panel2.Controls.Add(this.button1);
this.panel2.Dock = System.Windows.Forms.DockStyle.Fill;
this.panel2.Location = new System.Drawing.Point(230, 0);
this.panel2.Name = "panel2";
this.panel2.Size = new System.Drawing.Size(408, 296);
this.panel2.TabIndex = 6;
//
// button3
//
this.button3.Dock = System.Windows.Forms.DockStyle.Bottom;
this.button3.Location = new System.Drawing.Point(0, 236);
this.button3.Name = "button3";
this.button3.Size = new System.Drawing.Size(408, 30);
this.button3.TabIndex = 3;
this.button3.Text = "Сохранить персонажа";
this.button3.UseVisualStyleBackColor = true;
this.button3.Click += new System.EventHandler(this.button3_Click);
//
// panel3
//
this.panel3.Controls.Add(this.spriteLabel);
this.panel3.Controls.Add(this.spriteTextBox);
this.panel3.Controls.Add(this.button5);
this.panel3.Controls.Add(this.button4);
this.panel3.Controls.Add(this.label12);
this.panel3.Controls.Add(this.label11);
this.panel3.Controls.Add(this.label10);
this.panel3.Controls.Add(this.label9);
this.panel3.Controls.Add(this.label8);
this.panel3.Controls.Add(this.textBox7);
this.panel3.Controls.Add(this.textBox6);
this.panel3.Controls.Add(this.textBox5);
this.panel3.Controls.Add(this.textBox4);
this.panel3.Controls.Add(this.comboBox2);
this.panel3.Controls.Add(this.label7);
this.panel3.Dock = System.Windows.Forms.DockStyle.Fill;
this.panel3.Location = new System.Drawing.Point(0, 26);
this.panel3.Name = "panel3";
this.panel3.Size = new System.Drawing.Size(408, 240);
this.panel3.TabIndex = 2;
this.panel3.Visible = false;
//
// spriteLabel
//
this.spriteLabel.AutoSize = true;
this.spriteLabel.Location = new System.Drawing.Point(7, 153);
this.spriteLabel.Name = "spriteLabel";
this.spriteLabel.Size = new System.Drawing.Size(119, 13);
this.spriteLabel.TabIndex = 16;
this.spriteLabel.Text = "Количество спрайтов:";
this.spriteLabel.Click += new System.EventHandler(this.label13_Click_1);
//
// spriteTextBox
//
this.spriteTextBox.Location = new System.Drawing.Point(10, 169);
this.spriteTextBox.Name = "spriteTextBox";
this.spriteTextBox.Size = new System.Drawing.Size(83, 20);
this.spriteTextBox.TabIndex = 15;
//
// button5
//
this.button5.Location = new System.Drawing.Point(221, 160);
this.button5.Name = "button5";
this.button5.Size = new System.Drawing.Size(171, 30);
this.button5.TabIndex = 14;
this.button5.Text = "Открыть персонажа";
this.button5.UseVisualStyleBackColor = true;
this.button5.Click += new System.EventHandler(this.button5_Click);
//
// button4
//
this.button4.Location = new System.Drawing.Point(132, 169);
this.button4.Name = "button4";
this.button4.Size = new System.Drawing.Size(65, 20);
this.button4.TabIndex = 13;
this.button4.Text = "Добавить";
this.button4.UseVisualStyleBackColor = true;
this.button4.Click += new System.EventHandler(this.button4_Click);
//
// label12
//
this.label12.AutoSize = true;
this.label12.Location = new System.Drawing.Point(129, 153);
this.label12.Name = "label12";
this.label12.Size = new System.Drawing.Size(58, 13);
this.label12.TabIndex = 12;
this.label12.Text = "Картинка:";
//
// label11
//
this.label11.AutoSize = true;
this.label11.Location = new System.Drawing.Point(19, 91);
this.label11.Name = "label11";
this.label11.Size = new System.Drawing.Size(54, 13);
this.label11.TabIndex = 11;
this.label11.Text = "Тайминг:";
//
// label10
//
this.label10.AutoSize = true;
this.label10.Location = new System.Drawing.Point(240, 91);
this.label10.Name = "label10";
this.label10.Size = new System.Drawing.Size(13, 13);
this.label10.TabIndex = 10;
this.label10.Text = "--";
this.label10.Click += new System.EventHandler(this.label10_Click);
//
// label9
//
this.label9.AutoSize = true;
this.label9.Location = new System.Drawing.Point(240, 62);
this.label9.Name = "label9";
this.label9.Size = new System.Drawing.Size(13, 13);
this.label9.TabIndex = 9;
this.label9.Text = "--";
this.label9.Click += new System.EventHandler(this.label9_Click);
//
// label8
//
this.label8.AutoSize = true;
this.label8.Location = new System.Drawing.Point(19, 62);
this.label8.Name = "label8";
this.label8.Size = new System.Drawing.Size(107, 13);
this.label8.TabIndex = 8;
this.label8.Text = "Границы движения:";
this.label8.Click += new System.EventHandler(this.label8_Click);
//
// textBox7
//
this.textBox7.Location = new System.Drawing.Point(132, 88);
this.textBox7.Name = "textBox7";
this.textBox7.Size = new System.Drawing.Size(100, 20);
this.textBox7.TabIndex = 5;
//
// textBox6
//
this.textBox6.Location = new System.Drawing.Point(259, 88);
this.textBox6.Name = "textBox6";
this.textBox6.Size = new System.Drawing.Size(100, 20);
this.textBox6.TabIndex = 4;
this.textBox6.TextChanged += new System.EventHandler(this.textBox6_TextChanged);
//
// textBox5
//
this.textBox5.Location = new System.Drawing.Point(259, 59);
this.textBox5.Name = "textBox5";
this.textBox5.Size = new System.Drawing.Size(100, 20);
this.textBox5.TabIndex = 3;
//
// textBox4
//
this.textBox4.Location = new System.Drawing.Point(132, 59);
this.textBox4.Name = "textBox4";
this.textBox4.Size = new System.Drawing.Size(100, 20);
this.textBox4.TabIndex = 2;
//
// comboBox2
//
this.comboBox2.FormattingEnabled = true;
this.comboBox2.Items.AddRange(new object[] {
"Прямо",
"По диагонали",
"Волнами",
"Кругами"});
this.comboBox2.Location = new System.Drawing.Point(107, 12);
this.comboBox2.Name = "comboBox2";
this.comboBox2.Size = new System.Drawing.Size(121, 21);
this.comboBox2.TabIndex = 1;
this.comboBox2.Text = "Прямо";
//
// label7
//
this.label7.AutoSize = true;
this.label7.Location = new System.Drawing.Point(19, 12);
this.label7.Name = "label7";
this.label7.Size = new System.Drawing.Size(82, 13);
this.label7.TabIndex = 0;
this.label7.Text = "Вид движения:";
//
// button2
//
this.button2.Dock = System.Windows.Forms.DockStyle.Bottom;
this.button2.Location = new System.Drawing.Point(0, 266);
this.button2.Name = "button2";
this.button2.Size = new System.Drawing.Size(408, 30);
this.button2.TabIndex = 1;
this.button2.Text = "Сохранить мульт";
this.button2.UseVisualStyleBackColor = true;
//
// button1
//
this.button1.Dock = System.Windows.Forms.DockStyle.Top;
this.button1.Location = new System.Drawing.Point(0, 0);
this.button1.Name = "button1";
this.button1.Size = new System.Drawing.Size(408, 26);
this.button1.TabIndex = 0;
this.button1.Text = "Добавить персонажа";
this.button1.UseVisualStyleBackColor = true;
this.button1.Click += new System.EventHandler(this.button1_Click);
//
// openFileDialog1
//
this.openFileDialog1.FileName = "openFileDialog1";
//
// pictureBox1
//
this.pictureBox1.Location = new System.Drawing.Point(17, 160);
this.pictureBox1.Name = "pictureBox1";
this.pictureBox1.Size = new System.Drawing.Size(100, 50);
this.pictureBox1.TabIndex = 12;
this.pictureBox1.TabStop = false;
//
// MainForm
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(638, 296);
this.Controls.Add(this.panel2);
this.Controls.Add(this.splitter1);
this.Controls.Add(this.panel1);
this.Name = "MainForm";
this.RightToLeftLayout = true;
this.Text = "Свойства персонажа";
this.Load += new System.EventHandler(this.Form1_Load);
this.panel1.ResumeLayout(false);
this.panel1.PerformLayout();
this.panel2.ResumeLayout(false);
this.panel3.ResumeLayout(false);
this.panel3.PerformLayout();
((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).EndInit();
this.ResumeLayout(false);
}
#endregion
private System.Windows.Forms.Label label1;
private System.Windows.Forms.Label label2;
private System.Windows.Forms.Label label3;
private System.Windows.Forms.TextBox nazvanieTextBox;
private System.Windows.Forms.Panel panel1;
private System.Windows.Forms.Splitter splitter1;
private System.Windows.Forms.Panel panel2;
private System.Windows.Forms.Button button2;
private System.Windows.Forms.Button button1;
private System.Windows.Forms.Panel panel3;
private System.Windows.Forms.Label label7;
private System.Windows.Forms.TextBox textBox7;
private System.Windows.Forms.TextBox textBox6;
private System.Windows.Forms.TextBox textBox5;
private System.Windows.Forms.TextBox textBox4;
private System.Windows.Forms.ComboBox comboBox2;
private System.Windows.Forms.Label label9;
private System.Windows.Forms.Label label8;
private System.Windows.Forms.Label label11;
private System.Windows.Forms.Label label10;
private System.Windows.Forms.Button button3;
private System.Windows.Forms.Button button4;
private System.Windows.Forms.Label label12;
private System.Windows.Forms.SaveFileDialog saveFileDialog1;
private System.Windows.Forms.Button button5;
private System.Windows.Forms.OpenFileDialog openFileDialog1;
private System.Windows.Forms.Label spriteLabel;
private System.Windows.Forms.TextBox spriteTextBox;
private System.Windows.Forms.Label label14;
private System.Windows.Forms.Button dobavitFonButton;
private System.Windows.Forms.PictureBox pictureBox1;
}
}

View file

@ -0,0 +1,161 @@
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
namespace WindowsFormsApplication1
{
public struct Personazh
{
public string ce_nibud;
public string nazvanie_personazha;
}
public partial class MainForm : Form
{
PictureBox[] pic1 = new PictureBox[1000];
public MainForm()
{
InitializeComponent();
button1.Click += button1_Click;
button3.Click += button3_Click;
openFileDialog1.Filter = "Text files(*OpenFileDialog.txt)|*.txt|All files(*.*)|*.*";
saveFileDialog1.Filter = "Text files(*SaveFileDialog.txt)|*.txt|All files(*.*)|*.*";
}
private void Form1_Load(object sender, EventArgs e)
{
/*int i=0;
for (; i < 10; i++)
{
PictureBox pic2 = new PictureBox();
pic2.Location = new Point(pic2.Location.X + (i*100), pic2.Location.Y);
pic2.BorderStyle = BorderStyle.FixedSingle;
pic1[i] = pic2;
Controls.Add(pic1[i]);
}*/
}
private void label1_Click(object sender, EventArgs e)
{
}
private void label3_Click(object sender, EventArgs e)
{
}
private void textBox3_TextChanged(object sender, EventArgs e)
{
}
private void button1_Click(object sender, EventArgs e)
{
panel3.Visible = true;
}
private void label9_Click(object sender, EventArgs e)
{
}
private void label10_Click(object sender, EventArgs e)
{
}
private void button4_Click(object sender, EventArgs e)
{
//Список всех файлов папки
//Создаешь из них массив (или список)
//Выбираешь рандомный номер
//pictureBox1.Image = Image.FromFile("kartinka.jpg");
}
private void pictureBox1_Click(object sender, EventArgs e)
{
}
private void button3_Click(object sender, EventArgs e)
{
if (saveFileDialog1.ShowDialog() == DialogResult.Cancel)
return;
string filename = saveFileDialog1.FileName;
System.IO.File.WriteAllText(filename, "");
System.IO.File.AppendAllText(filename, "#include \"TXLib.h\"" + Environment.NewLine);
System.IO.File.AppendAllText(filename, Environment.NewLine);
System.IO.File.AppendAllText(filename, "int main()" + Environment.NewLine);
System.IO.File.AppendAllText(filename, "{" + Environment.NewLine);
//txCreateWindow(800, 600);
System.IO.File.AppendAllText(filename, Environment.NewLine);
System.IO.File.AppendAllText(filename, "txSetColor(TX_WHITE);" + Environment.NewLine);
System.IO.File.AppendAllText(filename, "txSetFillColor(TX_WHITE);" + Environment.NewLine);
System.IO.File.AppendAllText(filename, "txRectangle(0, 0, 800, 600);" + Environment.NewLine);
System.IO.File.AppendAllText(filename, "HDC texture = txLoadImage(\"Pictures\\Personaj.bmp\");" + Environment.NewLine);
//тут будет мультфильм
System.IO.File.AppendAllText(filename, "return " + spriteTextBox.Text + "0;" + Environment.NewLine);
System.IO.File.AppendAllText(filename, "}" + Environment.NewLine);
MessageBox.Show("Файл сохранен");
}
private void button5_Click(object sender, EventArgs e)
{
if (openFileDialog1.ShowDialog() == DialogResult.Cancel)
return;
string filename = openFileDialog1.FileName;
string fileText = System.IO.File.ReadAllText(filename);
nazvanieTextBox.Text = fileText;
MessageBox.Show("Файл открыт");
}
private void textBox6_TextChanged(object sender, EventArgs e)
{
}
private void label8_Click(object sender, EventArgs e)
{
}
private void label13_Click(object sender, EventArgs e)
{
}
private void label13_Click_1(object sender, EventArgs e)
{
}
private void button6_Click(object sender, EventArgs e)
{
if (openFileDialog1.ShowDialog() == DialogResult.Cancel)
return;
string filename = openFileDialog1.FileName;
string fileText = System.IO.File.ReadAllText(filename);
nazvanieTextBox.Text = fileText;
//MessageBox.Show("Файл открыт");
pictureBox1.Image = Image.FromFile("kartinka.jpg");
}
}
}

View file

@ -1,126 +1,129 @@
<?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=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<metadata name="folderBrowserDialog1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>17, 17</value>
</metadata>
<metadata name="$this.TrayHeight" type="System.Int32, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>25</value>
</metadata>
<?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=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<metadata name="saveFileDialog1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>17, 17</value>
</metadata>
<metadata name="openFileDialog1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>153, 17</value>
</metadata>
<metadata name="$this.TrayHeight" type="System.Int32, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>39</value>
</metadata>
</root>

View file

@ -1,51 +0,0 @@
using System;
using System.IO;
namespace WindowsFormsApplication1
{
public class Line
{
public static void CreatePerson(string filename, string name, Person p)
{
StreamWriter sw = new StreamWriter(filename, true);
sw.Write(Environment.NewLine);
sw.Write(" Person " + name + ";" + Environment.NewLine);
sw.Write(" " + name + ".x = " + p.x1 + "; " + Environment.NewLine);
sw.Write(" " + name + ".y = " + p.y1 + "; " + Environment.NewLine);
sw.Write(" " + name + ".x2 = " + p.x2 + "; " + Environment.NewLine);
sw.Write(" " + name + ".y2 = " + p.y2 + "; " + Environment.NewLine);
sw.Write(" " + name + ".nomer_kadra = 0; " + Environment.NewLine);
sw.Write(" " + name + ".texture = txLoadImage(\"Pictures\\\\" + Path.GetFileName(p.address) + "\"); " +
Environment.NewLine);
sw.Write(Environment.NewLine);
sw.Close();
}
public static void MovePerson(string filename, string name, Person p)
{
StreamWriter sw = new StreamWriter(filename, true);
sw.Write(" if ((myTime >= " + p.time1 + ") && (myTime <= " + p.time2 + ")) {" +
Environment.NewLine);
sw.Write(" " + name + ".x+= (" + name + ".x2 - " + name + ".x) / (" +
p.time2 + "-" + p.time1 + ");" + Environment.NewLine);
sw.Write(" " + name + ".y+= (" + name + ".y2 - " + name + ".y) / (" +
p.time2 + "-" + p.time1 + ");" + Environment.NewLine);
sw.Write(" txTransparentBlt(txDC(), " + name + ".x, " + name + ".y, " +
p.width + "/" + p.sprite + ", " +
p.height + "," +
name + ".texture, " +
p.width + "/" + p.sprite + " * " + name + ".nomer_kadra, 0, RGB(255, 255, 255));" + Environment.NewLine);
sw.Write(Environment.NewLine);
sw.Write(" " + name + ".nomer_kadra++;" + Environment.NewLine);
sw.Write(Environment.NewLine);
sw.Write(" if (" + name + ".nomer_kadra >= " + p.sprite + ")" +
Environment.NewLine);
sw.Write(" {" + Environment.NewLine);
sw.Write(" " + name + ".nomer_kadra = 0;" + Environment.NewLine);
sw.Write(" }" + Environment.NewLine);
sw.Write(" }" + Environment.NewLine);
sw.Write(Environment.NewLine);
sw.Close();
}
}
}

View file

@ -1,4 +1,4 @@
namespace WindowsFormsApplication1
namespace WindowsFormsApplication1
{
partial class MainForm
{
@ -32,26 +32,37 @@ namespace WindowsFormsApplication1
this.LabelLengh = new System.Windows.Forms.Label();
this.LabelName = new System.Windows.Forms.Label();
this.nazvanieTextBox = new System.Windows.Forms.TextBox();
this.leftPanel = new System.Windows.Forms.Panel();
this.panel1 = new System.Windows.Forms.Panel();
this.label13 = new System.Windows.Forms.Label();
this.label12 = new System.Windows.Forms.Label();
this.label11 = new System.Windows.Forms.Label();
this.label10 = new System.Windows.Forms.Label();
this.label9 = new System.Windows.Forms.Label();
this.label8 = new System.Windows.Forms.Label();
this.label7 = new System.Windows.Forms.Label();
this.label6 = new System.Windows.Forms.Label();
this.label4 = new System.Windows.Forms.Label();
this.label5 = new System.Windows.Forms.Label();
this.label3 = new System.Windows.Forms.Label();
this.label2 = new System.Windows.Forms.Label();
this.button4 = new System.Windows.Forms.Button();
this.button3 = new System.Windows.Forms.Button();
this.button2 = new System.Windows.Forms.Button();
this.label1 = new System.Windows.Forms.Label();
this.button6 = new System.Windows.Forms.Button();
this.button5 = new System.Windows.Forms.Button();
this.button1 = new System.Windows.Forms.Button();
this.checkBox1 = new System.Windows.Forms.CheckBox();
this.Char_Stats = new System.Windows.Forms.Label();
this.Char_Info = new System.Windows.Forms.Label();
this.PictureBoxBackground = new System.Windows.Forms.PictureBox();
this.LabelBackground = new System.Windows.Forms.Label();
this.dobavitFonButton = new System.Windows.Forms.Button();
this.splitter1 = new System.Windows.Forms.Splitter();
this.rightPanel = new System.Windows.Forms.Panel();
this.panel2 = new System.Windows.Forms.Panel();
this.SaveCharButton = new System.Windows.Forms.Button();
this.personPanel = new System.Windows.Forms.Panel();
this.SpriteNumberTextBox = new System.Windows.Forms.NumericUpDown();
this.charNameBox = new System.Windows.Forms.TextBox();
this.circlesTextBox = new System.Windows.Forms.TextBox();
this.circlesLabel = new System.Windows.Forms.Label();
this.charNameLabel = new System.Windows.Forms.Label();
this.openSpace = new System.Windows.Forms.PictureBox();
this.panel3 = new System.Windows.Forms.Panel();
this.SpriteNumberLabel = new System.Windows.Forms.Label();
this.SpriteNumberTextBox = new System.Windows.Forms.TextBox();
this.OpenButton = new System.Windows.Forms.Button();
this.AddPictureButton = new System.Windows.Forms.Button();
this.LabelPic = new System.Windows.Forms.Label();
this.LabelTime = new System.Windows.Forms.Label();
this.LabelDef2 = new System.Windows.Forms.Label();
@ -67,122 +78,274 @@ namespace WindowsFormsApplication1
this.ButtonAddChar = new System.Windows.Forms.Button();
this.saveFileDialog1 = new System.Windows.Forms.SaveFileDialog();
this.openFileDialog1 = new System.Windows.Forms.OpenFileDialog();
this.leftPanel.SuspendLayout();
this.textBox1 = new System.Windows.Forms.TextBox();
this.panel1.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.PictureBoxBackground)).BeginInit();
this.rightPanel.SuspendLayout();
this.personPanel.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.SpriteNumberTextBox)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.openSpace)).BeginInit();
this.panel2.SuspendLayout();
this.panel3.SuspendLayout();
this.SuspendLayout();
//
// LabelData
//
this.LabelData.AutoSize = true;
this.LabelData.Font = new System.Drawing.Font("Arial Black", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(204)));
this.LabelData.Location = new System.Drawing.Point(3, 3);
this.LabelData.Location = new System.Drawing.Point(0, 9);
this.LabelData.Name = "LabelData";
this.LabelData.Size = new System.Drawing.Size(234, 23);
this.LabelData.Size = new System.Drawing.Size(224, 23);
this.LabelData.TabIndex = 0;
this.LabelData.Text = "Данные о мультфильме:";
this.LabelData.Text = "Данные о мултфильме:";
this.LabelData.Click += new System.EventHandler(this.label1_Click);
//
// LabelLengh
//
this.LabelLengh.AutoSize = true;
this.LabelLengh.Location = new System.Drawing.Point(4, 32);
this.LabelLengh.Location = new System.Drawing.Point(14, 60);
this.LabelLengh.Name = "LabelLengh";
this.LabelLengh.Size = new System.Drawing.Size(130, 13);
this.LabelLengh.Size = new System.Drawing.Size(136, 13);
this.LabelLengh.TabIndex = 1;
this.LabelLengh.Text = "Длительность: 0 секунд";
this.LabelLengh.Text = "Длительность: 35 секунд";
//
// LabelName
//
this.LabelName.AutoSize = true;
this.LabelName.Location = new System.Drawing.Point(4, 58);
this.LabelName.Location = new System.Drawing.Point(14, 86);
this.LabelName.Name = "LabelName";
this.LabelName.Size = new System.Drawing.Size(60, 13);
this.LabelName.TabIndex = 2;
this.LabelName.Text = "Название:";
this.LabelName.Click += new System.EventHandler(this.label3_Click);
//
// nazvanieTextBox
//
this.nazvanieTextBox.Location = new System.Drawing.Point(86, 55);
this.nazvanieTextBox.Location = new System.Drawing.Point(80, 86);
this.nazvanieTextBox.Name = "nazvanieTextBox";
this.nazvanieTextBox.Size = new System.Drawing.Size(138, 20);
this.nazvanieTextBox.TabIndex = 3;
//
// leftPanel
// panel1
//
this.leftPanel.Controls.Add(this.button1);
this.leftPanel.Controls.Add(this.checkBox1);
this.leftPanel.Controls.Add(this.Char_Stats);
this.leftPanel.Controls.Add(this.Char_Info);
this.leftPanel.Controls.Add(this.PictureBoxBackground);
this.leftPanel.Controls.Add(this.LabelBackground);
this.leftPanel.Controls.Add(this.dobavitFonButton);
this.leftPanel.Controls.Add(this.LabelData);
this.leftPanel.Controls.Add(this.nazvanieTextBox);
this.leftPanel.Controls.Add(this.LabelLengh);
this.leftPanel.Controls.Add(this.LabelName);
this.leftPanel.Dock = System.Windows.Forms.DockStyle.Left;
this.leftPanel.Location = new System.Drawing.Point(0, 0);
this.leftPanel.Name = "leftPanel";
this.leftPanel.Size = new System.Drawing.Size(297, 380);
this.leftPanel.TabIndex = 4;
this.panel1.Controls.Add(this.label13);
this.panel1.Controls.Add(this.label12);
this.panel1.Controls.Add(this.label11);
this.panel1.Controls.Add(this.label10);
this.panel1.Controls.Add(this.label9);
this.panel1.Controls.Add(this.label8);
this.panel1.Controls.Add(this.label7);
this.panel1.Controls.Add(this.label6);
this.panel1.Controls.Add(this.label4);
this.panel1.Controls.Add(this.label5);
this.panel1.Controls.Add(this.label3);
this.panel1.Controls.Add(this.label2);
this.panel1.Controls.Add(this.button4);
this.panel1.Controls.Add(this.button3);
this.panel1.Controls.Add(this.button2);
this.panel1.Controls.Add(this.label1);
this.panel1.Controls.Add(this.button6);
this.panel1.Controls.Add(this.button5);
this.panel1.Controls.Add(this.button1);
this.panel1.Controls.Add(this.PictureBoxBackground);
this.panel1.Controls.Add(this.LabelBackground);
this.panel1.Controls.Add(this.dobavitFonButton);
this.panel1.Controls.Add(this.LabelData);
this.panel1.Controls.Add(this.nazvanieTextBox);
this.panel1.Controls.Add(this.LabelLengh);
this.panel1.Controls.Add(this.LabelName);
this.panel1.Dock = System.Windows.Forms.DockStyle.Left;
this.panel1.Location = new System.Drawing.Point(0, 0);
this.panel1.Name = "panel1";
this.panel1.Size = new System.Drawing.Size(282, 527);
this.panel1.TabIndex = 4;
//
// label13
//
this.label13.AutoSize = true;
this.label13.Location = new System.Drawing.Point(44, 232);
this.label13.Name = "label13";
this.label13.Size = new System.Drawing.Size(180, 13);
this.label13.TabIndex = 23;
this.label13.Text = "ИНФОРМАЦИЯ О ПЕРСОНАЖАХ";
//
// label12
//
this.label12.AutoSize = true;
this.label12.Location = new System.Drawing.Point(143, 308);
this.label12.Name = "label12";
this.label12.Size = new System.Drawing.Size(39, 13);
this.label12.TabIndex = 22;
this.label12.Text = "номер";
//
// label11
//
this.label11.AutoSize = true;
this.label11.Location = new System.Drawing.Point(79, 308);
this.label11.Name = "label11";
this.label11.Size = new System.Drawing.Size(39, 13);
this.label11.TabIndex = 22;
this.label11.Text = "время";
//
// label10
//
this.label10.AutoSize = true;
this.label10.Location = new System.Drawing.Point(9, 308);
this.label10.Name = "label10";
this.label10.Size = new System.Drawing.Size(27, 13);
this.label10.TabIndex = 22;
this.label10.Text = "имя";
//
// label9
//
this.label9.AutoSize = true;
this.label9.Location = new System.Drawing.Point(143, 324);
this.label9.Name = "label9";
this.label9.Size = new System.Drawing.Size(13, 13);
this.label9.TabIndex = 21;
this.label9.Text = "1";
this.label9.Click += new System.EventHandler(this.label7_Click);
//
// label8
//
this.label8.AutoSize = true;
this.label8.Location = new System.Drawing.Point(143, 342);
this.label8.Name = "label8";
this.label8.Size = new System.Drawing.Size(13, 13);
this.label8.TabIndex = 21;
this.label8.Text = "2";
this.label8.Click += new System.EventHandler(this.label7_Click);
//
// label7
//
this.label7.AutoSize = true;
this.label7.Location = new System.Drawing.Point(143, 359);
this.label7.Name = "label7";
this.label7.Size = new System.Drawing.Size(13, 13);
this.label7.TabIndex = 21;
this.label7.Text = "3";
this.label7.Click += new System.EventHandler(this.label7_Click);
//
// label6
//
this.label6.AutoSize = true;
this.label6.Location = new System.Drawing.Point(61, 359);
this.label6.Name = "label6";
this.label6.Size = new System.Drawing.Size(80, 13);
this.label6.TabIndex = 21;
this.label6.Text = "(2-12 секунды)";
//
// label4
//
this.label4.AutoSize = true;
this.label4.Location = new System.Drawing.Point(58, 342);
this.label4.Name = "label4";
this.label4.Size = new System.Drawing.Size(80, 13);
this.label4.TabIndex = 21;
this.label4.Text = "(2-12 секунды)";
//
// label5
//
this.label5.AutoSize = true;
this.label5.Location = new System.Drawing.Point(6, 361);
this.label5.Name = "label5";
this.label5.Size = new System.Drawing.Size(49, 13);
this.label5.TabIndex = 18;
this.label5.Text = "Котенок";
this.label5.Click += new System.EventHandler(this.label1_Click_1);
//
// label3
//
this.label3.AutoSize = true;
this.label3.Location = new System.Drawing.Point(58, 324);
this.label3.Name = "label3";
this.label3.Size = new System.Drawing.Size(80, 13);
this.label3.TabIndex = 21;
this.label3.Text = "(2-12 секунды)";
//
// label2
//
this.label2.AutoSize = true;
this.label2.Location = new System.Drawing.Point(6, 342);
this.label2.Name = "label2";
this.label2.Size = new System.Drawing.Size(49, 13);
this.label2.TabIndex = 18;
this.label2.Text = "Котенок";
this.label2.Click += new System.EventHandler(this.label1_Click_1);
//
// button4
//
this.button4.Location = new System.Drawing.Point(188, 356);
this.button4.Name = "button4";
this.button4.Size = new System.Drawing.Size(26, 18);
this.button4.TabIndex = 19;
this.button4.Text = "X";
this.button4.UseVisualStyleBackColor = true;
//
// button3
//
this.button3.Location = new System.Drawing.Point(188, 339);
this.button3.Name = "button3";
this.button3.Size = new System.Drawing.Size(26, 18);
this.button3.TabIndex = 19;
this.button3.Text = "X";
this.button3.UseVisualStyleBackColor = true;
//
// button2
//
this.button2.Location = new System.Drawing.Point(188, 320);
this.button2.Name = "button2";
this.button2.Size = new System.Drawing.Size(26, 17);
this.button2.TabIndex = 19;
this.button2.Text = "X";
this.button2.UseVisualStyleBackColor = true;
this.button2.Click += new System.EventHandler(this.button2_Click);
//
// label1
//
this.label1.AutoSize = true;
this.label1.Location = new System.Drawing.Point(6, 324);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(49, 13);
this.label1.TabIndex = 18;
this.label1.Text = "Котенок";
this.label1.Click += new System.EventHandler(this.label1_Click_1);
//
// button6
//
this.button6.Location = new System.Drawing.Point(259, 356);
this.button6.Name = "button6";
this.button6.Size = new System.Drawing.Size(26, 18);
this.button6.TabIndex = 17;
this.button6.Text = "Р";
this.button6.UseVisualStyleBackColor = true;
//
// button5
//
this.button5.Location = new System.Drawing.Point(259, 339);
this.button5.Name = "button5";
this.button5.Size = new System.Drawing.Size(26, 18);
this.button5.TabIndex = 17;
this.button5.Text = "Р";
this.button5.UseVisualStyleBackColor = true;
//
// button1
//
this.button1.Dock = System.Windows.Forms.DockStyle.Bottom;
this.button1.Location = new System.Drawing.Point(0, 350);
this.button1.Location = new System.Drawing.Point(259, 321);
this.button1.Name = "button1";
this.button1.Size = new System.Drawing.Size(297, 30);
this.button1.TabIndex = 26;
this.button1.Text = "Компилировать";
this.button1.Size = new System.Drawing.Size(26, 18);
this.button1.TabIndex = 17;
this.button1.Text = "Р";
this.button1.UseVisualStyleBackColor = true;
this.button1.Click += new System.EventHandler(this.button1_Click);
//
// checkBox1
//
this.checkBox1.AutoSize = true;
this.checkBox1.Location = new System.Drawing.Point(7, 193);
this.checkBox1.Name = "checkBox1";
this.checkBox1.Size = new System.Drawing.Size(245, 17);
this.checkBox1.TabIndex = 25;
this.checkBox1.Text = "Автозакрытие мультфильма по окончанию";
this.checkBox1.UseVisualStyleBackColor = true;
//
// Char_Stats
//
this.Char_Stats.AutoSize = true;
this.Char_Stats.Location = new System.Drawing.Point(12, 240);
this.Char_Stats.Name = "Char_Stats";
this.Char_Stats.Size = new System.Drawing.Size(259, 13);
this.Char_Stats.TabIndex = 24;
this.Char_Stats.Text = "number name state view delete";
//
// Char_Info
//
this.Char_Info.AutoSize = true;
this.Char_Info.Location = new System.Drawing.Point(44, 226);
this.Char_Info.Name = "Char_Info";
this.Char_Info.Size = new System.Drawing.Size(180, 13);
this.Char_Info.TabIndex = 23;
this.Char_Info.Text = "ИНФОРМАЦИЯ О ПЕРСОНАЖАХ";
this.Char_Info.Click += new System.EventHandler(this.Char_Info_Click);
//
// PictureBoxBackground
//
this.PictureBoxBackground.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
this.PictureBoxBackground.Location = new System.Drawing.Point(84, 111);
this.PictureBoxBackground.Location = new System.Drawing.Point(17, 160);
this.PictureBoxBackground.Name = "PictureBoxBackground";
this.PictureBoxBackground.Size = new System.Drawing.Size(117, 72);
this.PictureBoxBackground.SizeMode = System.Windows.Forms.PictureBoxSizeMode.Zoom;
this.PictureBoxBackground.Size = new System.Drawing.Size(245, 55);
this.PictureBoxBackground.TabIndex = 12;
this.PictureBoxBackground.TabStop = false;
//
// LabelBackground
//
this.LabelBackground.AutoSize = true;
this.LabelBackground.Location = new System.Drawing.Point(4, 87);
this.LabelBackground.Location = new System.Drawing.Point(14, 114);
this.LabelBackground.Name = "LabelBackground";
this.LabelBackground.Size = new System.Drawing.Size(77, 13);
this.LabelBackground.TabIndex = 11;
@ -190,150 +353,111 @@ namespace WindowsFormsApplication1
//
// dobavitFonButton
//
this.dobavitFonButton.Location = new System.Drawing.Point(85, 81);
this.dobavitFonButton.Location = new System.Drawing.Point(17, 130);
this.dobavitFonButton.Name = "dobavitFonButton";
this.dobavitFonButton.Size = new System.Drawing.Size(116, 24);
this.dobavitFonButton.TabIndex = 10;
this.dobavitFonButton.Text = "Добавить";
this.dobavitFonButton.UseVisualStyleBackColor = true;
this.dobavitFonButton.Click += new System.EventHandler(this.AddBackArtClick);
this.dobavitFonButton.Click += new System.EventHandler(this.button6_Click);
//
// splitter1
//
this.splitter1.Location = new System.Drawing.Point(297, 0);
this.splitter1.Location = new System.Drawing.Point(282, 0);
this.splitter1.Name = "splitter1";
this.splitter1.Size = new System.Drawing.Size(3, 380);
this.splitter1.Size = new System.Drawing.Size(3, 527);
this.splitter1.TabIndex = 5;
this.splitter1.TabStop = false;
//
// rightPanel
// panel2
//
this.rightPanel.Controls.Add(this.SaveCharButton);
this.rightPanel.Controls.Add(this.personPanel);
this.rightPanel.Controls.Add(this.SaveMultButton);
this.rightPanel.Controls.Add(this.ButtonAddChar);
this.rightPanel.Dock = System.Windows.Forms.DockStyle.Fill;
this.rightPanel.Location = new System.Drawing.Point(300, 0);
this.rightPanel.Name = "rightPanel";
this.rightPanel.Size = new System.Drawing.Size(377, 380);
this.rightPanel.TabIndex = 6;
this.panel2.Controls.Add(this.SaveCharButton);
this.panel2.Controls.Add(this.panel3);
this.panel2.Controls.Add(this.SaveMultButton);
this.panel2.Controls.Add(this.ButtonAddChar);
this.panel2.Dock = System.Windows.Forms.DockStyle.Fill;
this.panel2.Location = new System.Drawing.Point(285, 0);
this.panel2.Name = "panel2";
this.panel2.Size = new System.Drawing.Size(392, 527);
this.panel2.TabIndex = 6;
//
// SaveCharButton
//
this.SaveCharButton.Dock = System.Windows.Forms.DockStyle.Bottom;
this.SaveCharButton.Location = new System.Drawing.Point(0, 320);
this.SaveCharButton.Location = new System.Drawing.Point(0, 467);
this.SaveCharButton.Name = "SaveCharButton";
this.SaveCharButton.Size = new System.Drawing.Size(377, 30);
this.SaveCharButton.Size = new System.Drawing.Size(392, 30);
this.SaveCharButton.TabIndex = 3;
this.SaveCharButton.Text = "Сохранить персонажа";
this.SaveCharButton.UseVisualStyleBackColor = true;
this.SaveCharButton.Click += new System.EventHandler(this.SaveCharButtonClick);
//
// personPanel
// panel3
//
this.personPanel.Controls.Add(this.SpriteNumberTextBox);
this.personPanel.Controls.Add(this.charNameBox);
this.personPanel.Controls.Add(this.circlesTextBox);
this.personPanel.Controls.Add(this.circlesLabel);
this.personPanel.Controls.Add(this.charNameLabel);
this.personPanel.Controls.Add(this.openSpace);
this.personPanel.Controls.Add(this.SpriteNumberLabel);
this.personPanel.Controls.Add(this.OpenButton);
this.personPanel.Controls.Add(this.LabelPic);
this.personPanel.Controls.Add(this.LabelTime);
this.personPanel.Controls.Add(this.LabelDef2);
this.personPanel.Controls.Add(this.LabelDef1);
this.personPanel.Controls.Add(this.LabelWalls);
this.personPanel.Controls.Add(this.TextBoxTime1);
this.personPanel.Controls.Add(this.TextBoxTime2);
this.personPanel.Controls.Add(this.TextBoxWall2);
this.personPanel.Controls.Add(this.TextBoxWall1);
this.personPanel.Controls.Add(this.ComboBoxMove);
this.personPanel.Controls.Add(this.LabelMoveType);
this.personPanel.Dock = System.Windows.Forms.DockStyle.Fill;
this.personPanel.Location = new System.Drawing.Point(0, 26);
this.personPanel.Name = "personPanel";
this.personPanel.Size = new System.Drawing.Size(377, 324);
this.personPanel.TabIndex = 2;
this.personPanel.Visible = false;
//
// SpriteNumberTextBox
//
this.SpriteNumberTextBox.Location = new System.Drawing.Point(128, 136);
this.SpriteNumberTextBox.Name = "SpriteNumberTextBox";
this.SpriteNumberTextBox.Size = new System.Drawing.Size(43, 20);
this.SpriteNumberTextBox.TabIndex = 22;
this.SpriteNumberTextBox.Value = new decimal(new int[] {
1,
0,
0,
0});
//
// charNameBox
//
this.charNameBox.Location = new System.Drawing.Point(115, 84);
this.charNameBox.Name = "charNameBox";
this.charNameBox.Size = new System.Drawing.Size(138, 20);
this.charNameBox.TabIndex = 19;
//
// circlesTextBox
//
this.circlesTextBox.Location = new System.Drawing.Point(115, 110);
this.circlesTextBox.Name = "circlesTextBox";
this.circlesTextBox.Size = new System.Drawing.Size(138, 20);
this.circlesTextBox.TabIndex = 21;
//
// circlesLabel
//
this.circlesLabel.AutoSize = true;
this.circlesLabel.Location = new System.Drawing.Point(3, 113);
this.circlesLabel.Name = "circlesLabel";
this.circlesLabel.Size = new System.Drawing.Size(81, 13);
this.circlesLabel.TabIndex = 20;
this.circlesLabel.Text = "Кол-во кругов:";
//
// charNameLabel
//
this.charNameLabel.AutoSize = true;
this.charNameLabel.Location = new System.Drawing.Point(3, 87);
this.charNameLabel.Name = "charNameLabel";
this.charNameLabel.Size = new System.Drawing.Size(60, 13);
this.charNameLabel.TabIndex = 18;
this.charNameLabel.Text = "Название:";
//
// openSpace
//
this.openSpace.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
this.openSpace.Location = new System.Drawing.Point(72, 203);
this.openSpace.Name = "openSpace";
this.openSpace.Size = new System.Drawing.Size(192, 72);
this.openSpace.SizeMode = System.Windows.Forms.PictureBoxSizeMode.Zoom;
this.openSpace.TabIndex = 17;
this.openSpace.TabStop = false;
this.panel3.Controls.Add(this.textBox1);
this.panel3.Controls.Add(this.SpriteNumberLabel);
this.panel3.Controls.Add(this.SpriteNumberTextBox);
this.panel3.Controls.Add(this.OpenButton);
this.panel3.Controls.Add(this.AddPictureButton);
this.panel3.Controls.Add(this.LabelPic);
this.panel3.Controls.Add(this.LabelTime);
this.panel3.Controls.Add(this.LabelDef2);
this.panel3.Controls.Add(this.LabelDef1);
this.panel3.Controls.Add(this.LabelWalls);
this.panel3.Controls.Add(this.TextBoxTime1);
this.panel3.Controls.Add(this.TextBoxTime2);
this.panel3.Controls.Add(this.TextBoxWall2);
this.panel3.Controls.Add(this.TextBoxWall1);
this.panel3.Controls.Add(this.ComboBoxMove);
this.panel3.Controls.Add(this.LabelMoveType);
this.panel3.Dock = System.Windows.Forms.DockStyle.Fill;
this.panel3.Location = new System.Drawing.Point(0, 26);
this.panel3.Name = "panel3";
this.panel3.Size = new System.Drawing.Size(392, 471);
this.panel3.TabIndex = 2;
this.panel3.Visible = false;
//
// SpriteNumberLabel
//
this.SpriteNumberLabel.AutoSize = true;
this.SpriteNumberLabel.Location = new System.Drawing.Point(3, 139);
this.SpriteNumberLabel.Location = new System.Drawing.Point(7, 153);
this.SpriteNumberLabel.Name = "SpriteNumberLabel";
this.SpriteNumberLabel.Size = new System.Drawing.Size(119, 13);
this.SpriteNumberLabel.TabIndex = 16;
this.SpriteNumberLabel.Text = "Количество спрайтов:";
this.SpriteNumberLabel.Click += new System.EventHandler(this.label13_Click_1);
//
// SpriteNumberTextBox
//
this.SpriteNumberTextBox.Location = new System.Drawing.Point(10, 169);
this.SpriteNumberTextBox.Name = "SpriteNumberTextBox";
this.SpriteNumberTextBox.Size = new System.Drawing.Size(83, 20);
this.SpriteNumberTextBox.TabIndex = 15;
//
// OpenButton
//
this.OpenButton.Location = new System.Drawing.Point(72, 167);
this.OpenButton.Location = new System.Drawing.Point(225, 153);
this.OpenButton.Name = "OpenButton";
this.OpenButton.Size = new System.Drawing.Size(192, 30);
this.OpenButton.Size = new System.Drawing.Size(171, 30);
this.OpenButton.TabIndex = 14;
this.OpenButton.Text = "Открыть персонажа";
this.OpenButton.UseVisualStyleBackColor = true;
this.OpenButton.Click += new System.EventHandler(this.OpenAddCharClick);
this.OpenButton.Click += new System.EventHandler(this.button5_Click);
//
// AddPictureButton
//
this.AddPictureButton.Location = new System.Drawing.Point(132, 169);
this.AddPictureButton.Name = "AddPictureButton";
this.AddPictureButton.Size = new System.Drawing.Size(65, 20);
this.AddPictureButton.TabIndex = 13;
this.AddPictureButton.Text = "Добавить";
this.AddPictureButton.UseVisualStyleBackColor = true;
this.AddPictureButton.Click += new System.EventHandler(this.button4_Click);
//
// LabelPic
//
this.LabelPic.AutoSize = true;
this.LabelPic.Location = new System.Drawing.Point(3, 174);
this.LabelPic.Location = new System.Drawing.Point(129, 153);
this.LabelPic.Name = "LabelPic";
this.LabelPic.Size = new System.Drawing.Size(58, 13);
this.LabelPic.TabIndex = 12;
@ -342,7 +466,7 @@ namespace WindowsFormsApplication1
// LabelTime
//
this.LabelTime.AutoSize = true;
this.LabelTime.Location = new System.Drawing.Point(3, 61);
this.LabelTime.Location = new System.Drawing.Point(19, 91);
this.LabelTime.Name = "LabelTime";
this.LabelTime.Size = new System.Drawing.Size(54, 13);
this.LabelTime.TabIndex = 11;
@ -351,79 +475,82 @@ namespace WindowsFormsApplication1
// LabelDef2
//
this.LabelDef2.AutoSize = true;
this.LabelDef2.Location = new System.Drawing.Point(223, 61);
this.LabelDef2.Location = new System.Drawing.Point(240, 91);
this.LabelDef2.Name = "LabelDef2";
this.LabelDef2.Size = new System.Drawing.Size(13, 13);
this.LabelDef2.TabIndex = 10;
this.LabelDef2.Text = "--";
this.LabelDef2.Click += new System.EventHandler(this.label10_Click);
//
// LabelDef1
//
this.LabelDef1.AutoSize = true;
this.LabelDef1.Location = new System.Drawing.Point(223, 36);
this.LabelDef1.Location = new System.Drawing.Point(240, 62);
this.LabelDef1.Name = "LabelDef1";
this.LabelDef1.Size = new System.Drawing.Size(13, 13);
this.LabelDef1.TabIndex = 9;
this.LabelDef1.Text = "--";
this.LabelDef1.Click += new System.EventHandler(this.label9_Click);
//
// LabelWalls
//
this.LabelWalls.AutoSize = true;
this.LabelWalls.Location = new System.Drawing.Point(3, 36);
this.LabelWalls.Location = new System.Drawing.Point(19, 62);
this.LabelWalls.Name = "LabelWalls";
this.LabelWalls.Size = new System.Drawing.Size(107, 13);
this.LabelWalls.TabIndex = 8;
this.LabelWalls.Text = "Границы движения:";
this.LabelWalls.Click += new System.EventHandler(this.label8_Click);
//
// TextBoxTime1
//
this.TextBoxTime1.Location = new System.Drawing.Point(116, 59);
this.TextBoxTime1.Location = new System.Drawing.Point(132, 88);
this.TextBoxTime1.Name = "TextBoxTime1";
this.TextBoxTime1.Size = new System.Drawing.Size(100, 20);
this.TextBoxTime1.TabIndex = 5;
//
// TextBoxTime2
//
this.TextBoxTime2.Location = new System.Drawing.Point(243, 59);
this.TextBoxTime2.Location = new System.Drawing.Point(259, 88);
this.TextBoxTime2.Name = "TextBoxTime2";
this.TextBoxTime2.Size = new System.Drawing.Size(100, 20);
this.TextBoxTime2.TabIndex = 4;
this.TextBoxTime2.TextChanged += new System.EventHandler(this.textBox6_TextChanged);
//
// TextBoxWall2
//
this.TextBoxWall2.Location = new System.Drawing.Point(243, 33);
this.TextBoxWall2.Location = new System.Drawing.Point(259, 59);
this.TextBoxWall2.Name = "TextBoxWall2";
this.TextBoxWall2.Size = new System.Drawing.Size(100, 20);
this.TextBoxWall2.TabIndex = 3;
this.TextBoxWall2.KeyPress += new System.Windows.Forms.KeyPressEventHandler(this.TextBoxWall1_KeyPress);
this.TextBoxWall2.TextChanged += new System.EventHandler(this.TextBoxWall2_TextChanged);
//
// TextBoxWall1
//
this.TextBoxWall1.Location = new System.Drawing.Point(116, 33);
this.TextBoxWall1.Location = new System.Drawing.Point(132, 59);
this.TextBoxWall1.Name = "TextBoxWall1";
this.TextBoxWall1.Size = new System.Drawing.Size(100, 20);
this.TextBoxWall1.TabIndex = 2;
this.TextBoxWall1.KeyPress += new System.Windows.Forms.KeyPressEventHandler(this.TextBoxWall1_KeyPress);
this.TextBoxWall1.TextChanged += new System.EventHandler(this.TextBoxWall1_TextChanged);
//
// ComboBoxMove
//
this.ComboBoxMove.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
this.ComboBoxMove.FormattingEnabled = true;
this.ComboBoxMove.Items.AddRange(new object[] {
"Прямо",
"Диагонально",
"По диагонали",
"Волнами",
"Кругами"});
this.ComboBoxMove.Location = new System.Drawing.Point(115, 3);
this.ComboBoxMove.Location = new System.Drawing.Point(107, 12);
this.ComboBoxMove.Name = "ComboBoxMove";
this.ComboBoxMove.Size = new System.Drawing.Size(121, 21);
this.ComboBoxMove.TabIndex = 1;
this.ComboBoxMove.SelectedIndexChanged += new System.EventHandler(this.ComboBoxMove_SelectedIndexChanged);
this.ComboBoxMove.Text = "Прямо";
//
// LabelMoveType
//
this.LabelMoveType.AutoSize = true;
this.LabelMoveType.Location = new System.Drawing.Point(3, 6);
this.LabelMoveType.Location = new System.Drawing.Point(19, 12);
this.LabelMoveType.Name = "LabelMoveType";
this.LabelMoveType.Size = new System.Drawing.Size(82, 13);
this.LabelMoveType.TabIndex = 0;
@ -432,49 +559,54 @@ namespace WindowsFormsApplication1
// SaveMultButton
//
this.SaveMultButton.Dock = System.Windows.Forms.DockStyle.Bottom;
this.SaveMultButton.Location = new System.Drawing.Point(0, 350);
this.SaveMultButton.Location = new System.Drawing.Point(0, 497);
this.SaveMultButton.Name = "SaveMultButton";
this.SaveMultButton.Size = new System.Drawing.Size(377, 30);
this.SaveMultButton.Size = new System.Drawing.Size(392, 30);
this.SaveMultButton.TabIndex = 1;
this.SaveMultButton.Text = "Сохранить мульт";
this.SaveMultButton.UseVisualStyleBackColor = true;
this.SaveMultButton.Click += new System.EventHandler(this.SaveMultButton_Click);
//
// ButtonAddChar
//
this.ButtonAddChar.Dock = System.Windows.Forms.DockStyle.Top;
this.ButtonAddChar.Location = new System.Drawing.Point(0, 0);
this.ButtonAddChar.Name = "ButtonAddChar";
this.ButtonAddChar.Size = new System.Drawing.Size(377, 26);
this.ButtonAddChar.Size = new System.Drawing.Size(392, 26);
this.ButtonAddChar.TabIndex = 0;
this.ButtonAddChar.Text = "Добавить персонажа";
this.ButtonAddChar.UseVisualStyleBackColor = true;
this.ButtonAddChar.Click += new System.EventHandler(this.buttonAddCharClick);
this.ButtonAddChar.Click += new System.EventHandler(this.button1_Click);
//
// openFileDialog1
//
this.openFileDialog1.FileName = "openFileDialog1";
//
// textBox1
//
this.textBox1.Location = new System.Drawing.Point(132, 114);
this.textBox1.Name = "textBox1";
this.textBox1.Size = new System.Drawing.Size(235, 20);
this.textBox1.TabIndex = 17;
this.textBox1.Text = "Здесь должна быть кнопка амплитуды X Y !!!";
//
// MainForm
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(677, 380);
this.Controls.Add(this.rightPanel);
this.ClientSize = new System.Drawing.Size(677, 527);
this.Controls.Add(this.panel2);
this.Controls.Add(this.splitter1);
this.Controls.Add(this.leftPanel);
this.Controls.Add(this.panel1);
this.Name = "MainForm";
this.RightToLeftLayout = true;
this.Text = "Свойства персонажа";
this.Load += new System.EventHandler(this.MainForm_Load);
this.leftPanel.ResumeLayout(false);
this.leftPanel.PerformLayout();
this.Load += new System.EventHandler(this.Form1_Load);
this.panel1.ResumeLayout(false);
this.panel1.PerformLayout();
((System.ComponentModel.ISupportInitialize)(this.PictureBoxBackground)).EndInit();
this.rightPanel.ResumeLayout(false);
this.personPanel.ResumeLayout(false);
this.personPanel.PerformLayout();
((System.ComponentModel.ISupportInitialize)(this.SpriteNumberTextBox)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.openSpace)).EndInit();
this.panel2.ResumeLayout(false);
this.panel3.ResumeLayout(false);
this.panel3.PerformLayout();
this.ResumeLayout(false);
}
@ -485,12 +617,12 @@ namespace WindowsFormsApplication1
private System.Windows.Forms.Label LabelLengh;
private System.Windows.Forms.Label LabelName;
private System.Windows.Forms.TextBox nazvanieTextBox;
private System.Windows.Forms.Panel leftPanel;
private System.Windows.Forms.Panel panel1;
private System.Windows.Forms.Splitter splitter1;
private System.Windows.Forms.Panel rightPanel;
private System.Windows.Forms.Panel panel2;
private System.Windows.Forms.Button SaveMultButton;
private System.Windows.Forms.Button ButtonAddChar;
private System.Windows.Forms.Panel personPanel;
private System.Windows.Forms.Panel panel3;
private System.Windows.Forms.Label LabelMoveType;
private System.Windows.Forms.TextBox TextBoxTime1;
private System.Windows.Forms.TextBox TextBoxTime2;
@ -502,23 +634,36 @@ namespace WindowsFormsApplication1
private System.Windows.Forms.Label LabelTime;
private System.Windows.Forms.Label LabelDef2;
private System.Windows.Forms.Button SaveCharButton;
private System.Windows.Forms.Button AddPictureButton;
private System.Windows.Forms.Label LabelPic;
private System.Windows.Forms.SaveFileDialog saveFileDialog1;
private System.Windows.Forms.Button OpenButton;
private System.Windows.Forms.OpenFileDialog openFileDialog1;
private System.Windows.Forms.Label SpriteNumberLabel;
private System.Windows.Forms.TextBox SpriteNumberTextBox;
private System.Windows.Forms.Label LabelBackground;
private System.Windows.Forms.Button dobavitFonButton;
private System.Windows.Forms.PictureBox PictureBoxBackground;
private System.Windows.Forms.Label Char_Info;
private System.Windows.Forms.PictureBox openSpace;
private System.Windows.Forms.Label Char_Stats;
private System.Windows.Forms.TextBox charNameBox;
private System.Windows.Forms.Label charNameLabel;
private System.Windows.Forms.TextBox circlesTextBox;
private System.Windows.Forms.Label circlesLabel;
private System.Windows.Forms.NumericUpDown SpriteNumberTextBox;
private System.Windows.Forms.Button button2;
private System.Windows.Forms.Button button1;
private System.Windows.Forms.CheckBox checkBox1;
private System.Windows.Forms.Label label3;
private System.Windows.Forms.Label label1;
private System.Windows.Forms.Label label7;
private System.Windows.Forms.Label label6;
private System.Windows.Forms.Label label4;
private System.Windows.Forms.Label label5;
private System.Windows.Forms.Label label2;
private System.Windows.Forms.Label label12;
private System.Windows.Forms.Label label11;
private System.Windows.Forms.Label label10;
private System.Windows.Forms.Label label9;
private System.Windows.Forms.Label label8;
private System.Windows.Forms.Label label13;
private System.Windows.Forms.Button button4;
private System.Windows.Forms.Button button3;
private System.Windows.Forms.Button button6;
private System.Windows.Forms.Button button5;
private System.Windows.Forms.TextBox textBox1;
}
}
}

View file

@ -1,419 +1,424 @@
using System;
using System.IO;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.IO;
using System.Linq;
using System.Text;
using System.Windows.Forms;
namespace WindowsFormsApplication1
{
public struct Personazh
{
public string ce_nibud;
public string nazvanie_personazha;
}
public partial class MainForm : Form
{
Person[] persons = new Person[8];
int yPersa = 263;
int yPersa = 300;
int nomerPersa = 0;
int pNomer = 0;
int maxTime = 0;
//PictureBox[] pic1 = new PictureBox[1000];
String addressBackground = "";
string mainFilename = "";
public Label[] l1 = new Label[100];
public Label[] l2 = new Label[100];
public Label[] l3 = new Label[100];
public Button[] b1 = new Button[100];
public Button[] b2 = new Button[100];
PictureBox[] pic1 = new PictureBox[1000];
public MainForm()
{
InitializeComponent();
ComboBoxMove.SelectedIndex = 0;
openFileDialog1.Filter = "Bitmap Pictures|*.bmp";
saveFileDialog1.Filter = "C++ Code Files|*.cpp";
openFileDialog1.Filter = "Kartinki|*.bmp";
saveFileDialog1.Filter = "cpp files|*.cpp";
}
private void buttonAddCharClick(object sender, EventArgs e)
private void Form1_Load(object sender, EventArgs e)
{
personPanel.Visible = true;
pNomer = -120;
}
private void DeletePics(string filename, int nomer)
{
File.AppendAllText(filename, Environment.NewLine);
for (int n1 = 0; n1 < nomer; n1++)
{
File.AppendAllText(filename, " txDeleteDC(" + Person.PersonName(n1) + ".texture);" + Environment.NewLine);
}
}
private void SaveCharButtonClick(object sender, EventArgs e)
{
if (personPanel.Visible == false)
{
MessageBox.Show("Где параметры? Покажи мне, ткни меня в них!");
return;
}
personPanel.Visible = true;
if (pNomer == -120)
{
persons[nomerPersa] = AddRowToPersList(persons[nomerPersa], false);
nomerPersa++;
yPersa += 30;
openSpace.Image = null;
}
else
{
persons[pNomer] = AddRowToPersList(persons[pNomer], true);
}
for (int nomer = 0; nomer < nomerPersa; nomer++)
{
if (Convert.ToInt32(persons[nomer].time2) > maxTime)
/*int i=0;
for (; i < 10; i++)
{
maxTime = Convert.ToInt32(persons[nomer].time2);
}
}
LabelLengh.Text = "Длительность: " + maxTime.ToString() + " секунд";
PictureBox pic2 = new PictureBox();
pic2.Location = new Point(pic2.Location.X + (i*100), pic2.Location.Y);
pic2.BorderStyle = BorderStyle.FixedSingle;
pic1[i] = pic2;
Controls.Add(pic1[i]);
}*/
}
private Person AddRowToPersList(Person p, bool use_pnumber = false)
private void label1_Click(object sender, EventArgs e)
{
if (!use_pnumber)
{
p.l1 = new Label();
p.l1.Top = yPersa;
p.l1.Left = 30;
p.l1.Width = 20;
p.l1.Visible = true;
p.l1.Text = (nomerPersa + 1).ToString();
leftPanel.Controls.Add(p.l1);
p.l2 = new Label();
p.l2.Top = yPersa;
p.l2.Left = 60;
p.l2.Width = 60;
p.l2.Visible = true;
p.l2.Text = "Перс" + (nomerPersa + 1).ToString();
leftPanel.Controls.Add(p.l2);
p.l3 = new Label();
p.l3.Top = yPersa;
p.l3.Left = 120;
p.l3.Width = 40;
p.l3.Visible = true;
p.l3.Text = "saved";
leftPanel.Controls.Add(p.l3);
p.b1 = new Button();
p.b1.Top = yPersa;
p.b1.Left = 170;
p.b1.Width = 50;
p.b1.Visible = true;
p.b1.Text = "Edit";
p.b1.MouseClick +=
new MouseEventHandler(Char_Creator_Button_Click);
leftPanel.Controls.Add(p.b1);
ToolTip tView = new ToolTip();
tView.IsBalloon = true;
tView.InitialDelay = 0;
tView.ShowAlways = true;
tView.AutoPopDelay = 2000;
tView.SetToolTip(p.b1, "View/edit person");
p.b2 = new Button();
p.b2.Top = yPersa;
p.b2.Left = 230;
p.b2.Width = 50;
p.b2.Visible = true;
p.b2.Text = "Del";
p.b2.Click +=
new EventHandler(Char_Info_Click);
leftPanel.Controls.Add(p.b2);
ToolTip tDelete = new ToolTip();
tDelete.IsBalloon = true;
tDelete.InitialDelay = 0;
tDelete.ShowAlways = true;
tDelete.AutoPopDelay = 2000;
tDelete.SetToolTip(p.b2, "Delete this person");
}
p.coord = TextBoxWall1.Text;
p.coord2 = TextBoxWall2.Text;
p.time1 = TextBoxTime1.Text;
p.time2 = TextBoxTime2.Text;
p.sprite = SpriteNumberTextBox.Text;
p.moveside = ComboBoxMove.Text;
p.nomer = (use_pnumber) ? pNomer : nomerPersa;
p.charname = charNameBox.Text;
p.circles = circlesTextBox.Text;
p.l2.Text = charNameBox.Text;
String[] coordinatyNachala = TextBoxWall1.Text.Split(new String[] { "," }, StringSplitOptions.None);
if (coordinatyNachala.Length > 1)
{
p.x1 = coordinatyNachala[0];
p.y1 = coordinatyNachala[1];
}
String[] coordinatyKonza = TextBoxWall2.Text.Split(new String[] { "," }, StringSplitOptions.None);
if (coordinatyKonza.Length > 1)
{
p.x2 = coordinatyKonza[0];
p.y2 = coordinatyKonza[1];
}
return p;
}
private void OpenAddCharClick(object sender, EventArgs e)
private void label3_Click(object sender, EventArgs e)
{
if (openFileDialog1.ShowDialog() == DialogResult.Cancel)
return;
openSpace.Image = Image.FromFile(openFileDialog1.FileName);
if (pNomer == -120)
{
persons[nomerPersa].address = openFileDialog1.FileName;
persons[nomerPersa].width = openSpace.Image.Width.ToString();
persons[nomerPersa].height = openSpace.Image.Height.ToString();
}
else
{
persons[pNomer].address = openFileDialog1.FileName;
persons[pNomer].width = openSpace.Image.Width.ToString();
persons[pNomer].height = openSpace.Image.Height.ToString();
}
}
private void AddBackArtClick(object sender, EventArgs e)
private void textBox3_TextChanged(object sender, EventArgs e)
{
if (openFileDialog1.ShowDialog() == DialogResult.Cancel)
return;
PictureBoxBackground.Image = Image.FromFile(openFileDialog1.FileName);
addressBackground = openFileDialog1.FileName;
}
private void SaveMultButton_Click(object sender, EventArgs e)
{
if (PictureBoxBackground.Image == null)
{
MessageBox.Show("Что ты собрался выводить-то, поехавший (фон)?");
return;
}
for (int nomer = 0; nomer < nomerPersa; nomer++)
{
if (String.IsNullOrEmpty(persons[nomer].address))
{
MessageBox.Show("Картинка №" + (nomer + 1).ToString() + " пустая");
return;
}
if (String.IsNullOrEmpty(persons[nomer].x1))
{
MessageBox.Show("Первая координата персонажа №" + (nomer + 1).ToString() + " пустая");
return;
}
if (String.IsNullOrEmpty(persons[nomer].y1))
{
MessageBox.Show("Первая координата персонажа №" + (nomer + 1).ToString() + " пустая");
return;
}
if (String.IsNullOrEmpty(persons[nomer].y2))
{
MessageBox.Show("Вторая координата персонажа №" + (nomer + 1).ToString() + " пустая");
return;
}
if (String.IsNullOrEmpty(persons[nomer].x2))
{
MessageBox.Show("Вторая координата персонажа №" + (nomer + 1).ToString() + " пустая");
return;
}
if (String.IsNullOrEmpty(persons[nomer].time1))
{
MessageBox.Show("Первая координата времени №" + (nomer + 1).ToString() + " пустая");
return;
}
if (String.IsNullOrEmpty(persons[nomer].time2))
{
MessageBox.Show("Вторая координата времени №" + (nomer + 1).ToString() + " пустая");
return;
}
}
if (saveFileDialog1.ShowDialog() == DialogResult.OK)
{
try
{
mainFilename = saveFileDialog1.FileName;
//Adding TXLibrary and pictures
File.WriteAllText(Path.GetDirectoryName(mainFilename) + "\\TXLib.h", Properties.Resources.TXLib);
string dir_path = Path.GetDirectoryName(mainFilename) + "\\Pictures";
if (!Directory.Exists(dir_path))
{
Directory.CreateDirectory(dir_path);
}
if (addressBackground != dir_path + "\\" + Path.GetFileName(addressBackground))
{
File.Copy(addressBackground, dir_path + "\\" + Path.GetFileName(addressBackground), true);
}
Files.CreateStruct(mainFilename);
Files.OpenMain(mainFilename, PictureBoxBackground, addressBackground);
for (int nomer = 0; nomer < nomerPersa; nomer++)
{
File.Copy(persons[nomer].address, dir_path + "\\" + Path.GetFileName(persons[nomer].address), true);
if (dir_path == dir_path + "\\" + Path.GetFileName(persons[nomer].address))
{
File.Copy(persons[nomer].address, dir_path + "\\" + Path.GetFileName(persons[nomer].address), true);
}
if (persons[nomer].moveside == "Прямо")
{
Line.CreatePerson(mainFilename, Person.PersonName(nomer), persons[nomer]);
}
else if (persons[nomer].moveside == "Волнами")
{
Sinus.CreatePerson(mainFilename, Person.PersonName(nomer), persons[nomer]);
}
else if (persons[nomer].moveside == "Кругами")
{
Circle.CreatePerson(mainFilename, Person.PersonName(nomer), persons[nomer]);
}
else if (persons[nomer].moveside == "Диагонально")
{
Line.CreatePerson(mainFilename, Person.PersonName(nomer), persons[nomer]);
}
}
Files.OpenWhile(mainFilename, maxTime);
for (int nomer = 0; nomer < nomerPersa; nomer++)
{
if (persons[nomer].moveside == "Прямо")
{
Line.MovePerson(mainFilename, Person.PersonName(nomer), persons[nomer]);
}
else if (persons[nomer].moveside == "Волнами")
{
Sinus.MovePerson(mainFilename, Person.PersonName(nomer), persons[nomer]);
}
else if (persons[nomer].moveside == "Кругами")
{
Circle.MovePerson(mainFilename, Person.PersonName(nomer), persons[nomer]);
}
else if (persons[nomer].moveside == "Диагонально")
{
Line.MovePerson(mainFilename, Person.PersonName(nomer), persons[nomer]);
}
}
Files.CloseWhile(mainFilename);
DeletePics(mainFilename, nomerPersa);
Files.Ending(mainFilename, checkBox1.Checked);
MessageBox.Show("Готово!");
}
catch (Exception ex)
{
_ = MessageBox.Show("Произошла ошибка!\n" + ex.Message, "Ошибка",
MessageBoxButtons.OK, MessageBoxIcon.Error);
}
}
}
private void Char_Creator_Button_Click(object sender, MouseEventArgs e)
{
for (int nomer = 0; nomer < nomerPersa; nomer++)
{
if (sender.Equals(persons[nomer].b1))
{
TextBoxWall1.Text = persons[nomer].coord;
TextBoxWall2.Text = persons[nomer].coord2;
TextBoxTime1.Text = persons[nomer].time1;
TextBoxTime2.Text = persons[nomer].time2;
SpriteNumberTextBox.Text = persons[nomer].sprite;
ComboBoxMove.Text = persons[nomer].moveside;
pNomer = persons[nomer].nomer;
charNameBox.Text = persons[nomer].charname;
circlesTextBox.Text = persons[nomer].circles;
if (!String.IsNullOrEmpty(persons[nomer].address))
{
openSpace.Image = Image.FromFile(persons[nomer].address);
}
else
{
openSpace.Image = null;
}
}
}
}
private void Char_Info_Click(object sender, EventArgs e)
{
leftPanel.Controls.Remove(persons[nomerPersa - 1].l1);
leftPanel.Controls.Remove(persons[nomerPersa - 1].l2);
leftPanel.Controls.Remove(persons[nomerPersa - 1].l3);
leftPanel.Controls.Remove(persons[nomerPersa - 1].b1);
leftPanel.Controls.Remove(persons[nomerPersa - 1].b2);
nomerPersa--;
yPersa -= 30;
}
private void TextBoxWall1_KeyPress(object sender, KeyPressEventArgs e)
{
char c = e.KeyChar;
if (!(char.IsDigit(c) || c == '\b' || c == ','))
{
e.Handled = true;
}
}
private void MainForm_Load(object sender, EventArgs e)
{
ToolTip tView = new ToolTip();
tView.IsBalloon = true;
tView.InitialDelay = 0;
tView.ShowAlways = true;
tView.AutoPopDelay = 2000;
tView.SetToolTip(TextBoxWall1, "x.y");
ToolTip tView2 = new ToolTip();
tView2.IsBalloon = true;
tView2.InitialDelay = 0;
tView2.ShowAlways = true;
tView2.AutoPopDelay = 2000;
tView2.SetToolTip(TextBoxWall2, "x.y");
ComboBoxMove_SelectedIndexChanged(sender, e);
}
private void ComboBoxMove_SelectedIndexChanged(object sender, EventArgs e)
{
if (ComboBoxMove.Text == "Кругами")
{
circlesTextBox.Visible = true;
circlesLabel.Visible = true;
}
else
{
circlesTextBox.Visible = false;
circlesLabel.Visible = false;
}
}
private void button1_Click(object sender, EventArgs e)
{
if (!String.IsNullOrEmpty(mainFilename))
panel3.Visible = true;
}
private void label9_Click(object sender, EventArgs e)
{
}
private void label10_Click(object sender, EventArgs e)
{
}
private void button4_Click(object sender, EventArgs e)
{
//Ñïèñîê âñåõ ôàéëîâ ïàïêè
//Ñîçäàåøü èç íèõ ìàññèâ (èëè ñïèñîê)
//Âûáèðàåøü ðàíäîìíûé íîìåð
//pictureBox1.Image = Image.FromFile("kartinka.jpg");
}
private void pictureBox1_Click(object sender, EventArgs e)
{
}
private void create_struct(string filename)
{
File.WriteAllText(filename, "");
File.AppendAllText(filename, "#include \"TXLib.h\"" + Environment.NewLine);
File.AppendAllText(filename, Environment.NewLine);
File.AppendAllText(filename, "struct Person" + Environment.NewLine);
File.AppendAllText(filename, "{" + Environment.NewLine);
File.AppendAllText(filename, " double x;" + Environment.NewLine);
File.AppendAllText(filename, " double y;" + Environment.NewLine);
File.AppendAllText(filename, " double angle;" + Environment.NewLine);
File.AppendAllText(filename, " double nomer_kadra;" + Environment.NewLine);
File.AppendAllText(filename, " HDC texture;" + Environment.NewLine);
File.AppendAllText(filename, " int MID_x;" + Environment.NewLine);
File.AppendAllText(filename, " int MID_y;" + Environment.NewLine);
File.AppendAllText(filename, " int rad;" + Environment.NewLine);
File.AppendAllText(filename, " int skorost;" + Environment.NewLine);
File.AppendAllText(filename, " int gr_dvigx;" + Environment.NewLine);
File.AppendAllText(filename, " int gr_dvigy;" + Environment.NewLine);
File.AppendAllText(filename, " int nach_dv;" + Environment.NewLine);
File.AppendAllText(filename, " int ampl_y;" + Environment.NewLine);
File.AppendAllText(filename, " int ampl_x;" + Environment.NewLine);
File.AppendAllText(filename, " double BeginTime;" + Environment.NewLine);
File.AppendAllText(filename, " double EndTime;" + Environment.NewLine);
File.AppendAllText(filename, " double Time;" + Environment.NewLine);
File.AppendAllText(filename, "};" + Environment.NewLine);
File.AppendAllText(filename, Environment.NewLine);
File.AppendAllText(filename, "int main()" + Environment.NewLine);
File.AppendAllText(filename, "{" + Environment.NewLine);
File.AppendAllText(filename, " txCreateWindow(" +
PictureBoxBackground.Image.Width.ToString() + ", " +
PictureBoxBackground.Image.Height.ToString() + ");" + Environment.NewLine);
}
private void open_while(string filename)
{
File.AppendAllText(filename, Environment.NewLine);
File.AppendAllText(filename, " while (!GetAsyncKeyState(VK_ESCAPE));" + Environment.NewLine);
File.AppendAllText(filename, " {" + Environment.NewLine);
File.AppendAllText(filename, " txSetColor(TX_RED);" + Environment.NewLine);
File.AppendAllText(filename, " txSetFillColor(TX_RED);" + Environment.NewLine);
File.AppendAllText(filename, " txRectangle(0, 0, txGetExtentX(), txGetExtentY());" + Environment.NewLine);
}
private void close_while(string filename)
{
File.AppendAllText(filename, Environment.NewLine);
File.AppendAllText(filename, " txSleep(10);" + Environment.NewLine);
File.AppendAllText(filename, " }" + Environment.NewLine);
}
private void delete_pics(string filename)
{
File.AppendAllText(filename, Environment.NewLine);
File.AppendAllText(filename, " txDeleteDC(per.texture);" + Environment.NewLine);
}
private void file_forser(string filename)
{
File.AppendAllText(filename, Environment.NewLine);
File.AppendAllText(filename, "txSetColor(TX_WHITE);" + Environment.NewLine);
File.AppendAllText(filename, "txSetFillColor(TX_WHITE);" + Environment.NewLine);
File.AppendAllText(filename, "txRectangle(0, 0, 800, 600);" + Environment.NewLine);
File.AppendAllText(filename, "HDC texture = txLoadImage(\"Pictures\\Personaj.bmp\");" + Environment.NewLine);
}
private void file_ending(string filename)
{
File.AppendAllText(filename, "return " + SpriteNumberTextBox.Text + "0;" + Environment.NewLine);
File.AppendAllText(filename, "}" + Environment.NewLine);
}
private void SaveCharButtonClick(object sender, EventArgs e)
{
if (PictureBoxBackground.Image == null)
{
new CompileForm(mainFilename).ShowDialog();
return;
}
else
{
_ = MessageBox.Show("Сначала сохраните мультфильм!");
if (saveFileDialog1.ShowDialog() == DialogResult.OK)
{
string filename = saveFileDialog1.FileName;
//main.cpp
create_struct(filename);
if (ComboBoxMove.Text == "Прямо")
{
sinus_create_person(filename);
old_place (filename);
open_while(filename);
go_pryamo(filename);
close_while(filename);
// delete_pics(filename);
}
else if (ComboBoxMove.Text == "Волнами")
{
sinus_create_person(filename);
open_while(filename);
sinus3(filename);
close_while(filename);
delete_pics(filename);
}
else if (ComboBoxMove.Text == "Кругами")
{
circle_create_person(filename);
open_while(filename);
circle(filename);
close_while(filename);
delete_pics(filename);
}
file_ending(filename);
//Add TXLib and pics
File.Copy("TXLib.h", filename.Replace(Path.GetFileName(filename), "TXLib.h"), true);
string adres_papki = filename.Replace(Path.GetFileName(filename), "Pictures");
if (!Directory.Exists(adres_papki))
{
Directory.CreateDirectory(adres_papki);
}
File.Copy("kartinka.bmp", adres_papki + "\\Personaj.bmp", true);
MessageBox.Show("Complete");
}
}
private void sinus_create_person(string filename)
{
File.AppendAllText(filename, " Person per;" + Environment.NewLine);
File.AppendAllText(filename, Environment.NewLine);
File.AppendAllText(filename, " per.texture = txLoadImage(\"Pictures\\Personaj.bmp\");" + Environment.NewLine);
File.AppendAllText(filename, " per.x = " + TextBoxWall1.Text + ";" + Environment.NewLine);
File.AppendAllText(filename, " per.y = " + TextBoxWall1.Text + ";" + Environment.NewLine);
File.AppendAllText(filename, " per.nomer_kadra = 0;" + Environment.NewLine);
File.AppendAllText(filename, " per.nach_dv = per.y;" + Environment.NewLine);
File.AppendAllText(filename, " per.ampl_y = 150;" + Environment.NewLine);
File.AppendAllText(filename, " per.ampl_x = 10;" + Environment.NewLine);
}
private void sinus3(string filename)
{
File.AppendAllText(filename, " per.x++;" + Environment.NewLine);
File.AppendAllText(filename, " per.y = per.nach_dv + per.ampl_y * sin(per.x / per.ampl_x);" + Environment.NewLine);
File.AppendAllText(filename, " txTransparentBlt(txDC(), per.x, per.y, 55, 86, per.texture, 55 * per.nomer_kadra, 0, RGB(0, 255, 255));" + Environment.NewLine);
File.AppendAllText(filename, Environment.NewLine);
File.AppendAllText(filename, " per.nomer_kadra++;" + Environment.NewLine);
File.AppendAllText(filename, " if (per.nomer_kadra > " + SpriteNumberTextBox.Text + ")" + Environment.NewLine);
File.AppendAllText(filename, " {" + Environment.NewLine);
File.AppendAllText(filename, " per.nomer_kadra = 0;" + Environment.NewLine);
File.AppendAllText(filename, " }" + Environment.NewLine);
}
private void circle_create_person(string filename)
{
File.AppendAllText(filename, " HDC texture = txLoadImage(\"Pictures\\Personaj.bmp);" + Environment.NewLine);
File.AppendAllText(filename, Environment.NewLine);
File.AppendAllText(filename, " double textureX = 50;"+ Environment.NewLine);
File.AppendAllText(filename, " double textureY = 50;"+ Environment.NewLine);
File.AppendAllText(filename, " double angle = 0;"+ Environment.NewLine);
File.AppendAllText(filename, " double nomer_kadra = 0;"+ Environment.NewLine);
File.AppendAllText(filename, Environment.NewLine);
}
private void old_place(string filename)
{
File.AppendAllText(filename, " per.x = 10; " + Environment.NewLine);
File.AppendAllText(filename, " per.y = 10; " + Environment.NewLine);
File.AppendAllText(filename, " per.nomer_kadra = 0; " + Environment.NewLine);
File.AppendAllText(filename, " per.gr_dvigx = 1000; " + Environment.NewLine);
}
private void go_pryamo(string filename)
{
File.AppendAllText(filename, " txTransparentBlt(txDC(), per.x, per.y, 55, 86, per.texture, 55 * per.nomer_kadra, 0, RGB(0, 255, 255)); " + Environment.NewLine);
File.AppendAllText(filename, " per.x++; " + Environment.NewLine);
File.AppendAllText(filename, " per.nomer_kadra++;" + Environment.NewLine);
File.AppendAllText(filename, " if (per.nomer_kadra > 2) " + Environment.NewLine);
File.AppendAllText(filename, " { " + Environment.NewLine);
File.AppendAllText(filename, " per.nomer_kadra = 0;" + Environment.NewLine);
File.AppendAllText(filename, " }" + Environment.NewLine);
}
private void circle(string filename)
{
File.AppendAllText(filename, " angle++;"+ Environment.NewLine);
File.AppendAllText(filename, " textureX = 500 + 200 * cos (angle / 10);"+ Environment.NewLine);
File.AppendAllText(filename, " textureY = 300 + 200 * sin (angle / 10);"+ Environment.NewLine);
File.AppendAllText(filename, " txTransparentBlt(txDC(), textureX, textureY, 55, 86, texture, 55 * nomer_kadra, 0, RGB(0, 255, 255));"+ Environment.NewLine);
File.AppendAllText(filename, Environment.NewLine);
File.AppendAllText(filename, " nomer_kadra++;"+ Environment.NewLine);
File.AppendAllText(filename, Environment.NewLine);
File.AppendAllText(filename, " if (nomer_kadra > 2)"+ Environment.NewLine);
File.AppendAllText(filename, " {"+ Environment.NewLine);
File.AppendAllText(filename, " nomer_kadra = 0;"+ Environment.NewLine);
File.AppendAllText(filename, " }"+ Environment.NewLine);
File.AppendAllText(filename, Environment.NewLine);
}
private void button5_Click(object sender, EventArgs e)
{
if (openFileDialog1.ShowDialog() == DialogResult.Cancel)
return;
string filename = openFileDialog1.FileName;
string fileText =File.ReadAllText(filename);
nazvanieTextBox.Text = fileText;
MessageBox.Show("Ôàéë îòêðûò");
}
private void textBox6_TextChanged(object sender, EventArgs e)
{
}
private void label8_Click(object sender, EventArgs e)
{
}
private void label13_Click(object sender, EventArgs e)
{
}
private void label13_Click_1(object sender, EventArgs e)
{
}
private void button6_Click(object sender, EventArgs e)
{
if (openFileDialog1.ShowDialog() == DialogResult.Cancel)
return;
string filename = openFileDialog1.FileName;
string fileText = File.ReadAllText(filename);
nazvanieTextBox.Text = fileText;
PictureBoxBackground.Image = Image.FromFile("kartinka.bmp");
MessageBox.Show(PictureBoxBackground.Image.Width.ToString());
}
private void button1_Click_1(object sender, EventArgs e)
{
Close();
}
private void TextBoxWall2_TextChanged(object sender, EventArgs e)
{
}
private void label2_Click(object sender, EventArgs e)
{
}
private void label1_Click_1(object sender, EventArgs e)
{
}
private void label7_Click(object sender, EventArgs e)
{
}
private void button2_Click(object sender, EventArgs e)
{
l1[0] = new Label();
l1[0].Top = yPersa;
l1[0].Left = 30;
l1[0].Width = 20;
l1[0].Visible = true;
l1[0].Text = "1";
this.panel1.Controls.Add(l1[0]);
l2[0] = new Label();
l2[0].Top = yPersa;
l2[0].Left = 60;
l2[0].Width = 60;
l2[0].Visible = true;
l2[0].Text = "Перс1";
this.panel1.Controls.Add(l2[0]);
l3[0] = new Label();
l3[0].Top = yPersa;
l3[0].Left = 120;
l3[0].Width = 40;
l3[0].Visible = true;
l3[0].Text = "ocphcghfgh";
this.panel1.Controls.Add(l3[0]);
b1[0] = new Button();
b1[0].Top = yPersa;
b1[0].Left = 170;
b1[0].Width = 50;
b1[0].Visible = true;
b1[0].Text = "R";
this.panel1.Controls.Add(b1[0]);
b2[0] = new Button();
b2[0].Top = yPersa;
b2[0].Left = 230;
b2[0].Width = 50;
b2[0].Visible = true;
b2[0].Text = "X";
this.panel1.Controls.Add(b2[0]);
yPersa = yPersa + 30;
}
private void button3_Click(object sender, EventArgs e)
{
}
private void TextBoxWall1_TextChanged(object sender, EventArgs e)
{
}
}
}

View file

@ -1,37 +0,0 @@
using System;
using System.Windows.Forms;
namespace WindowsFormsApplication1
{
public struct Person
{
public Label l1;
public Label l2;
public Label l3;
public Button b1;
public Button b2;
public int nomer;
public String coord;
public String coord2;
// TODO: Add fields
public String x1;
public String y1;
public String x2;
public String y2;
public String address;
public String time1;
public String time2;
public String sprite;
public String moveside;
public String charname;
public String height;
public String width;
public String circles;
public static string PersonName(int nomer)
{
return "per" + nomer.ToString();
}
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 10 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 147 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.4 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.4 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.4 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.4 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.4 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 176 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 176 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 176 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 176 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 176 KiB

View file

@ -19,7 +19,7 @@ namespace WindowsFormsApplication1.Properties {
// с помощью такого средства, как ResGen или Visual Studio.
// Чтобы добавить или удалить член, измените файл .ResX и снова запустите ResGen
// с параметром /str или перестройте свой проект VS.
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "16.0.0.0")]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "15.0.0.0")]
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
internal class Resources {
@ -59,20 +59,5 @@ namespace WindowsFormsApplication1.Properties {
resourceCulture = value;
}
}
/// <summary>
/// Ищет локализованную строку, похожую на //=================================================================================================================
///// [These sections are for folding control in Code::Blocks]
/////{ [Best viewed with &quot;Fold all on file open&quot; option enabled] [best screen width is 115 chars]
/////=================================================================================================================
/////!
/////! @file TXLib.h
/////! @brief Библиотека Тупого Художника (The Dumb Artist Libr [остаток строки не уместился]&quot;;.
/// </summary>
internal static string TXLib {
get {
return ResourceManager.GetString("TXLib", resourceCulture);
}
}
}
}

View file

@ -46,7 +46,7 @@
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: System.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
@ -60,7 +60,6 @@
: 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">
@ -69,10 +68,9 @@
<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="name" 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">
@ -87,10 +85,9 @@
<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="name" type="xsd:string" 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">
@ -112,13 +109,9 @@
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
<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=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<assembly alias="System.Windows.Forms" name="System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
<data name="TXLib" type="System.Resources.ResXFileRef, System.Windows.Forms">
<value>..\TXLib.h;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089;windows-1251</value>
</data>
</root>

View file

@ -1,51 +0,0 @@
using System;
using System.IO;
namespace WindowsFormsApplication1
{
public class Sinus
{
public static void CreatePerson(string filename, string name, Person p)
{
StreamWriter sw = new StreamWriter(filename, true);
sw.Write(Environment.NewLine);
sw.Write(" Person " + name + ";" + Environment.NewLine);
sw.Write(" " + name + ".texture = txLoadImage(\"Pictures\\\\" + Path.GetFileName(p.address) + "\"); " +
Environment.NewLine);
sw.Write(" " + name + ".x = " + p.x1 + ";" + Environment.NewLine);
sw.Write(" " + name + ".y = " + p.y1 + ";" + Environment.NewLine);
sw.Write(" " + name + ".x2 = " + p.x2 + "; " + Environment.NewLine);
sw.Write(" " + name + ".y2 = " + p.y2 + "; " + Environment.NewLine);
sw.Write(" " + name + ".nomer_kadra = 0;" + Environment.NewLine);
sw.Write(" " + name + ".nach_dv = (" + p.y1 + "+" + p.y2 + ")/2;" + Environment.NewLine);
sw.Write(" " + name + ".ampl_y = abs(" + p.y1 + "-" + name + ".nach_dv)/2;" + Environment.NewLine);
sw.Write(" " + name + ".ampl_x = 10;" + Environment.NewLine);
sw.Close();
}
public static void MovePerson(string filename, string name, Person p)
{
StreamWriter sw = new StreamWriter(filename, true);
sw.Write(" if ((myTime >= " + p.time1 + ") && (myTime <= " + p.time2 + ")) {" + Environment.NewLine);
sw.Write(" " + name + ".x+= (" + name + ".x2 - " + name + ".x) / (" + p.time2 + "-" +
p.time1 + ");" + Environment.NewLine);
sw.Write(" " + name + ".y+= (" + name + ".y2 - " + name + ".y) / (" + p.time2 + "-" +
p.time1 + ");" + Environment.NewLine);
sw.Write(" " + name + ".y = " + name + ".nach_dv + " + name + ".ampl_y * sin(" + name +
".x / " + name + ".ampl_x);" + Environment.NewLine);
sw.Write(" txTransparentBlt(txDC(), " + name + ".x, " + name + ".y, " +
p.width + "/" + p.sprite + ", " +
p.height + "," +
name + ".texture, " +
p.width + "/" + p.sprite + " * " + name + ".nomer_kadra, 0, RGB(255, 255, 255));" + Environment.NewLine);
sw.Write(Environment.NewLine);
sw.Write(" " + name + ".nomer_kadra++;" + Environment.NewLine);
sw.Write(" if (" + name + ".nomer_kadra >= " + p.sprite + ")" + Environment.NewLine);
sw.Write(" {" + Environment.NewLine);
sw.Write(" " + name + ".nomer_kadra = 0;" + Environment.NewLine);
sw.Write(" }" + Environment.NewLine);
sw.Write(" }" + Environment.NewLine);
sw.Close();
}
}
}

View file

@ -48,28 +48,14 @@
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="Circle.cs" />
<Compile Include="CompileForm.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="CompileForm.Designer.cs">
<DependentUpon>CompileForm.cs</DependentUpon>
</Compile>
<Compile Include="Files.cs" />
<Compile Include="Line.cs" />
<Compile Include="MainForm.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="MainForm.Designer.cs">
<DependentUpon>MainForm.cs</DependentUpon>
</Compile>
<Compile Include="Person.cs" />
<Compile Include="Program.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
<Compile Include="Sinus.cs" />
<EmbeddedResource Include="CompileForm.resx">
<DependentUpon>CompileForm.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="MainForm.resx">
<DependentUpon>MainForm.cs</DependentUpon>
</EmbeddedResource>
@ -94,9 +80,6 @@
<DesignTimeSharedInput>True</DesignTimeSharedInput>
</Compile>
</ItemGroup>
<ItemGroup>
<None Include="TXLib.h" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\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.

View file

@ -0,0 +1,3 @@
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<startup><supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.6.1"/></startup></configuration>

View file

@ -0,0 +1,11 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
<assemblyIdentity version="1.0.0.0" name="MyApplication.app"/>
<trustInfo xmlns="urn:schemas-microsoft-com:asm.v2">
<security>
<requestedPrivileges xmlns="urn:schemas-microsoft-com:asm.v3">
<requestedExecutionLevel level="asInvoker" uiAccess="false"/>
</requestedPrivileges>
</security>
</trustInfo>
</assembly>

View file

Before

Width:  |  Height:  |  Size: 147 KiB

After

Width:  |  Height:  |  Size: 147 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 10 KiB

View file

@ -0,0 +1 @@
f27943f0e34f482c9aac41b3c68fb08d02204b37

View file

@ -0,0 +1,20 @@
C:\Users\user\Desktop\MultRedactor-master\WindowsFormsApplication1\WindowsFormsApplication1\bin\Debug\WindowsFormsApplication1.exe.config
C:\Users\user\Desktop\MultRedactor-master\WindowsFormsApplication1\WindowsFormsApplication1\bin\Debug\WindowsFormsApplication1.exe
C:\Users\user\Desktop\MultRedactor-master\WindowsFormsApplication1\WindowsFormsApplication1\bin\Debug\WindowsFormsApplication1.pdb
C:\Users\user\Desktop\MultRedactor-master\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\WindowsFormsApplication1.csprojResolveAssemblyReference.cache
C:\Users\user\Desktop\MultRedactor-master\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\WindowsFormsApplication1.MainForm.resources
C:\Users\user\Desktop\MultRedactor-master\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\WindowsFormsApplication1.Properties.Resources.resources
C:\Users\user\Desktop\MultRedactor-master\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\WindowsFormsApplication1.csproj.GenerateResource.Cache
C:\Users\user\Desktop\MultRedactor-master\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\WindowsFormsApplication1.csproj.CoreCompileInputs.cache
C:\Users\user\Desktop\MultRedactor-master\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\WindowsFormsApplication1.exe
C:\Users\user\Desktop\MultRedactor-master\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\WindowsFormsApplication1.pdb
C:\Users\Админ\Desktop\MultRedactor-master\WindowsFormsApplication1\WindowsFormsApplication1\bin\Debug\WindowsFormsApplication1.exe.config
C:\Users\Админ\Desktop\MultRedactor-master\WindowsFormsApplication1\WindowsFormsApplication1\bin\Debug\WindowsFormsApplication1.exe
C:\Users\Админ\Desktop\MultRedactor-master\WindowsFormsApplication1\WindowsFormsApplication1\bin\Debug\WindowsFormsApplication1.pdb
C:\Users\Админ\Desktop\MultRedactor-master\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\WindowsFormsApplication1.csprojResolveAssemblyReference.cache
C:\Users\Админ\Desktop\MultRedactor-master\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\WindowsFormsApplication1.MainForm.resources
C:\Users\Админ\Desktop\MultRedactor-master\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\WindowsFormsApplication1.Properties.Resources.resources
C:\Users\Админ\Desktop\MultRedactor-master\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\WindowsFormsApplication1.csproj.GenerateResource.Cache
C:\Users\Админ\Desktop\MultRedactor-master\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\WindowsFormsApplication1.csproj.CoreCompileInputs.cache
C:\Users\Админ\Desktop\MultRedactor-master\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\WindowsFormsApplication1.exe
C:\Users\Админ\Desktop\MultRedactor-master\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\WindowsFormsApplication1.pdb