- add: money is now sent with the character data sent to the client
This commit is contained in:
@@ -79,9 +79,10 @@ message Character {
|
||||
message CharacterFull {
|
||||
string character_id = 1; // Unique ID for the character
|
||||
string name = 2; // Name of the character
|
||||
Location position = 3; // Character's position
|
||||
Looks looks = 4; // Character's Looks
|
||||
Stats stats = 5; // Character's stats
|
||||
repeated Skill skills = 6; // Character's skills
|
||||
repeated Item items = 7; // Character inventory
|
||||
int64 money = 3;
|
||||
Location position = 4; // Character's position
|
||||
Looks looks = 5; // Character's Looks
|
||||
Stats stats = 6; // Character's stats
|
||||
repeated Skill skills = 7; // Character's skills
|
||||
repeated Item items = 8; // Character inventory
|
||||
}
|
||||
@@ -3,61 +3,62 @@ syntax = "proto3";
|
||||
package character_db_api;
|
||||
|
||||
service CharacterDbService {
|
||||
rpc GetCharacter (CharacterRequest) returns (Character);
|
||||
rpc GetCharacterList (CharacterListRequest) returns (CharacterListResponse);
|
||||
rpc CreateCharacter (CreateCharacterRequest) returns (CreateCharacterResponse);
|
||||
rpc DeleteCharacter (DeleteCharacterRequest) returns (DeleteCharacterResponse);
|
||||
rpc GetCharacter (CharacterRequest) returns (Character);
|
||||
rpc GetCharacterList (CharacterListRequest) returns (CharacterListResponse);
|
||||
rpc CreateCharacter (CreateCharacterRequest) returns (CreateCharacterResponse);
|
||||
rpc DeleteCharacter (DeleteCharacterRequest) returns (DeleteCharacterResponse);
|
||||
}
|
||||
|
||||
message CharacterRequest {
|
||||
int32 user_id = 1;
|
||||
int32 character_id = 2;
|
||||
int32 user_id = 1;
|
||||
int32 character_id = 2;
|
||||
}
|
||||
|
||||
message CharacterListRequest {
|
||||
int32 user_id = 1;
|
||||
int32 user_id = 1;
|
||||
}
|
||||
|
||||
message CharacterListResponse {
|
||||
repeated Character characters = 1;
|
||||
repeated Character characters = 1;
|
||||
}
|
||||
|
||||
message CreateCharacterRequest {
|
||||
int32 user_id = 1;
|
||||
string name = 2;
|
||||
string inventory = 3; // JSON serialized
|
||||
string stats = 4; // JSON serialized
|
||||
string looks = 5; // JSON serialized
|
||||
string position = 6; // JSON serialized
|
||||
int32 user_id = 1;
|
||||
string name = 2;
|
||||
string inventory = 3; // JSON serialized
|
||||
string stats = 4; // JSON serialized
|
||||
string looks = 5; // JSON serialized
|
||||
string position = 6; // JSON serialized
|
||||
}
|
||||
|
||||
message CreateCharacterResponse {
|
||||
int32 result = 1;
|
||||
int32 character_id = 2;
|
||||
int32 result = 1;
|
||||
int32 character_id = 2;
|
||||
}
|
||||
|
||||
message DeleteCharacterRequest {
|
||||
int32 user_id = 1;
|
||||
int32 character_id = 2;
|
||||
int32 delete_type = 3;
|
||||
int32 user_id = 1;
|
||||
int32 character_id = 2;
|
||||
int32 delete_type = 3;
|
||||
}
|
||||
|
||||
message DeleteCharacterResponse {
|
||||
int64 remaining_time = 1;
|
||||
string name = 2;
|
||||
int64 remaining_time = 1;
|
||||
string name = 2;
|
||||
}
|
||||
|
||||
message Character {
|
||||
int32 id = 1;
|
||||
int32 user_id = 2;
|
||||
string name = 3;
|
||||
string inventory = 6;
|
||||
string stats = 7;
|
||||
string skills = 8;
|
||||
string looks = 9;
|
||||
string position = 10;
|
||||
string created_at = 11;
|
||||
string updated_at = 12;
|
||||
string deleted_at = 13;
|
||||
bool is_active = 14;
|
||||
int32 id = 1;
|
||||
int32 user_id = 2;
|
||||
string name = 3;
|
||||
int64 money = 4;
|
||||
string inventory = 6;
|
||||
string stats = 7;
|
||||
string skills = 8;
|
||||
string looks = 9;
|
||||
string position = 10;
|
||||
string created_at = 11;
|
||||
string updated_at = 12;
|
||||
string deleted_at = 13;
|
||||
bool is_active = 14;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user