Commit 0f941138 by jixudong

Upload New File

parent eed681ec
**测试环境URL**:http://tx-gz14.heyqiwu.cn
**测试环境URL**:http://tx-gz14.heyqiwu.cn
**生产环境URL**:http://tx-gz11.heyqiwu.cn
[TOC]
### 添加NPC类
URL: api/platform/design/npc/class
METHOD: POST
URL Parameters|TYPE: JSON
```
{
"name":"瑞哪",
"intro":"队长的报表",
"projectId":11,
"npcClassAttrVos":[
{
"name":"杀伤力",
"value":"1000",
},
{
"name":"年龄",
"value":"18"
}
]
}
```
Headers:
| Parameter | Type | Description |
| :----------- | :----------------------------: | ----------: |
| content-type | application/json;charset=utf-8 | |
ResponseBody:
```
{"code":1,"msg":"成功","data":{"id":12}}
```
### 删除NPC分类
URL: api/platform/design/npc/class
METHOD: DELETE
URL Parameters|TYPE:
Headers:
| Parameter | Type | Description |
| :----------- | :----------------------------: | ----------: |
| content-type | application/json;charset=utf-8 | |
ResponseBody:
```
{"code":1,"msg":"成功","data":null}
```
### 更新NPC分类
URL: api/platform/design/npc/class
METHOD: PUT
URL Parameters|TYPE: JSON
```
{
"id": 12,
"name": "瑞哪",
"intro": "队长的报表",
"projectId": 11,
"npcClassAttrVos": [{
"id": 1,
"name": "杀伤力",
"value": "2000"
}, {
"id": 2,
"name": "年龄",
"value": "17"
},{
"name":"身高",
"value":"180"
}]
}
```
Headers:
| Parameter | Type | Description |
| :----------- | :----------------------------: | ----------: |
| content-type | application/json;charset=utf-8 | |
ResponseBody:
```
{"code":1,"msg":"成功","data":null}
```
### 通过工程id查询所有NPC分类
URL: api/platform/design/npc/class
METHOD: GET
URL Parameters|TYPE:Param
| Parameter | Type | Description |
| :-------- | :--: | ----------: |
| projectId | Long | 游戏工程id |
Headers:
| Parameter | Type | Description |
| :----------- | :----------------------------: | ----------- |
| content-type | application/json;charset=utf-8 | |
ResponseBody:
```
{
"code": 1,
"msg": "成功",
"data": [{
"id": 7,
"name": "商贩",
"intro": "游走于大陆上的商人",
"projectId": 11,
"npcClassAttrVos": []
}, {
"id": 10,
"name": "飞机",
"intro": "用来",
"projectId": 11,
"npcClassAttrVos": []
}, {
"id": 13,
"name": "瑞哪",
"intro": "队长的报表",
"projectId": 11,
"npcClassAttrVos": [{
"id": 4,
"name": "杀伤力",
"value": "1000"
}, {
"id": 5,
"name": "年龄",
"value": "18"
}]
}]
}
```
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment