?? gameconfig.pas
字號:
procedure CheckBoxHighLevelGroupFixExpClick(Sender: TObject);
procedure SpinEditLimitExpLevelChange(Sender: TObject);
procedure SpinEditLimitExpValueChange(Sender: TObject);
procedure SpinEditLimitMinOrderLevelChange(Sender: TObject);
private
boOpened: Boolean;
boModValued: Boolean;
procedure ModValue();
procedure uModValue();
procedure RefGameSpeedConf();
procedure RefCharStatusConf();
procedure RefGameVarConf();
{ Private declarations }
public
procedure Open();
{ Public declarations }
end;
var
frmGameConfig: TfrmGameConfig;
implementation
uses M2Share, HUtil32, SDK, ActionSpeedConfig;
{$R *.dfm}
{ TfrmGameConfig }
procedure TfrmGameConfig.FormCreate(Sender: TObject);
var
I: Integer;
begin
ComboBoxLineNoticeColor.Items.Add('紅色');
ComboBoxLineNoticeColor.Items.Add('綠色');
ComboBoxLineNoticeColor.Items.Add('藍色');
GridLevelExp.ColWidths[0] := 30;
GridLevelExp.ColWidths[1] := 100;
GridLevelExp.Cells[0, 0] := '等級';
GridLevelExp.Cells[1, 0] := '經驗值';
for I := 1 to GridLevelExp.RowCount - 1 do begin
GridLevelExp.Cells[0, I] := IntToStr(I);
end;
ComboBoxLevelExp.AddItem('原始經驗值', TObject(s_OldLevelExp));
ComboBoxLevelExp.AddItem('標準經驗值', TObject(s_StdLevelExp));
ComboBoxLevelExp.AddItem('當前1/2倍經驗', TObject(s_2Mult));
ComboBoxLevelExp.AddItem('當前1/5倍經驗', TObject(s_5Mult));
ComboBoxLevelExp.AddItem('當前1/8倍經驗', TObject(s_8Mult));
ComboBoxLevelExp.AddItem('當前1/10倍經驗', TObject(s_10Mult));
ComboBoxLevelExp.AddItem('當前1/20倍經驗', TObject(s_20Mult));
ComboBoxLevelExp.AddItem('當前1/30倍經驗', TObject(s_30Mult));
ComboBoxLevelExp.AddItem('當前1/40倍經驗', TObject(s_40Mult));
ComboBoxLevelExp.AddItem('當前1/50倍經驗', TObject(s_50Mult));
ComboBoxLevelExp.AddItem('當前1/60倍經驗', TObject(s_60Mult));
ComboBoxLevelExp.AddItem('當前1/70倍經驗', TObject(s_70Mult));
ComboBoxLevelExp.AddItem('當前1/80倍經驗', TObject(s_80Mult));
ComboBoxLevelExp.AddItem('當前1/90倍經驗', TObject(s_90Mult));
ComboBoxLevelExp.AddItem('當前1/100倍經驗', TObject(s_100Mult));
ComboBoxLevelExp.AddItem('當前1/150倍經驗', TObject(s_150Mult));
ComboBoxLevelExp.AddItem('當前1/200倍經驗', TObject(s_200Mult));
ComboBoxLevelExp.AddItem('當前1/250倍經驗', TObject(s_250Mult));
ComboBoxLevelExp.AddItem('當前1/300倍經驗', TObject(s_300Mult));
EditSoftVersionDate.Hint := '客戶端版本日期設置,此參數默認為 20020522,此版本日期必須與客戶端相匹配,否則在進入游戲時將提示版本不正確';
EditConsoleShowUserCountTime.Hint := '程序控制臺上顯示當前在線人數間隔時間,此參數默認為 10分鐘。';
EditShowLineNoticeTime.Hint := '游戲中顯示公告信息的間隔時間,此參數默認為 300秒。';
ComboBoxLineNoticeColor.Hint := '游戲中顯示公告信息的文字顏色,此參數默認為 藍色。';
EditLineNoticePreFix.Hint := '游戲中顯示公告信息的文字行前綴文字。';
EditHitIntervalTime.Hint := '游戲中人物二次攻擊間隔時間,此參數默認為 900毫秒。';
EditMagicHitIntervalTime.Hint := '游戲中人物二次魔法攻擊間隔時間,此參數默認為 800毫秒。';
EditRunIntervalTime.Hint := '游戲中人物二次跑動間隔時間,此參數默認為 600毫秒。';
EditWalkIntervalTime.Hint := '游戲中人物二次走動間隔時間,此參數默認為 600毫秒。';
EditTurnIntervalTime.Hint := '游戲中人物二次變方向間隔時間,此參數默認為 600毫秒。';
EditItemSpeedTime.Hint := '裝備加速屬性速度控制,數字越小控制越嚴,此參數默認為 50毫秒。';
EditStruckTime.Hint := '人物被攻擊后彎腰停留時間控制,此參數默認為 100毫秒。';
CheckBoxDisableStruck.Hint := '人物在被攻擊后是否顯示彎腰動作。';
GridLevelExp.Hint := '修改的經驗在點擊保存按鈕后生效。';
ComboBoxLevelExp.Hint := '選擇的經驗計劃,立即生效。';
EditKillMonExpMultiple.Hint := '人物殺怪物所得經驗值倍,此參數默認為 1,此經驗值以怪物數據庫里的經驗值為基準。';
CheckBoxHighLevelKillMonFixExp.Hint := '高等級人物殺怪經驗是否保持不變,此參數默認為關閉(不打鉤)。';
EditRepairDoorPrice.Hint := '維修城門所需費用,此參數默認為 2000000金幣。';
EditRepairWallPrice.Hint := '維修城墻所需費用,此參數默認為 500000金幣。';
EditHireArcherPrice.Hint := '雇用弓箭手所需費用,此參數默認為 300000金幣。';
EditHireGuardPrice.Hint := '維修守衛所需費用,此參數默認為 300000金幣。';
EditCastleGoldMax.Hint := '城堡內最高可存金幣數量,此參數默認為 10000000金幣。';
EditCastleOneDayGold.Hint := '城堡一天內最高收入上限,此參數默認為 2000000金幣。';
EditCastleHomeMap.Hint := '行會回城點默認所在地圖號,此參數默認地圖號為 3,以城堡配置文件中的參數為準';
EditCastleHomeX.Hint := '行會回城點默認所在地圖座標X,此參數默認座標為 644,以城堡配置文件中的參數為準';
EditCastleHomeY.Hint := '行會回城點默認所在地圖座標Y,此參數默認座標為 290,以城堡配置文件中的參數為準';
EditCastleName.Hint := '城堡默認的名稱,以城堡配置文件中的參數為準。';
EditWarRangeX.Hint := '攻城區域默認座標X范圍大小,此參數默認為 100,以城堡配置文件中的參數為準';
EditWarRangeY.Hint := '攻城區域默認座標Y范圍大小,此參數默認為 100,以城堡配置文件中的參數為準';
CheckBoxGetAllNpcTax.Hint := '是否收取所有交易NPC的交易稅,此參數默認為關閉(不打鉤)。';
EditTaxRate.Hint := '交易稅率,此參為默認為 5,也就是 0.05%。';
{$IF SoftVersion = VERDEMO}
Caption := '游戲參數[演示版本,所有設置調整有效,但不能保存]'
{$IFEND}
end;
procedure TfrmGameConfig.GameConfigControlChanging(Sender: TObject;
var AllowChange: Boolean);
begin
if boModValued then begin
if Application.MessageBox('參數設置已經被修改,是否確認不保存修改的設置?', '確認信息', MB_YESNO + MB_ICONQUESTION) = IDYES then begin
uModValue
end else AllowChange := False;
end;
end;
procedure TfrmGameConfig.ModValue;
begin
boModValued := True;
ButtonGameSpeedSave.Enabled := True;
ButtonGeneralSave.Enabled := True;
ButtonExpSave.Enabled := True;
ButtonCastleSave.Enabled := True;
ButtonOptionSave0.Enabled := True;
ButtonOptionSave.Enabled := True;
ButtonOptionSave2.Enabled := True;
ButtonOptionSave3.Enabled := True;
ButtonTimeSave.Enabled := True;
ButtonPriceSave.Enabled := True;
ButtonMsgSave.Enabled := True;
ButtonMsgColorSave.Enabled := True;
ButtonHumanDieSave.Enabled := True;
ButtonCharStatusSave.Enabled := True;
end;
procedure TfrmGameConfig.uModValue;
begin
boModValued := False;
ButtonGameSpeedSave.Enabled := False;
ButtonGeneralSave.Enabled := False;
ButtonExpSave.Enabled := False;
ButtonCastleSave.Enabled := False;
ButtonOptionSave0.Enabled := False;
ButtonOptionSave.Enabled := False;
ButtonOptionSave2.Enabled := False;
ButtonOptionSave3.Enabled := False;
ButtonTimeSave.Enabled := False;
ButtonPriceSave.Enabled := False;
ButtonMsgSave.Enabled := False;
ButtonMsgColorSave.Enabled := False;
ButtonHumanDieSave.Enabled := False;
ButtonCharStatusSave.Enabled := False;
end;
procedure TfrmGameConfig.Open;
var
I: Integer;
begin
boOpened := False;
uModValue();
RefGameSpeedConf();
EditKillMonExpMultiple.Value := g_Config.dwKillMonExpMultiple;
CheckBoxHighLevelKillMonFixExp.Checked := g_Config.boHighLevelKillMonFixExp;
CheckBoxHighLevelGroupFixExp.Checked := g_Config.boHighLevelGroupFixExp;
EditRepairDoorPrice.Value := g_Config.nRepairDoorPrice;
EditRepairWallPrice.Value := g_Config.nRepairWallPrice;
EditHireArcherPrice.Value := g_Config.nHireArcherPrice;
EditHireGuardPrice.Value := g_Config.nHireGuardPrice;
EditCastleGoldMax.Value := g_Config.nCastleGoldMax;
EditCastleOneDayGold.Value := g_Config.nCastleOneDayGold;
EditCastleHomeMap.Text := g_Config.sCastleHomeMap;
EditCastleHomeX.Value := g_Config.nCastleHomeX;
EditCastleHomeY.Value := g_Config.nCastleHomeY;
EditCastleName.Text := g_Config.sCASTLENAME;
EditWarRangeX.Value := g_Config.nCastleWarRangeX;
EditWarRangeY.Value := g_Config.nCastleWarRangeY;
CheckBoxGetAllNpcTax.Checked := g_Config.boGetAllNpcTax;
EditTaxRate.Value := g_Config.nCastleTaxRate;
for I := 1 to GridLevelExp.RowCount - 1 do begin
GridLevelExp.Cells[1, I] := IntToStr(g_Config.dwNeedExps[I]);
end;
GroupBoxLevelExp.Caption := Format('升級經驗(最高有效等級%d)', [MAXUPLEVEL]);
(*
{$IF SoftVersion = VERFREE}
GroupBoxLevelExp.Caption:='升級經驗(最高有效等級255)';
{$ELSEIF SoftVersion = VERSTD}
GroupBoxLevelExp.Caption:='升級經驗(最高有效等級350)';
{$ELSEIF SoftVersion = VEROEM}
GroupBoxLevelExp.Caption:='升級經驗(最高有效等級350)';
{$ELSEIF SoftVersion = VERPRO}
GroupBoxLevelExp.Caption:='升級經驗(最高有效等級450)';
{$ELSEIF SoftVersion = VERENT}
GroupBoxLevelExp.Caption:='升級經驗(最高有效等級500)';
{$IFEND}
*)
CheckBoxDisHumRun.Checked := not g_Config.boDiableHumanRun;
CheckBoxRunHum.Checked := g_Config.boRUNHUMAN;
CheckBoxRunMon.Checked := g_Config.boRUNMON;
CheckBoxRunNpc.Checked := g_Config.boRunNpc;
CheckBoxRunGuard.Checked := g_Config.boRunGuard;
CheckBoxWarDisHumRun.Checked := g_Config.boWarDisHumRun;
CheckBoxGMRunAll.Checked := g_Config.boGMRunAll;
CheckBoxSafeArea.Checked := g_Config.boSafeAreaLimited;
CheckBoxDisHumRunClick(CheckBoxDisHumRun);
EditSafeZoneSize.Value := g_Config.nSafeZoneSize;
EditStartPointSize.Value := g_Config.nStartPointSize;
EditGroupMembersMax.Value := g_Config.nGroupMembersMax;
EditRedHomeMap.Text := g_Config.sRedHomeMap;
EditRedHomeX.Value := g_Config.nRedHomeX;
EditRedHomeY.Value := g_Config.nRedHomeY;
EditRedDieHomeMap.Text := g_Config.sRedDieHomeMap;
EditRedDieHomeX.Value := g_Config.nRedDieHomeX;
EditRedDieHomeY.Value := g_Config.nRedDieHomeY;
EditHomeMap.Text := g_Config.sHomeMap;
EditHomeX.Value := g_Config.nHomeX;
EditHomeY.Value := g_Config.nHomeY;
EditDecPkPointTime.Value := g_Config.dwDecPkPointTime div 1000;
EditDecPkPointCount.Value := g_Config.nDecPkPointCount;
EditPKFlagTime.Value := g_Config.dwPKFlagTime div 1000;
EditKillHumanAddPKPoint.Value := g_Config.nKillHumanAddPKPoint;
EditPosionDecHealthTime.Value := g_Config.dwPosionDecHealthTime;
EditPosionDamagarmor.Value := g_Config.nPosionDamagarmor;
CheckBoxTestServer.Checked := g_Config.boTestServer;
CheckBoxServiceMode.Checked := g_Config.boServiceMode;
CheckBoxVentureMode.Checked := g_Config.boVentureServer;
CheckBoxNonPKMode.Checked := g_Config.boNonPKServer;
EditStartPermission.Value := g_Config.nStartPermission;
EditTestLevel.Value := g_Config.nTestLevel;
EditTestGold.Value := g_Config.nTestGold;
EditTestUserLimit.Value := g_Config.nTestUserLimit;
EditUserFull.Value := g_Config.nUserFull;
CheckBoxTestServerClick(CheckBoxTestServer);
CheckBoxKillHumanWinLevel.Checked := g_Config.boKillHumanWinLevel;
CheckBoxKilledLostLevel.Checked := g_Config.boKilledLostLevel;
CheckBoxKillHumanWinExp.Checked := g_Config.boKillHumanWinExp;
CheckBoxKilledLostExp.Checked := g_Config.boKilledLostExp;
EditKillHumanWinLevel.Value := g_Config.nKillHumanWinLevel;
EditKilledLostLevel.Value := g_Config.nKilledLostLevel;
EditKillHumanWinExp.Value := g_Config.nKillHumanWinExp;
EditKillHumanLostExp.Value := g_Config.nKillHumanLostExp;
EditHumanLevelDiffer.Value := g_Config.nHumanLevelDiffer;
CheckBoxKillHumanWinLevelClick(CheckBoxKillHumanWinLevel);
CheckBoxKilledLostLevelClick(CheckBoxKilledLostLevel);
CheckBoxKillHumanWinExpClick(CheckBoxKillHumanWinExp);
CheckBoxKilledLostExpClick(CheckBoxKilledLostExp);
EditHumanMaxGold.Value := g_Config.nHumanMaxGold;
EditHumanTryModeMaxGold.Value := g_Config.nHumanTryModeMaxGold;
EditTryModeLevel.Value := g_Config.nTryModeLevel;
CheckBoxTryModeUseStorage.Checked := g_Config.boTryModeUseStorage;
EditSayMsgMaxLen.Value := g_Config.nSayMsgMaxLen;
EditSayRedMsgMaxLen.Value := g_Config.nSayRedMsgMaxLen;
EditCanShoutMsgLevel.Value := g_Config.nCanShoutMsgLevel;
CheckBoxShutRedMsgShowGMName.Checked := g_Config.boShutRedMsgShowGMName;
CheckBoxShowPreFixMsg.Checked := g_Config.boShowPreFixMsg;
EditGMRedMsgCmd.Text := g_GMRedMsgCmd;
EditStartCastleWarDays.Value := g_Config.nStartCastleWarDays;
EditStartCastlewarTime.Value := g_Config.nStartCastlewarTime;
EditShowCastleWarEndMsgTime.Value := g_Config.dwShowCastleWarEndMsgTime div (60 * 1000);
EditCastleWarTime.Value := g_Config.dwCastleWarTime div (60 * 1000);
EditGetCastleTime.Value := g_Config.dwGetCastleTime div (60 * 1000);
EditGuildWarTime.Value := g_Config.dwGuildWarTime div (60 * 1000);
EditMakeGhostTime.Value := g_Config.dwMakeGhostTime div 1000;
EditClearDropOnFloorItemTime.Value := g_Config.dwClearDropOnFloorItemTime div 1000;
EditSaveHumanRcdTime.Value := g_Config.dwSaveHumanRcdTime div (60 * 1000);
EditHumanFreeDelayTime.Value := g_Config.dwHumanFreeDelayTime div (60 * 1000);
EditFloorItemCanPickUpTime.Value := g_Config.dwFloorItemCanPickUpTime div 1000;
EditBuildGuildPrice.Value := g_Config.nBuildGuildPrice;
EditGuildWarPrice.Value := g_Config.nGuildWarPrice;
EditMakeDurgPrice.Value := g_Config.nMakeDurgPrice;
EditTryDealTime.Value := g_Config.dwTryDealTime div 1000;
EditDealOKTime.Value := g_Config.dwDealOKTime div 1000;
EditCastleMemberPriceRate.Value := g_Config.nCastleMemberPriceRate;
EditHearMsgFColor.Value := g_Config.btHearMsgFColor;
EdittHearMsgBColor.Value := g_Config.btHearMsgBColor;
EditWhisperMsgFColor.Value := g_Config.btWhisperMsgFColor;
EditWhisperMsgBColor.Value := g_Config.btWhisperMsgBColor;
EditGMWhisperMsgFColor.Value := g_Config.btGMWhisperMsgFColor;
EditGMWhisperMsgBColor.Value := g_Config.btGMWhisperMsgBColor;
EditRedMsgFColor.Value := g_Config.btRedMsgFColor;
EditRedMsgBColor.Value := g_Config.btRedMsgBColor;
EditGreenMsgFColor.Value := g_Config.btGreenMsgFColor;
EditGreenMsgBColor.Value := g_Config.btGreenMsgBColor;
EditBlueMsgFColor.Value := g_Config.btBlueMsgFColor;
EditBlueMsgBColor.Value := g_Config.btBlueMsgBColor;
EditCryMsgFColor.Value := g_Config.btCryMsgFColor;
EditCryMsgBColor.Value := g_Config.btCryMsgBColor;
EditGuildMsgFColor.Value := g_Config.btGuildMsgFColor;
EditGuildMsgBColor.Value := g_Config.btGuildMsgBColor;
EditGroupMsgFColor.Value := g_Config.btGroupMsgFColor;
EditGroupMsgBColor.Value := g_Config.btGroupMsgBColor;
EditCustMsgFColor.Value := g_Config.btCustMsgFColor;
EditCustMsgBColor.Value := g_Config.btCustMsgBColor;
CheckBoxPKLevelProtect.Checked := g_Config.boPKLevelProtect;
EditPKProtectLevel.Value := g_Config.nPKProtectLevel;
EditRedPKProtectLevel.Value := g_Config.nRedPKProtectLevel;
CheckBoxPKLevelProtectClick(CheckBoxPKLevelProtect);
CheckBoxCanNotGetBackDeal.Checked := g_Config.boCanNotGetBackDeal;
CheckBoxDisableDeal.Checked := g_Config.boDisableDeal;
CheckBoxControlDropItem.Checked := g_Config.boControlDropItem;
CheckBoxIsSafeDisableDrop.Checked := g_Config.boInSafeDisableDrop;
EditCanDropPrice.Value := g_Config.nCanDropPrice;
EditCanDropGold.Value := g_Config.nCanDropGold;
EditSuperRepairPriceRate.Value := g_Config.nSuperRepairPriceRate;
EditRepairItemDecDura.Value := g_Config.nRepairItemDecDura;
CheckBoxKillByMonstDropUseItem.Checked := g_Config.boKillByMonstDropUseItem;
CheckBoxKillByHumanDropUseItem.Checked := g_Config.boKillByHumanDropUseItem;
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -