|
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035 |
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
- using System.Windows;
- using System.Windows.Controls;
- using System.Windows.Data;
- using System.Windows.Documents;
- using System.Windows.Input;
- using System.Windows.Media;
- using System.Windows.Media.Imaging;
- using System.Windows.Navigation;
- using System.Windows.Shapes;
- using System.Diagnostics;
- using System.Windows.Threading;
- using Grpc.Core;
- using Protobuf;
-
- // 目前MainWindow还未复现的功能:
- // 部分errordisplayer
- // private void ReactToCommandline(),
- // private void Playback(string fileName, double pbSpeed = 2.0)
-
- // 交互:private void ClickToSetMode(object sender, RoutedEventArgs e)
-
- // private void Bonus()
-
- namespace Client
- {
- /// <summary>
- /// Interaction logic for MainWindow.xaml
- /// </summary>
- public partial class MainWindow : Window
- {
- public MainWindow()
- {
- unitHeight = unitWidth = unit = 13;
- bonusflag = true;
- timer = new DispatcherTimer
- {
- Interval = new TimeSpan(50000) // 每50ms刷新一次
- };
- timer.Tick += new EventHandler(Refresh); // 定时器初始化
- InitializeComponent();
- timer.Start();
- SetStatusBar();
- isClientStocked = true;
- isPlaybackMode = false;
- drawPicLock = new();
- listOfProp = new List<MessageOfProp>();
- listOfHuman = new List<MessageOfStudent>();
- listOfButcher = new List<MessageOfTricker>();
- listOfBullet=new List<MessageOfBullet>();
- listOfBombedBullet = new List<MessageOfBombedBullet>();
- listOfAll = new List<MessageOfAll>();
- WindowStartupLocation = WindowStartupLocation.CenterScreen;
- comInfo[0] = "183.172.212.19";
- comInfo[1] = "8888";
- comInfo[2] = "0";
- comInfo[3] = "1";
-
- ConnectToServer(comInfo);
- OnReceive();
- //DrawMap();
- //ZoomMap();
- //MessageOfStudent kurei = new MessageOfStudent();
- //kurei.X = 10000;
- //kurei.Y = 20000;
- //kurei.Speed = 1000;
- //kurei.PlayerId = 0;
- //listOfHuman.Add(kurei);
- //MessageOfAll all= new MessageOfAll();
- //all.HiddenGateRefreshed = false;
- //listOfAll.Add(all);
- // ReactToCommandline();
- }
-
- private void SetStatusBar()
- {
- StatusBarsOfSurvivor = new StatusBarOfSurvivor[4];
- StatusBarsOfHunter = new StatusBarOfHunter(MainGrid, 3, 0);
- StatusBarsOfCircumstance = new StatusBarOfCircumstance(MainGrid, 1, 0);
- for (int i = 4; i < 8; i++)
- {
- StatusBarsOfSurvivor[i - 4] = new(MainGrid, i / 2 + 2, i % 2);
- }
- }
-
- // 连接Server,comInfo[]的格式:0-ip 1- port 2-playerID 3-human/TrickerType
- private void ConnectToServer(string[] comInfo)
- {
- if (!isPlaybackMode)
- {
- if (comInfo.Length != 5)
- throw new Exception("注册信息有误!");
- playerID = Convert.ToInt64(comInfo[2]);
- Connect.Background = Brushes.Gray;
- string connect = new string(comInfo[0]);
- connect += ':';
- connect += comInfo[1];
- Channel channel = new Channel(connect, ChannelCredentials.Insecure);
- client = new AvailableService.AvailableServiceClient(channel);
- // 没判断连没连上
-
- PlayerMsg playerMsg = new PlayerMsg();
- playerMsg.PlayerId = playerID;
- playerType = Convert.ToInt64(comInfo[3]) switch
- {
- 0 => PlayerType.NullPlayerType,
- 1 => PlayerType.StudentPlayer,
- 2 => PlayerType.TrickerPlayer,
- };
- if (Convert.ToInt64(comInfo[3]) == 1)
- {
- humanOrButcher = true;
- }
- else if (Convert.ToInt64(comInfo[3]) == 2)
- {
- humanOrButcher = false;
- }
- if (playerType == PlayerType.StudentPlayer)
- {
- switch (Convert.ToInt64(comInfo[4]))
- {
- case 0:
- playerMsg.StudentType = StudentType.NullStudentType;
- break;
- case 1:
- playerMsg.StudentType = StudentType._1;
- break;
- case 2:
- playerMsg.StudentType = StudentType._2;
- break;
- case 3:
- playerMsg.StudentType = StudentType._3;
- break;
- case 4:
- playerMsg.StudentType = StudentType._4;
- break;
- default:
- break;
- }
- }
- else if (playerType == PlayerType.TrickerPlayer)
- {
- switch (Convert.ToInt64(comInfo[4]))
- {
- case 0:
- playerMsg.TrickerType = TrickerType.NullTrickerType;
- break;
- case 1:
- playerMsg.TrickerType = TrickerType._1;
- break;
- case 2:
- playerMsg.TrickerType = TrickerType._2;
- break;
- case 3:
- playerMsg.TrickerType = TrickerType._3;
- break;
- case 4:
- playerMsg.TrickerType = TrickerType._4;
- break;
- default:
- break;
- }
- }
- responseStream = client.AddPlayer(playerMsg);
- Connect.Background = Brushes.Transparent;
- isClientStocked = false;
- PorC.Content = "⏸";
- // 建立连接的同时加入人物
- }
- }
-
- // 绘制道具
- private void DrawProp(MessageOfProp data, string text)
- {
- TextBox icon = new()
- {
- FontSize = 10,
- Width = 20,
- Height = 20,
- Text = text,
- HorizontalAlignment = HorizontalAlignment.Left,
- VerticalAlignment = VerticalAlignment.Top,
- Margin = new Thickness(data.Y * unitWidth / 1000.0 - unitWidth / 2, data.X * unitHeight / 1000.0 - unitHeight / 2, 0, 0),
- Background = Brushes.Transparent,
- BorderBrush = Brushes.Transparent,
- IsReadOnly = true
- };
- UpperLayerOfMap.Children.Add(icon);
- }
-
- // 获得地图信息,未更新数值
- private void GetMap(MessageOfMap obj)
- {
- int[,] map = new int[50, 50];
- try
- {
- for (int i = 0; i < 50; i++)
- {
- for (int j = 0; j < 50; j++)
- {
- map[i, j] = Convert.ToInt32(obj.Row[i].Col[j])+4;//与proto一致
- }
- }
- }
- catch
- {
- mapFlag = false;
- }
- finally
- {
- defaultMap = map;
- mapFlag = true;
- }
- }
- private void ZoomMap()
- {
- for (int i = 0; i < 50; i++)
- {
- for (int j = 0; j < 50; j++)
- {
- if (mapPatches[i, j] != null)
- {
- mapPatches[i, j].Width = UpperLayerOfMap.ActualWidth / 50;
- mapPatches[i, j].Height = UpperLayerOfMap.ActualHeight / 50;
- mapPatches[i, j].HorizontalAlignment = HorizontalAlignment.Left;
- mapPatches[i, j].VerticalAlignment = VerticalAlignment.Top;
- mapPatches[i, j].Margin = new Thickness(UpperLayerOfMap.ActualWidth / 50 * j, UpperLayerOfMap.ActualHeight / 50 * i, 0, 0);
- }
- }
- }
- }
- private void DrawMap()
- {
- for (int i = 0; i < defaultMap.GetLength(0); i++)
- {
- for (int j = 0; j < defaultMap.GetLength(1); j++)
- {
- mapPatches[i, j] = new()
- {
- Width = unitWidth,
- Height = unitHeight,
- HorizontalAlignment = HorizontalAlignment.Left,
- VerticalAlignment = VerticalAlignment.Top,
- Margin = new Thickness(Width * (j), Height * (i), 0, 0)
- };
- // mapPatches[i, j].SetValue(Canvas.LeftProperty, (double)(Width / 65.5 * j));
- // mapPatches[i, j].SetValue(Canvas.TopProperty, (double)(Height / 56.5 * i)); // 用zoommap进行修改
- switch (defaultMap[i, j])
- {
- case 6:
- mapPatches[i, j].Fill = Brushes.Brown;
- mapPatches[i, j].Stroke = Brushes.Brown;
- break;//wall
- case 7:
- mapPatches[i, j].Fill = Brushes.Green;
- mapPatches[i, j].Stroke = Brushes.Green;
- break;//grass
- case 8:
- mapPatches[i, j].Fill = Brushes.LightPink;
- mapPatches[i, j].Stroke = Brushes.LightPink;
- break;//machine
- case 9:
- mapPatches[i, j].Fill = Brushes.LightSkyBlue;
- mapPatches[i, j].Stroke = Brushes.LightSkyBlue;
- break;//door
- case 10:
- foreach (var obj in listOfAll)
- {
- if(obj.HiddenGateRefreshed)
- {
- mapPatches[i, j].Fill = Brushes.LightSalmon;
- mapPatches[i, j].Stroke = Brushes.LightSalmon;
- }
- }
- break;//emergency
- default:
- break;
- }
- UnderLayerOfMap.Children.Add(mapPatches[i, j]);
- }
- }
- hasDrawed = true;
- }
-
- //三个参数分别为攻击者的位置,攻击方位角(窗口坐标)和攻击半径
- private void DrawLaser(Point source, double theta, double range, double Width) // 三个参数分别为攻击者的位置,攻击方位角(窗口坐标)和攻击半径
- {
- Point[] endPoint = new Point[4];
- Point target = new();
- target.X = source.X + range * Math.Cos(theta);
- target.Y = source.Y + range * Math.Sin(theta);
- endPoint[0].X = source.X + Width * Math.Cos(theta - Math.PI / 2);
- endPoint[0].Y = source.Y + Width * Math.Sin(theta - Math.PI / 2);
- endPoint[1].X = target.X + Width * Math.Cos(theta - Math.PI / 2);
- endPoint[1].Y = target.Y + Width * Math.Sin(theta - Math.PI / 2);
- endPoint[2].X = target.X + Width * Math.Cos(theta + Math.PI / 2);
- endPoint[2].Y = target.Y + Width * Math.Sin(theta + Math.PI / 2);
- endPoint[3].X = source.X + Width * Math.Cos(theta + Math.PI / 2);
- endPoint[3].Y = source.Y + Width * Math.Sin(theta + Math.PI / 2);
- Polygon laserIcon = new();
- laserIcon.Stroke = System.Windows.Media.Brushes.Red;
- laserIcon.Fill = System.Windows.Media.Brushes.Red;
- laserIcon.StrokeThickness = 2;
- laserIcon.HorizontalAlignment = HorizontalAlignment.Left;
- laserIcon.VerticalAlignment = VerticalAlignment.Top;
- PointCollection laserEndPoints = new();
- for (int i = 0; i < 4; i++)
- {
- laserEndPoints.Add(endPoint[i]);
- }
- laserIcon.Points = laserEndPoints;
- UpperLayerOfMap.Children.Add(laserIcon);
- }
-
- private async void OnReceive() // 已按照3.5版proto更新信息,但是左侧信息栏还未填充。log未更新,switch1,2,3更新log
- {
- try
- {
- while (responseStream != null && await responseStream.ResponseStream.MoveNext())
- {
- lock (drawPicLock) // 加锁是必要的,画图操作和接收信息操作不能同时进行,否则画图时foreach会有bug
- {
- listOfHuman.Clear();
- listOfButcher.Clear();
- listOfProp.Clear();
- listOfBombedBullet.Clear();
- listOfBullet.Clear();
- listOfAll.Clear();
- MessageToClient content = responseStream.ResponseStream.Current;
- switch (content.GameState)
- {
- case GameState.GameStart:
- foreach (var obj in content.ObjMessage)
- {
- switch (obj.MessageOfObjCase)
- {
- case MessageOfObj.MessageOfObjOneofCase.StudentMessage:
- if (humanOrButcher && obj.StudentMessage.PlayerId == playerID)
- {
- human = obj.StudentMessage;
- }
- listOfHuman.Add(obj.StudentMessage);
- break;
- case MessageOfObj.MessageOfObjOneofCase.TrickerMessage:
- if (!humanOrButcher && obj.TrickerMessage.PlayerId == playerID)
- {
- butcher = obj.TrickerMessage;
- }
- listOfButcher.Add(obj.TrickerMessage);
- break;
- case MessageOfObj.MessageOfObjOneofCase.PropMessage:
- listOfProp.Add(obj.PropMessage);
- break;
- case MessageOfObj.MessageOfObjOneofCase.BombedBulletMessage:
- listOfBombedBullet.Add(obj.BombedBulletMessage);
- break;
- case MessageOfObj.MessageOfObjOneofCase.BulletMessage:
- listOfBullet.Add(obj.BulletMessage);
- break;
- }
- }
- GetMap(content.MapMessage);
- listOfAll.Add(content.AllMessage);
- break;
- case GameState.GameRunning:
- foreach (var obj in content.ObjMessage)
- {
- switch (obj.MessageOfObjCase)
- {
- case MessageOfObj.MessageOfObjOneofCase.StudentMessage:
- if (humanOrButcher && obj.StudentMessage.PlayerId == playerID)
- {
- human = obj.StudentMessage;
- }
- listOfHuman.Add(obj.StudentMessage);
- break;
- case MessageOfObj.MessageOfObjOneofCase.TrickerMessage:
- if (!humanOrButcher && obj.TrickerMessage.PlayerId == playerID)
- {
- butcher = obj.TrickerMessage;
- }
- listOfButcher.Add(obj.TrickerMessage);
- break;
- case MessageOfObj.MessageOfObjOneofCase.PropMessage:
- listOfProp.Add(obj.PropMessage);
- break;
- case MessageOfObj.MessageOfObjOneofCase.BombedBulletMessage:
- listOfBombedBullet.Add(obj.BombedBulletMessage);
- break;
- case MessageOfObj.MessageOfObjOneofCase.BulletMessage:
- listOfBullet.Add(obj.BulletMessage);
- break;
- }
- }
- listOfAll.Add(content.AllMessage);
- break;
-
- case GameState.GameEnd:
- foreach (var obj in content.ObjMessage)
- {
- switch (obj.MessageOfObjCase)
- {
- case MessageOfObj.MessageOfObjOneofCase.StudentMessage:
- listOfHuman.Add(obj.StudentMessage);
- break;
- case MessageOfObj.MessageOfObjOneofCase.TrickerMessage:
- listOfButcher.Add(obj.TrickerMessage);
- break;
- case MessageOfObj.MessageOfObjOneofCase.PropMessage:
- listOfProp.Add(obj.PropMessage);
- break;
- case MessageOfObj.MessageOfObjOneofCase.BombedBulletMessage:
- listOfBombedBullet.Add(obj.BombedBulletMessage);
- break;
- case MessageOfObj.MessageOfObjOneofCase.BulletMessage:
- listOfBullet.Add(obj.BulletMessage);
- break;
- }
- }
- listOfAll.Add(content.AllMessage);
- break;
- }
- }
- if (responseStream == null)
- {
- throw new Exception("Unconnected");
- }
- }
- }
- catch (Exception ex)
- {
- ErrorDisplayer error = new("Error: " + ex.ToString());
- error.Show();
- }
- }
-
- //待修改
- private bool CanSee(MessageOfStudent msg)
- {
- if (msg.State == PlayerState.Quit)
- return false;
- //if (playerID >= 2022 || teamID >= 2022)
- // return true;
- if (humanOrButcher && human != null)
- {
- if (human.Guid == msg.Guid) // 自己能看见自己
- return true;
- }
- if (msg.Place == PlaceType.Grass || msg.Place == PlaceType.Gate || msg.Place == PlaceType.HiddenGate)
- return false;
- if (msg.Place == PlaceType.Land || msg.Place == PlaceType.Classroom)
- return true;
- if (humanOrButcher && human != null)
- {
- if (msg.Place != human.Place)
- return false;
- }
- else if (!humanOrButcher && butcher != null)
- {
- if (msg.Place != butcher.Place)
- return false;
- }
- return true;
- }
-
- private bool CanSee(MessageOfTricker msg)
- {
- // if (playerID >= 2022 || teamID >= 2022)
- // return true;
- if (!humanOrButcher && butcher != null)
- {
- if (butcher.Guid == msg.Guid) // 自己能看见自己
- return true;
- }
- if (msg.Place == PlaceType.Grass || msg.Place == PlaceType.Gate || msg.Place == PlaceType.HiddenGate)
- return false;
- if (msg.Place == PlaceType.Land || msg.Place == PlaceType.Classroom)
- return true;
- if (humanOrButcher && human != null)
- {
- if (msg.Place != human.Place)
- return false;
- }
- else if (!humanOrButcher && butcher != null)
- {
- if (msg.Place != butcher.Place)
- return false;
- }
- return true;
- }
-
- private bool CanSee(MessageOfProp msg)
- {
- if (msg.Place == PlaceType.Land)
- return true;
- if (humanOrButcher && human != null)
- {
- if (msg.Place != human.Place)
- return false;
- }
- else if (!humanOrButcher && butcher != null)
- {
- if (msg.Place != butcher.Place)
- return false;
- }
- return true;
- }
-
- private bool CanSee(MessageOfBullet msg)
- {
- if (msg.Place == PlaceType.Land)
- return true;
- if (humanOrButcher && human != null)
- {
- if (msg.Place != human.Place)
- return false;
- }
- else if (!humanOrButcher && butcher != null)
- {
- if (msg.Place != butcher.Place)
- return false;
- }
- return true;
- }
-
- private void Refresh(object? sender, EventArgs e) // 已按照3.5版proto更新信息,circumstance栏未更新 log未更新
- {
- // Bonus();
- if (WindowState == WindowState.Maximized)
- MaxButton.Content = "❐";
- else
- MaxButton.Content = "🗖";
- if (StatusBarsOfSurvivor != null)
- for (int i = 4; i < 8; i++)
- {
- StatusBarsOfSurvivor[i - 4].SetFontSize(12 * UpperLayerOfMap.ActualHeight / 650);
- }
- if (StatusBarsOfHunter != null)
- StatusBarsOfHunter.SetFontSize(12 * UpperLayerOfMap.ActualHeight / 650);
- if (StatusBarsOfCircumstance != null)
- StatusBarsOfCircumstance.SetFontSize(12 * UpperLayerOfMap.ActualHeight / 650);
- // 完成窗口信息更新
-
- if (!isClientStocked)
- {
- unit = Math.Sqrt(UpperLayerOfMap.ActualHeight * UpperLayerOfMap.ActualWidth) / 50;
- unitHeight = UpperLayerOfMap.ActualHeight / 50;
- unitWidth = UpperLayerOfMap.ActualWidth / 50;
- try
- {
- // if (log != null)
- //{
- // string temp = "";
- // for (int i = 0; i < dataDict[GameObjType.Character].Count; i++)
- // {
- // temp += Convert.ToString(dataDict[GameObjType.Character][i].MessageOfCharacter.TeamID) + "\n";
- // }
- // log.Content = temp;
- // }
- UpperLayerOfMap.Children.Clear();
- // if ((communicator == null || !communicator.Client.IsConnected) && !isPlaybackMode)
- //{
- // UnderLayerOfMap.Children.Clear();
- // throw new Exception("Client is unconnected.");
- // }
- // else
- //{
- lock (drawPicLock) // 加锁是必要的,画图操作和接收信息操作不能同时进行
- {
- foreach (var data in listOfAll)
- {
- StatusBarsOfCircumstance.SetValue(data);
- }
- if (!hasDrawed && mapFlag)
- DrawMap();
- foreach (var data in listOfHuman)
- {
- StatusBarsOfSurvivor[data.PlayerId].SetValue(data);
- if (CanSee(data))
- {
- Ellipse icon = new()
- {
- Width = unitWidth,
- Height = unitHeight,
- HorizontalAlignment = HorizontalAlignment.Left,
- VerticalAlignment = VerticalAlignment.Top,
- Margin = new Thickness(data.Y * unitWidth / 1000.0 - unitWidth / 2, data.X * unitHeight / 1000.0 - unitHeight / 2, 0, 0),
- Fill = Brushes.BlueViolet,
- };
- UpperLayerOfMap.Children.Add(icon);
- }
- }
- foreach (var data in listOfButcher)
- {
- StatusBarsOfHunter.SetValue(data);
- if (CanSee(data))
- {
- Ellipse icon = new()
- {
- Width = unitWidth,
- Height = unitHeight,
- HorizontalAlignment = HorizontalAlignment.Left,
- VerticalAlignment = VerticalAlignment.Top,
- Margin = new Thickness(data.Y * unitWidth / 1000.0 - unitWidth / 2, data.X * unitHeight / 1000.0 - unitHeight / 2, 0, 0),
- Fill = Brushes.Black,
- };
- UpperLayerOfMap.Children.Add(icon);
- }
- }
- foreach (var data in listOfProp)
- {
- if (CanSee(data))
- {
- switch (data.Type)
- {
- case PropType.Ptype1:
- DrawProp(data, "🔧");
- break;
- case PropType.Ptype2:
- DrawProp(data, "🛡");
- break;
- case PropType.Ptype3:
- DrawProp(data, "♥");
- break;
- case PropType.Ptype4:
- DrawProp(data, "⛸");
- break;
- default:
- DrawProp(data, "");
- break;
- }
- }
- }
- foreach (var data in listOfBullet)
- {
- if (CanSee(data))
- {
- Ellipse icon = new()
- {
- Width = 10,
- Height = 10,
- HorizontalAlignment = HorizontalAlignment.Left,
- VerticalAlignment = VerticalAlignment.Top,
- Margin = new Thickness(data.Y * unitWidth / 1000.0 - unitWidth / 2, data.X * unitHeight / 1000.0 - unitHeight / 2, 0, 0),
- Fill = Brushes.Red
- };
- UpperLayerOfMap.Children.Add(icon);
- }
- }
- foreach (var data in listOfBombedBullet)
- {
- switch (data.Type)
- {
- case BulletType.FastBullet:
- {
- Ellipse icon = new();
- double bombRange = data.BombRange / 1000;
- icon.Width = bombRange * unitWidth;
- icon.Height = bombRange * unitHeight;
- icon.HorizontalAlignment = HorizontalAlignment.Left;
- icon.VerticalAlignment = VerticalAlignment.Top;
- icon.Margin = new Thickness(data.Y * unitWidth / 1000.0 - bombRange * unitWidth / 2, data.X * unitHeight / 1000.0 - bombRange * unitHeight / 2, 0, 0);
- icon.Fill = Brushes.Red;
- UpperLayerOfMap.Children.Add(icon);
- break;
- }
- case BulletType.AtomBomb:
- {
- Ellipse icon = new Ellipse();
- double bombRange = data.BombRange / 1000;
- icon.Width = bombRange * unitWidth;
- icon.Height = bombRange * unitHeight;
- icon.HorizontalAlignment = HorizontalAlignment.Left;
- icon.VerticalAlignment = VerticalAlignment.Top;
- icon.Margin = new Thickness(data.Y * unitWidth / 1000.0 - bombRange * unitWidth / 2, data.X * unitHeight / 1000.0 - bombRange * unitHeight / 2, 0, 0);
- icon.Fill = Brushes.Red;
- UpperLayerOfMap.Children.Add(icon);
- break;
- }
- case BulletType.OrdinaryBullet:
- {
- Ellipse icon = new Ellipse();
- double bombRange = data.BombRange / 1000;
- icon.Width = bombRange * unitWidth;
- icon.Height = bombRange * unitHeight;
- icon.HorizontalAlignment = HorizontalAlignment.Left;
- icon.VerticalAlignment = VerticalAlignment.Top;
- icon.Margin = new Thickness(data.Y * unitWidth / 1000.0 - bombRange * unitWidth / 2, data.X * unitHeight / 1000.0 - bombRange * unitHeight / 2, 0, 0);
- icon.Fill = Brushes.Red;
- UpperLayerOfMap.Children.Add(icon);
- break;
- }
- case BulletType.LineBullet:
- {
- double bombRange = data.BombRange / 1000;
- DrawLaser(new Point(data.Y * unitWidth / 1000.0, data.X * unitHeight / 1000.0), -data.FacingDirection + Math.PI / 2, bombRange * unitHeight, 0.5 * unitWidth);
- break;
- }
- default:
- break;
- }
- }
- //}
- ZoomMap();
- }
- }
- catch (Exception exc)
- {
- ErrorDisplayer error = new("Error: " + exc.ToString());
- error.Show();
- isClientStocked = true;
- PorC.Content = "▶";
- }
- }
- counter++;
- }
-
- // 键盘控制,未完善
- private void KeyBoardControl(object sender, KeyEventArgs e)
- {
- if (!isPlaybackMode)
- {
- switch (e.Key)
- {
- case Key.W:
- case Key.NumPad8:
- MoveMsg msgW = new()
- {
- PlayerId = playerID,
- TimeInMilliseconds = 50,
- Angle = Math.PI
- };
- client.Move(msgW);
- break;
- case Key.NumPad2:
- case Key.S:
- MoveMsg msgS = new()
- {
- PlayerId = playerID,
- TimeInMilliseconds = 50,
- Angle = 0
- };
- client.Move(msgS);
- break;
- case Key.D:
- case Key.NumPad6:
- MoveMsg msgD = new()
- {
- PlayerId = playerID,
- TimeInMilliseconds = 50,
- Angle = Math.PI / 2
- };
- client.Move(msgD);
- break;
- case Key.A:
- case Key.NumPad4:
- MoveMsg msgA = new()
- {
- PlayerId = playerID,
- TimeInMilliseconds = 50,
- Angle = 3 * Math.PI / 2
- };
- client.Move(msgA);
- break;
- case Key.J:
- AttackMsg msgJ = new()
- {
- PlayerId = playerID,
- Angle = Math.PI
- };
- client.Attack(msgJ);
- break;
- case Key.F:
- PropMsg msgF = new()
- {
- PlayerId = playerID,
- };
- client.PickProp(msgF);
- break;
- case Key.E:
- PropMsg msgE = new()
- {
- PlayerId = playerID,
- };
- client.UseProp(msgE);
- break;
- case Key.Q:
- SkillMsg msgQ = new()
- {
- PlayerId = playerID,
- };
- client.UseSkill(msgQ);
- break;
- case Key.K:
- IDMsg msgK = new()
- {
- PlayerId = playerID,
- };
- client.StartLearning(msgK);
- break;
- default:
- break;
- }
- }
- }
-
- //鼠标双击
- private void Attack(object sender, RoutedEventArgs e)
- {
- if (!isPlaybackMode)
- {
- if (humanOrButcher&&human != null)
- {
- AttackMsg msgJ = new()
- {
- PlayerId = playerID
- };
- double mouseY = Mouse.GetPosition(UpperLayerOfMap).X * 1000 / unitWidth;
- double mouseX = Mouse.GetPosition(UpperLayerOfMap).Y * 1000 / unitHeight;
- msgJ.Angle = Math.Atan2(mouseY - human.Y, mouseX - human.X);
- client.Attack(msgJ);
- }
- if (!humanOrButcher && butcher != null)
- {
- AttackMsg msgJ = new()
- {
- PlayerId = playerID
- };
- double mouseY = Mouse.GetPosition(UpperLayerOfMap).X * 1000 / unitWidth;
- double mouseX = Mouse.GetPosition(UpperLayerOfMap).Y * 1000 / unitHeight;
- msgJ.Angle = Math.Atan2(mouseY - butcher.Y, mouseX - butcher.X);
- client.Attack(msgJ);
- }
- }
- }
-
- // 之后需要修改,现在只具有修改按钮形状的功能,并不能实现暂停/继续
- private void ClickToPauseOrContinue(object sender, RoutedEventArgs e)
- {
- if (!isClientStocked)
- {
- isClientStocked = true;
- PorC.Content = "▶";
- }
- else
- {
- isClientStocked = false;
- PorC.Content = "⏸";
- }
- }
- // 未复现
- private void ClickToConnect(object sender, RoutedEventArgs e)
- {
- }
-
- // 窗口最大化、关闭、最小化、拖拽
- private void ClickToMaxmize(object sender, RoutedEventArgs e)
- {
- if (WindowState != WindowState.Maximized)
- WindowState = WindowState.Maximized;
- else
- WindowState = WindowState.Normal;
- }
- private void ClickToClose(object sender, RoutedEventArgs e)
- {
- Application.Current.Shutdown();
- }
- private void ClickToMinimize(object sender, RoutedEventArgs e)
- {
- WindowState = WindowState.Minimized;
- }
- private void DragWindow(object sender, RoutedEventArgs e)
- {
- DragMove();
- }
-
- // 寻求帮助、访问EESAST(部分功能未复原)
- private void ClickForHelp(object sender, RoutedEventArgs e)
- {
- PleaseWait();
- }
- private void ClickToVisitEESAST(object sender, RoutedEventArgs e)
- {
- try
- {
- _ = Process.Start("C:\\Program Files (x86)\\Microsoft\\Edge\\Application\\msedge.exe", "https://eesast.com");
- }
- catch (Exception exc)
- {
- // ErrorDisplayer error = new("发生错误。以下是系统报告\n" + exc.ToString());
- // error.Show();
- }
- }
-
- // 配置连接(未复原)、我的AI(THUAI5未实现)、获取更新、天梯信息(可能需要网站协助)
- private void ClickToSetConnect(object sender, RoutedEventArgs e)
- {
- // ConnectRegister crg = new();
- // crg.Show();
- }
- private void ClickToEnterVS(object sender, RoutedEventArgs e)
- {
- // try
- //{
- // if (!File.Exists("VSRoute.txt"))
- // {
- // File.Create("VSRoute.txt");
- // Exception ex = new("没有路径存储文件,已为您创建。请将VS路径输入该文件,并重新操作。");
- // throw ex;
- // }//创建路径文件
- // using StreamReader sr = new("VSRoute.txt");
- // _ = Process.Start(sr.ReadLine());
- // }
- // catch (Exception exc)
- //{
- // ErrorDisplayer error = new("发生错误。以下是系统报告:\n" + exc.ToString());
- // error.Show();
- // }
- PleaseWait();
- }
- private void ClickForUpdate(object sender, RoutedEventArgs e)
- {
- PleaseWait();
- }
- private void ClickToCheckLadder(object sender, RoutedEventArgs e)
- {
- PleaseWait();
- }
-
- // 敬请期待函数
- private void PleaseWait()
- {
- try
- {
- throw new Exception("敬请期待");
- }
- catch (Exception exc)
- {
- // ErrorDisplayer error = new(exc.Message);
- // error.Show();
- }
- }
-
- // 以下为Mainwindow自定义属性
- private readonly DispatcherTimer timer; // 定时器
- private long counter; // 预留的取时间变量
- AvailableService.AvailableServiceClient client;
- AsyncServerStreamingCall<MessageToClient>? responseStream;
- private StatusBarOfSurvivor[] StatusBarsOfSurvivor;
- private StatusBarOfHunter StatusBarsOfHunter;
- private StatusBarOfCircumstance StatusBarsOfCircumstance;
-
- private bool isClientStocked;
- private bool isPlaybackMode;
-
- private long playerID;
- private PlayerType playerType;
-
- private double unit;
- private double unitHeight;
- private double unitWidth;
- private readonly Rectangle[,] mapPatches = new Rectangle[50, 50];
-
- private List<MessageOfProp> listOfProp;
- private List<MessageOfStudent> listOfHuman;
- private List<MessageOfTricker> listOfButcher;
- private List<MessageOfBullet> listOfBullet;
- private List<MessageOfBombedBullet> listOfBombedBullet;
- private List<MessageOfAll> listOfAll;
- private object drawPicLock = new object();
- private MessageOfStudent? human = null;
- private MessageOfTricker? butcher = null;
- private bool humanOrButcher;//true for human
-
- private bool bonusflag;
- private bool mapFlag = false;
- private bool hasDrawed = false;
- public int[,] defaultMap = new int[,] {{ 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6 },
- { 6, 0, 0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