Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
phpdts
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
List
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Nemo Ma
phpdts
Commits
f7c39051
Commit
f7c39051
authored
Apr 10, 2023
by
hisuinohoshi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix?
parent
848fb7e7
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
28 additions
and
21 deletions
+28
-21
include/game.func.php
include/game.func.php
+5
-5
include/game/itemmain.func.php
include/game/itemmain.func.php
+5
-3
include/game/revbattle.calc.php
include/game/revbattle.calc.php
+1
-1
include/game/revcombat_extra.func.php
include/game/revcombat_extra.func.php
+10
-6
include/game/search.func.php
include/game/search.func.php
+3
-2
include/roommng.func.php
include/roommng.func.php
+2
-2
templates/default/battle_rev.htm
templates/default/battle_rev.htm
+2
-2
No files found.
include/game.func.php
View file @
f7c39051
...
@@ -652,15 +652,15 @@ function fetch_playerdata_by_name($n)
...
@@ -652,15 +652,15 @@ function fetch_playerdata_by_name($n)
if
(
!
empty
(
$data
[
'clbpara'
][
'lasttimes'
]))
check_skilllasttimes
(
$data
);
if
(
!
empty
(
$data
[
'clbpara'
][
'lasttimes'
]))
check_skilllasttimes
(
$data
);
# 读取套装效果
# 读取套装效果
include_once
GAME_ROOT
.
'./include/game/itemmain.func.php'
;
include_once
GAME_ROOT
.
'./include/game/itemmain.func.php'
;
reload_set_items
(
$
p
data
);
reload_set_items
(
$data
);
return
$data
;
return
$data
;
}
}
//通过pid抓取指定玩家/NPC数据
//通过pid抓取指定玩家/NPC数据
function
fetch_playerdata_by_pid
(
$
p
id
)
function
fetch_playerdata_by_pid
(
$id
)
{
{
global
$db
,
$gtablepre
,
$tablepre
;
global
$db
,
$gtablepre
,
$tablepre
;
$result
=
$db
->
query
(
"SELECT * FROM
{
$tablepre
}
players WHERE pid = '
$
p
id
'"
);
$result
=
$db
->
query
(
"SELECT * FROM
{
$tablepre
}
players WHERE pid = '
$id
'"
);
if
(
!
$db
->
num_rows
(
$result
))
return
NULL
;
if
(
!
$db
->
num_rows
(
$result
))
return
NULL
;
$data
=
$db
->
fetch_array
(
$result
);
$data
=
$db
->
fetch_array
(
$result
);
...
@@ -670,7 +670,7 @@ function fetch_playerdata_by_pid($pid)
...
@@ -670,7 +670,7 @@ function fetch_playerdata_by_pid($pid)
if
(
!
empty
(
$data
[
'clbpara'
][
'lasttimes'
]))
check_skilllasttimes
(
$data
);
if
(
!
empty
(
$data
[
'clbpara'
][
'lasttimes'
]))
check_skilllasttimes
(
$data
);
# 读取套装效果
# 读取套装效果
include_once
GAME_ROOT
.
'./include/game/itemmain.func.php'
;
include_once
GAME_ROOT
.
'./include/game/itemmain.func.php'
;
reload_set_items
(
$
p
data
);
reload_set_items
(
$data
);
return
$data
;
return
$data
;
}
}
...
@@ -756,7 +756,7 @@ function addnoise($wp_kind, $wsk, $ntime, $npls, $nid1, $nid2, $nmode)
...
@@ -756,7 +756,7 @@ function addnoise($wp_kind, $wsk, $ntime, $npls, $nid1, $nid2, $nmode)
//销毁尸体
//销毁尸体
function
destory_corpse
(
&
$edata
)
function
destory_corpse
(
&
$edata
)
{
{
if
(
$edata
)
if
(
$edata
&&
$edata
[
'hp'
]
<=
0
)
{
{
$edata
[
'action'
]
=
''
;
$edata
[
'bid'
]
=
0
;
$edata
[
'action'
]
=
''
;
$edata
[
'bid'
]
=
0
;
$edata
[
'state'
]
=
16
;
$edata
[
'hp'
]
=
0
;
$edata
[
'money'
]
=
0
;
$edata
[
'pls'
]
=
254
;
$edata
[
'state'
]
=
16
;
$edata
[
'hp'
]
=
0
;
$edata
[
'money'
]
=
0
;
$edata
[
'pls'
]
=
254
;
...
...
include/game/itemmain.func.php
View file @
f7c39051
...
@@ -1269,15 +1269,17 @@ function getcorpse($item,&$data=NULL)
...
@@ -1269,15 +1269,17 @@ function getcorpse($item,&$data=NULL)
return
;
return
;
}
}
$result
=
$db
->
query
(
"SELECT * FROM
{
$tablepre
}
players WHERE pid='
$corpseid
'"
);
//$result = $db->query("SELECT * FROM {$tablepre}players WHERE pid='$corpseid'");
if
(
!
$db
->
num_rows
(
$result
)){
$edata
=
fetch_playerdata_by_pid
(
$corpseid
);
if
(
!
$edata
){
$log
.=
'对方不存在!<br>'
;
$log
.=
'对方不存在!<br>'
;
$action
=
''
;
$bid
=
0
;
$action
=
''
;
$bid
=
0
;
$mode
=
'command'
;
$mode
=
'command'
;
return
;
return
;
}
}
$edata
=
$db
->
fetch_array
(
$result
);
//
$edata = $db->fetch_array($result);
if
(
$edata
[
'hp'
]
>
0
)
{
if
(
$edata
[
'hp'
]
>
0
)
{
$log
.=
'对方尚未死亡!<br>'
;
$log
.=
'对方尚未死亡!<br>'
;
...
...
include/game/revbattle.calc.php
View file @
f7c39051
...
@@ -34,7 +34,7 @@ namespace revbattle
...
@@ -34,7 +34,7 @@ namespace revbattle
}
}
# pa发现pd时,计算pd被pa发现的概率
# pa发现pd时,计算pd被pa发现的概率
function
calc_hide_rate
(
&
$pa
,
&
$pd
,
$mode
=
0
)
function
calc_hide_rate
(
$pa
,
$pd
,
$mode
=
0
)
{
{
global
$weather
,
$weather_hide_r
,
$pls_hide_modifier
,
$pose_hide_modifier
,
$tactic_hide_modifier
;
global
$weather
,
$weather_hide_r
,
$pls_hide_modifier
,
$pose_hide_modifier
,
$tactic_hide_modifier
;
...
...
include/game/revcombat_extra.func.php
View file @
f7c39051
...
@@ -18,20 +18,24 @@ namespace revcombat
...
@@ -18,20 +18,24 @@ namespace revcombat
# 2.进攻方攻击方式、进攻方主动技能参数、进攻方被动技能参数、武器射程、攻击熟练度、武器名;
# 2.进攻方攻击方式、进攻方主动技能参数、进攻方被动技能参数、武器射程、攻击熟练度、武器名;
function
get_attr_wepbase
(
&
$pa
,
&
$pd
,
$active
,
$wep_kind
=
''
)
function
get_attr_wepbase
(
&
$pa
,
&
$pd
,
$active
,
$wep_kind
=
''
)
{
{
# 初始化pd
相关攻击
参数
# 初始化pd
攻击方式
参数
\revattr\get_wep_kind
(
$pd
);
\revattr\get_wep_kind
(
$pd
);
$pd
[
'wep_skill'
]
=
\revattr\get_wep_skill
(
$pd
);
\revattr\get_attr_passive_skills
(
$pd
,
$pa
,
$active
);
$pd
[
'wep_range'
]
=
\revattr\get_wep_range
(
$pd
);
$pd
[
'wep_range'
]
=
\revattr\get_wep_range
(
$pd
);
$pd
[
'wep_name'
]
=
$pd
[
'wep'
];
$pd
[
'wep_name'
]
=
$pd
[
'wep'
];
# 初始化pa
相关攻击
参数
# 初始化pa
攻击方式
参数
\revattr\get_wep_kind
(
$pa
,
$wep_kind
,
$pd
[
'wep_range'
]);
\revattr\get_wep_kind
(
$pa
,
$wep_kind
,
$pd
[
'wep_range'
]);
\revattr\get_attr_bskills
(
$pa
,
$pd
,
$active
);
\revattr\get_attr_bskills
(
$pa
,
$pd
,
$active
);
$pa
[
'wep_skill'
]
=
\revattr\get_wep_skill
(
$pa
);
\revattr\get_attr_passive_skills
(
$pa
,
$pd
,
$active
);
$pa
[
'wep_range'
]
=
\revattr\get_wep_range
(
$pa
);
$pa
[
'wep_range'
]
=
\revattr\get_wep_range
(
$pa
);
$pa
[
'wep_name'
]
=
$pa
[
'wep'
];
$pa
[
'wep_name'
]
=
$pa
[
'wep'
];
# 初始化pa、pd熟练度相关参数
$pd
[
'wep_skill'
]
=
\revattr\get_wep_skill
(
$pd
);
$pa
[
'wep_skill'
]
=
\revattr\get_wep_skill
(
$pa
);
# 初始化pa、pd被动技能相关参数
\revattr\get_attr_passive_skills
(
$pd
,
$pa
,
$active
);
\revattr\get_attr_passive_skills
(
$pa
,
$pd
,
$active
);
}
}
# 正式进入rev_combat战斗状态后,在判定伤害、反击流程前的事件执行阶段;
# 正式进入rev_combat战斗状态后,在判定伤害、反击流程前的事件执行阶段;
...
...
include/game/search.func.php
View file @
f7c39051
...
@@ -641,8 +641,9 @@ function discover($schmode = 0,&$data=NULL)
...
@@ -641,8 +641,9 @@ function discover($schmode = 0,&$data=NULL)
{
{
$db
->
data_seek
(
$result
,
$enum
);
$db
->
data_seek
(
$result
,
$enum
);
$edata
=
$db
->
fetch_array
(
$result
);
$edata
=
$db
->
fetch_array
(
$result
);
$eid
=
$edata
[
'pid'
];
# 使用fetch_playerdata_by_pid重新获取敌人数据,以应用各种在载入玩家数据时进行的判定
# 使用fetch_playerdata_by_pid重新获取敌人数据,以应用各种在载入玩家数据时进行的判定
$edata
=
fetch_playerdata_by_pid
(
$e
data
[
'pid'
]
);
$edata
=
fetch_playerdata_by_pid
(
$e
id
);
if
(
!
$edata
[
'type'
]
||
$gamestate
<
50
)
if
(
!
$edata
[
'type'
]
||
$gamestate
<
50
)
{
{
if
(
$edata
[
'hp'
]
<=
0
)
if
(
$edata
[
'hp'
]
<=
0
)
...
@@ -694,7 +695,7 @@ function discover($schmode = 0,&$data=NULL)
...
@@ -694,7 +695,7 @@ function discover($schmode = 0,&$data=NULL)
{
{
if
(
$edata
[
'hp'
]
>
0
)
if
(
$edata
[
'hp'
]
>
0
)
{
{
if
(
isset
(
$edata
[
'clbpara'
]))
$edata
[
'clbpara'
]
=
get_clbpara
(
$edata
[
'clbpara'
]);
//
if(isset($edata['clbpara'])) $edata['clbpara']=get_clbpara($edata['clbpara']);
//发现队友
//发现队友
if
(
$teamID
&&
(
!
$fog
)
&&
(
$gamestate
<
40
)
&&
(
$teamID
==
$edata
[
'teamID'
]))
if
(
$teamID
&&
(
!
$fog
)
&&
(
$gamestate
<
40
)
&&
(
$teamID
==
$edata
[
'teamID'
]))
{
{
...
...
include/roommng.func.php
View file @
f7c39051
...
@@ -38,10 +38,10 @@ function roommng_verify_db_game_structure()
...
@@ -38,10 +38,10 @@ function roommng_verify_db_game_structure()
$gr
=
$db
->
fetch_array
(
$result
);
$gr
=
$db
->
fetch_array
(
$result
);
if
(
$gr
[
'Column_name'
]
!=
'groomid'
)
if
(
$gr
[
'Column_name'
]
!=
'groomid'
)
{
{
if
(
!
empty
(
$gr
[
'
k
ey_name'
]))
if
(
!
empty
(
$gr
[
'
K
ey_name'
]))
{
{
$db
->
query
(
"ALTER TABLE`
{
$gtablepre
}
game` DROP PRIMARY KEY"
);
$db
->
query
(
"ALTER TABLE`
{
$gtablepre
}
game` DROP PRIMARY KEY"
);
echo
"取消了game表的主键
{
$gr
[
'
k
ey_name'
]
}
<br>"
;
echo
"取消了game表的主键
{
$gr
[
'
K
ey_name'
]
}
<br>"
;
}
}
$db
->
query
(
"ALTER TABLE`
{
$gtablepre
}
game` ADD PRIMARY KEY (`groomid`)"
);
$db
->
query
(
"ALTER TABLE`
{
$gtablepre
}
game` ADD PRIMARY KEY (`groomid`)"
);
echo
"将game表的主键变更为groomid<br>"
;
echo
"将game表的主键变更为groomid<br>"
;
...
...
templates/default/battle_rev.htm
View file @
f7c39051
...
@@ -63,7 +63,7 @@
...
@@ -63,7 +63,7 @@
<span>
战斗技能
</span>
<span>
战斗技能
</span>
</td>
</td>
<td
class=
"b3"
>
<td
class=
"b3"
>
<span><input
type=
"button"
class=
"cmdbutton"
value=
"点击查看
NPC
技能"
onclick=
"showModalDialog($('enemy_skillpage'));"
></span>
<span><input
type=
"button"
class=
"cmdbutton"
value=
"点击查看技能"
onclick=
"showModalDialog($('enemy_skillpage'));"
></span>
</td>
</td>
<!--{/if}-->
<!--{/if}-->
</tr>
</tr>
...
@@ -128,7 +128,7 @@
...
@@ -128,7 +128,7 @@
<p
style=
"margin-left:0px; margin-top:0px; margin-right:0px; margin-bottom:0px;"
>
<p
style=
"margin-left:0px; margin-top:0px; margin-right:0px; margin-bottom:0px;"
>
以下是
<span
class=
"yellow"
>
{$typeinfo[$tdata['type']]} $tdata['name']
</span>
的的技能列表。
以下是
<span
class=
"yellow"
>
{$typeinfo[$tdata['type']]} $tdata['name']
</span>
的的技能列表。
请注意描述文字中的
<span
class=
"yellow"
>
“你”
</span>
指代的是这个
NPC
。
请注意描述文字中的
<span
class=
"yellow"
>
“你”
</span>
指代的是这个
对象
。
<br><br>
<br><br>
<table
class=
"skilltable"
style=
"width:559px"
>
<table
class=
"skilltable"
style=
"width:559px"
>
<tr>
<tr>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment