修复部分设置未生效的bug

This commit is contained in:
ZouJin 2023-03-11 01:37:45 +11:00
parent fb2a6ce768
commit 5e06a085d6
2 changed files with 11 additions and 3 deletions

View File

@ -186,7 +186,11 @@ namespace VPet_Simulator.Windows
public int PressLength
{
get => presslength;
set => this["gameconfig"].SetInt("presslength", value);
set
{
presslength = value;
this["gameconfig"].SetInt("presslength", value);
}
}
/// <summary>
/// 互动周期
@ -194,7 +198,11 @@ namespace VPet_Simulator.Windows
public int InteractionCycle
{
get => intercycle;
set => this["gameconfig"].SetInt("intercycle", value);
set
{
intercycle = value;
this["gameconfig"].SetInt("intercycle", value);
}
}
/// <summary>
/// 计算间隔

View File

@ -81,7 +81,7 @@ namespace VPet_Simulator.Windows
byte[] byteData = Encoding.UTF8.GetBytes(sb.ToString());
int length = byteData.Length;
request.ContentLength = length;
request.Timeout = 500000;
request.Timeout = 200000;
using (Stream writer = request.GetRequestStream())
{
writer.Write(byteData, 0, length);