aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFuwn <[email protected]>2024-06-12 06:50:29 -0700
committerFuwn <[email protected]>2024-06-12 06:50:29 -0700
commitd57ed896ec46ec5f081b3031bc8606033fdfd95f (patch)
tree87755d7ef6e3c54dab914e9004df84cf86ca8845
parentrefactor: clearer distance command (diff)
downloadworldserver-protobufs-d57ed896ec46ec5f081b3031bc8606033fdfd95f.tar.xz
worldserver-protobufs-d57ed896ec46ec5f081b3031bc8606033fdfd95f.zip
refactor: clearer network protobuf names
-rw-r--r--AppInitCmd.proto4
-rw-r--r--Network2Property.proto (renamed from Net2Property.proto)2
-rw-r--r--NetworkCommands.proto (renamed from NetCmds.proto)4
-rw-r--r--NetworkConstants.proto (renamed from NetConst.proto)0
-rw-r--r--NetworkData.proto (renamed from NetData.proto)0
-rw-r--r--NetworkPacket.proto (renamed from NetPacket.proto)2
-rw-r--r--NetworkProperty.proto (renamed from NetProperty.proto)2
-rw-r--r--OldPropertyList.proto4
-rw-r--r--PropertyList.proto4
-rw-r--r--build/test.py12
10 files changed, 17 insertions, 17 deletions
diff --git a/AppInitCmd.proto b/AppInitCmd.proto
index 10b7e73..d7c3bb9 100644
--- a/AppInitCmd.proto
+++ b/AppInitCmd.proto
@@ -2,8 +2,8 @@ syntax = "proto3";
package whirl;
-import "NetProperty.proto";
+import "NetworkProperty.proto";
message AppInitCmd {
- repeated NetProperty property_list = 2;
+ repeated NetworkProperty property_list = 2;
} \ No newline at end of file
diff --git a/Net2Property.proto b/Network2Property.proto
index 523b17b..94f6309 100644
--- a/Net2Property.proto
+++ b/Network2Property.proto
@@ -2,7 +2,7 @@ syntax = "proto3";
package whirl;
-message Net2Property {
+message Network2Property {
int32 prop_id = 1;
int32 flags = 2;
int32 access = 3;
diff --git a/NetCmds.proto b/NetworkCommands.proto
index 83d920c..d909716 100644
--- a/NetCmds.proto
+++ b/NetworkCommands.proto
@@ -2,7 +2,7 @@ syntax = "proto3";
package whirl;
-message NetCmds {
- repeated string receivable_net_packet = 1;
+message NetworkCommands {
+ repeated string receivable_network_packet = 1;
map<int32, string> property_list = 2;
}
diff --git a/NetConst.proto b/NetworkConstants.proto
index e51476f..e51476f 100644
--- a/NetConst.proto
+++ b/NetworkConstants.proto
diff --git a/NetData.proto b/NetworkData.proto
index 786370e..786370e 100644
--- a/NetData.proto
+++ b/NetworkData.proto
diff --git a/NetPacket.proto b/NetworkPacket.proto
index 0e9aff9..3922ea9 100644
--- a/NetPacket.proto
+++ b/NetworkPacket.proto
@@ -29,7 +29,7 @@ import "TextCmd.proto";
import "UnsubscribeRoomCmd.proto";
import "WhisperCmd.proto";
-message NetPacket {
+message NetworkPacket {
uint32 length = 1;
oneof object_id {
uint32 short_object_id = 2;
diff --git a/NetProperty.proto b/NetworkProperty.proto
index 8f426d8..4f30762 100644
--- a/NetProperty.proto
+++ b/NetworkProperty.proto
@@ -2,7 +2,7 @@ syntax = "proto3";
package whirl;
-message NetProperty {
+message NetworkProperty {
int32 property_id = 1;
string value = 2;
}
diff --git a/OldPropertyList.proto b/OldPropertyList.proto
index 5bb20e9..358ad67 100644
--- a/OldPropertyList.proto
+++ b/OldPropertyList.proto
@@ -2,8 +2,8 @@ syntax = "proto3";
package whirl;
-import "NetProperty.proto";
+import "NetworkProperty.proto";
message OldPropertyList {
- repeated NetProperty properties = 1;
+ repeated NetworkProperty properties = 1;
}
diff --git a/PropertyList.proto b/PropertyList.proto
index 2c83fcb..15e5ec7 100644
--- a/PropertyList.proto
+++ b/PropertyList.proto
@@ -2,8 +2,8 @@ syntax = "proto3";
package whirl;
-import "Net2Property.proto";
+import "Network2Property.proto";
message PropertyList {
- repeated Net2Property properties = 1;
+ repeated Network2Property properties = 1;
}
diff --git a/build/test.py b/build/test.py
index 00cc0f4..417e9eb 100644
--- a/build/test.py
+++ b/build/test.py
@@ -1,24 +1,24 @@
-import NetPacket_pb2
+import NetworkPacket_pb2
import BuddyListNotifyCmd_pb2
-request = NetPacket_pb2.NetPacket()
+request = NetworkPacket_pb2.NetworkPacket()
request.length = 3
request.short_object_id = 0xFF
-request.command_type = 0x0A
+request.type = 0x0A
request.buddy_list_notify_cmd.CopyFrom(BuddyListNotifyCmd_pb2.BuddyListNotifyCmd())
request.buddy_list_notify_cmd.buddy_name = "Whirl"
request.buddy_list_notify_cmd.logged_on = 1
print(request.SerializeToString())
-print(request.WhichOneof("packet"))
+print(request.WhichOneof("command"))
-deserialised_request = NetPacket_pb2.NetPacket()
+deserialised_request = NetworkPacket_pb2.NetworkPacket()
deserialised_request.ParseFromString(request.SerializeToString())
print(deserialised_request.length)
print(deserialised_request.short_object_id)
-print(deserialised_request.command_type)
+print(deserialised_request.type)
print(deserialised_request.buddy_list_notify_cmd.buddy_name)
print(deserialised_request.buddy_list_notify_cmd.logged_on)