用于战神引擎玩家充值排行榜Npc脚本,脚本全自动记录本服前十名的充值玩家的金额信息,根据充值金额的大小,进行排序,脚本有需要一份引入文件做为变量判断,非单独文件,添加的时候需要把对应的变量添加到原先版本里面对应的文件,不能直接覆盖引入文件,除非你版本里面没有这份引入文件。部分脚本
program mir2;
{$I common.pas}
procedure _DoExit;
begin
This_Npc.CloseDialog(This_Player);
end;
procedure _Exit;
begin
This_Npc.CloseDialog(This_Player);
end;
procedure domain;
var
i,j,x,temp : integer;
showName, showPoint, temp_str : string;
rankName : Array [1..100] of String; rankInt : Array [1..100] of integer;
begin
for i:=1 to 100 do
begin
if ReadIniSectionStr('Paylog.txt','PayList',inttostr(i)) = '' then
break;
showName:=ReadIniSectionStr('Paylog.txt','PayList',inttostr(i));
showPoint:=ReadIniSectionStr('Paylog.txt','PayName',showName);
rankName[i]:=showName;
rankInt[i]:=strtoint(showPoint);
end
if showName <> '' then
begin
for i:=1 to 100 do
begin
if rankInt[i] <= 0 then
break;
for j:=1 to 100 do
begin
x:=j+1;
if (rankInt[j] <= 0) or (rankInt[x] <= 0) then
break;
if (rankInt[j] < rankInt[x]) and (rankInt[x] > 0) then
begin
temp := rankInt[j];
rankInt[j] := rankInt[x];
rankInt[x] := temp;
temp_str:=rankName[j];
rankName[j] := rankName[x];
rankName[x] := temp_str;
end
end
end
end
temp_str:='';
for i := 1 to 10 Do
begin
if rankName[i] <> '' then
temp_str:=temp_str+'第'+inttostr(i)+'名 :<'+rankName[i]+ '> 充值金额:<' + inttostr(rankInt[i])+'元>|'
else
temp_str:=temp_str+'第'+inttostr(i)+'名 : <空缺>|'
end
This_Npc.NpcDialog(This_Player,
temp_str+
'|'+ MirDateTimeToStr('yyyy-MM-dd hh:mm:ss' , GetNow)
+'|<【充值奖励】:/c=red> <每充值一元可以获得一个灵符/SCOLOR=250>\'
+'|{cmd}<我要用灵符兑换物品/@lingfuBuy>\'
//+'|{cmd}<清除/@geiIt>\'
+'|{cmd}<退出/@doexit>'
);
end;
感谢你的来访!QQ交流群:970786861
![](https://10cm.icu/wp-content/uploads/2022/01/2021111910005257.gif)
© 版权声明
1.本文部分内容转载自其它媒体,但并不代表本站赞同其观点和对其真实性负责。
2.若您需要商业运营或用于其他商业活动,请您购买正版授权并合法使用。
3.如果本站有侵犯、不妥之处的资源,请在网站最下方联系我们。将会第一时间解决!
4.本站所有内容均由互联网收集整理、网友上传,仅供大家参考、学习,不存在任何商业目的与商业用途。
5.本站提供的所有资源仅供参考学习使用,版权归原著所有,禁止下载本站资源参与商业和非法行为,请在24小时之内自行删除!处理。
2.若您需要商业运营或用于其他商业活动,请您购买正版授权并合法使用。
3.如果本站有侵犯、不妥之处的资源,请在网站最下方联系我们。将会第一时间解决!
4.本站所有内容均由互联网收集整理、网友上传,仅供大家参考、学习,不存在任何商业目的与商业用途。
5.本站提供的所有资源仅供参考学习使用,版权归原著所有,禁止下载本站资源参与商业和非法行为,请在24小时之内自行删除!处理。
THE END
暂无评论内容