mirror of
https://bitbucket.org/grumdrig/pq.git
synced 2026-09-30 01:01:00 -06:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
95f5d66f97 | ||
|
|
4b16e8b7b9 | ||
|
|
73754959ac | ||
|
|
99314c4e0e | ||
|
|
e22fcdfa0e | ||
|
|
752f684fcc | ||
|
|
047dc7463c |
No files matched your search
@@ -105,7 +105,7 @@ object FrontForm: TFrontForm
|
|||||||
Height = 13
|
Height = 13
|
||||||
Align = alBottom
|
Align = alBottom
|
||||||
Alignment = taCenter
|
Alignment = taCenter
|
||||||
Caption = #169' 2002-2022 Eric Fredricksen - v6.4.2'
|
Caption = #169' 2002-2022 Eric Fredricksen - v6.4.4'
|
||||||
Color = clWhite
|
Color = clWhite
|
||||||
Font.Charset = DEFAULT_CHARSET
|
Font.Charset = DEFAULT_CHARSET
|
||||||
Font.Color = 11382189
|
Font.Color = 11382189
|
||||||
|
|||||||
@@ -831,23 +831,53 @@ end;
|
|||||||
|
|
||||||
procedure TMainForm.WinStat;
|
procedure TMainForm.WinStat;
|
||||||
var
|
var
|
||||||
i,t: Integer;
|
i: Integer;
|
||||||
function Square(x: Integer): Integer; begin Result := x * x; end;
|
t: Int64;
|
||||||
|
function Square(x: Int64): Int64; begin Result := x * x; end;
|
||||||
|
|
||||||
|
function Random64: Int64; overload;
|
||||||
|
begin
|
||||||
|
Int64Rec(Result).Hi := Random($3FFFFFFF);
|
||||||
|
Int64Rec(Result).Lo := Random($FFFFFFFF);
|
||||||
|
end;
|
||||||
|
|
||||||
|
function Random64(below: Int64): Int64; overload;
|
||||||
|
begin
|
||||||
|
Result := Random64 mod below;
|
||||||
|
end;
|
||||||
|
|
||||||
|
{
|
||||||
|
procedure TestRandom;
|
||||||
|
var
|
||||||
|
i, b: Integer;
|
||||||
|
c: Integer;
|
||||||
|
v: Int64;
|
||||||
|
begin
|
||||||
|
for b := 0 to 63 do begin
|
||||||
|
c := 0;
|
||||||
|
for i := 1 to 1000 do begin
|
||||||
|
v := Random64($0fffffffffffffff);
|
||||||
|
if ((v shr b) and 1) = 1 then Inc(c);
|
||||||
|
end;
|
||||||
|
OutputDebugString(PChar(IntToStr(b) + ' ' + IntToStr(c) + '\n'));
|
||||||
|
end
|
||||||
|
end;
|
||||||
|
}
|
||||||
|
|
||||||
begin
|
begin
|
||||||
|
// TestRandom;
|
||||||
|
|
||||||
if Odds(1,2)
|
if Odds(1,2)
|
||||||
then i := Random(Stats.Items.Count)
|
then i := Random(Stats.Items.Count)
|
||||||
else begin
|
else begin
|
||||||
// favor the best stat so it will tend to clump
|
// Favor the best stats so they will tend to clump
|
||||||
t := 0;
|
t := 0;
|
||||||
for i := 0 to 5 do Inc(t,Square(GetI(Stats,i)));
|
for i := 0 to 5 do Inc(t, Square(GetI(Stats,i)));
|
||||||
t := Random(t);
|
t := Random64(t);
|
||||||
if t < 0 then i := Random(Stats.Items.Count)
|
|
||||||
else begin
|
|
||||||
i := -1;
|
i := -1;
|
||||||
while t >= 0 do begin
|
while t >= 0 do begin
|
||||||
Inc(i);
|
Inc(i);
|
||||||
Dec(t,Square(GetI(Stats,i)));
|
Dec(t, Square(GetI(Stats,i)));
|
||||||
end;
|
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
Add(Stats, Stats.Items[i].Caption, 1);
|
Add(Stats, Stats.Items[i].Caption, 1);
|
||||||
@@ -1103,7 +1133,7 @@ begin
|
|||||||
WrLn( Format(' CHA%7d MP Max%7d', [GetI(Stats,'CHA'), GetI(Stats,'MP Max')]));
|
WrLn( Format(' CHA%7d MP Max%7d', [GetI(Stats,'CHA'), GetI(Stats,'MP Max')]));
|
||||||
WrLn;
|
WrLn;
|
||||||
WrLn( 'Equipment:');
|
WrLn( 'Equipment:');
|
||||||
for i := 1 to Equips.Items.Count-1 do
|
for i := 0 to Equips.Items.Count-1 do
|
||||||
if Get(Equips,i) <> '' then
|
if Get(Equips,i) <> '' then
|
||||||
WrLn( ' ' + LeftStr(Equips.Items[i].Caption + ' ', 12) + Get(Equips,i));
|
WrLn( ' ' + LeftStr(Equips.Items[i].Caption + ' ', 12) + Get(Equips,i));
|
||||||
WrLn;
|
WrLn;
|
||||||
@@ -1601,7 +1631,7 @@ begin
|
|||||||
Navigate(GetHostAddr + 'name=' + UrlEncode(Get(Traits,'Name')));
|
Navigate(GetHostAddr + 'name=' + UrlEncode(Get(Traits,'Name')));
|
||||||
end;
|
end;
|
||||||
if (ssCtrl in Shift) and (Key = ord('G')) then begin
|
if (ssCtrl in Shift) and (Key = ord('G')) then begin
|
||||||
SetGuild(InputBox('Progress Quest', 'Choose a guild.'#13#13'Make sure you undestand the guild rules before you join one. To learn more about guilds, visit http://progressquest.com/guilds.php', GetGuild));
|
SetGuild(InputBox('Progress Quest', 'Choose a guild.'#13#13'Make sure you understand the guild rules before you join one. To learn more about guilds, visit http://progressquest.com/guilds.php', GetGuild));
|
||||||
Guildify;
|
Guildify;
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|||||||
Vendored
+22
@@ -0,0 +1,22 @@
|
|||||||
|
Reminder: How I publish a new version
|
||||||
|
-------------------------------------
|
||||||
|
|
||||||
|
$ cd pq/dist
|
||||||
|
$ cp ../pq.exe .
|
||||||
|
$ zip pq6-MAJOR-MINOR pq.exe README.html license.txt
|
||||||
|
$ md5 pq6-MAJOR-MINOR.zip
|
||||||
|
$ shasum pq6-MAJOR-MINOR.zip
|
||||||
|
$ du -h pq6-MAJOR-MINOR.zip
|
||||||
|
$ git add pq6-MAJOR_MINOR.zip
|
||||||
|
$ git commit -am "new version!"
|
||||||
|
$ scp pq6-MAJOR-MINOR.zip progressquest.com:www/progressquest.com/dl/
|
||||||
|
$ ssh progressquest.com
|
||||||
|
$ cd www/progressquest.com
|
||||||
|
$ nano dl.php
|
||||||
|
[copypasta in the new version and checksums and size]
|
||||||
|
$ nano releasenotes.php
|
||||||
|
[type in the changes]
|
||||||
|
$ cd dl
|
||||||
|
$ git add pq6-MAJOR-MINOR.zip
|
||||||
|
$ git commit -am "New version published!"
|
||||||
|
$ did Released PQ version 6-MAJOR-MINOR
|
||||||
Vendored
BIN
Binary file not shown.
Vendored
BIN
Binary file not shown.
Vendored
BIN
Binary file not shown.
Reference in new issue
Block a user