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
36201dd7
Commit
36201dd7
authored
Jan 28, 2023
by
Nemo Ma
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update global.func.php
parent
9243c475
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
1 deletion
+11
-1
include/global.func.php
include/global.func.php
+11
-1
No files found.
include/global.func.php
View file @
36201dd7
...
...
@@ -532,7 +532,7 @@ function update_db_player_structure($type=0)
return
$type
?
$db_player_structure_types
:
$db_player_structure
;
}
//返回一个只有数据库合法字段键名的pdata数组
function
player_format_with_db_structure
(
$data
){
/*
function player_format_with_db_structure($data){
$ndata=Array();
$db_player_structure = update_db_player_structure();
foreach ($db_player_structure as $key){
...
...
@@ -543,6 +543,16 @@ function player_format_with_db_structure($data){
}
}
return $ndata;
} */
function
player_format_with_db_structure
(
$data
){
$ndata
=
Array
();
$db_player_structure
=
update_db_player_structure
();
foreach
(
$db_player_structure
as
$key
)
{
if
(
is_array
(
$data
[
$key
]))
$data
[
$key
]
=
json_encode
(
$data
[
$key
]);
$ndata
[
$key
]
=
$data
[
$key
];
}
return
$ndata
;
}
//为显示在主界面、尸体发现界面、游戏帮助界面的道具名、道具类、道具属性添加额外描述
//传入$n=道具名/类/属性;$t='m'(使用名称数组)/'k'(类别)/'sk'(属性);$short=1(传入的$n为数组情况下才有效,缩写属性);$class(如果传入的$n没有匹配的样式,则应用该样式)
...
...
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