summaryrefslogtreecommitdiff
path: root/NET/worlds/network/propReqCmd.java
diff options
context:
space:
mode:
authorFuwn <[email protected]>2026-02-12 22:33:32 -0800
committerFuwn <[email protected]>2026-02-12 22:33:32 -0800
commitc7a9d4a6bd53ed7d61731770f2f10e8b9fd435f9 (patch)
treedf9f48bf128a6c0186a8e91857d6ff30fe0e9f18 /NET/worlds/network/propReqCmd.java
downloadworldsplayer-c7a9d4a6bd53ed7d61731770f2f10e8b9fd435f9.tar.xz
worldsplayer-c7a9d4a6bd53ed7d61731770f2f10e8b9fd435f9.zip
Initial commit
Diffstat (limited to 'NET/worlds/network/propReqCmd.java')
-rw-r--r--NET/worlds/network/propReqCmd.java50
1 files changed, 50 insertions, 0 deletions
diff --git a/NET/worlds/network/propReqCmd.java b/NET/worlds/network/propReqCmd.java
new file mode 100644
index 0000000..0c6c043
--- /dev/null
+++ b/NET/worlds/network/propReqCmd.java
@@ -0,0 +1,50 @@
+package NET.worlds.network;
+
+import java.io.IOException;
+import java.util.Vector;
+
+public class propReqCmd extends netPacket {
+ public static final byte PROPREQCMD = 10;
+ protected Vector<Integer> _varids = new Vector<Integer>();
+
+ public propReqCmd(ObjID id, int varid) {
+ super(id, 10);
+ this.addProp(varid);
+ }
+
+ public propReqCmd(ObjID id) {
+ super(id, 10);
+ }
+
+ public void addProp(int varid) {
+ this._varids.addElement(new Integer(varid));
+ }
+
+ @Override
+ int packetSize() {
+ return this._varids.size() + super.packetSize();
+ }
+
+ @Override
+ void send(ServerOutputStream o) throws IOException {
+ super.send(o);
+ int maxidx = this._varids.size();
+
+ for (int i = 0; i < maxidx; i++) {
+ Integer tmpInt = this._varids.elementAt(i);
+ o.writeByte(tmpInt);
+ }
+ }
+
+ @Override
+ public String toString(WorldServer serv) {
+ String out = "PROPREQ " + this._objID.toString(serv) + " ";
+ int maxidx = this._varids.size();
+
+ for (int i = 0; i < maxidx; i++) {
+ out = out + " #" + this._varids.elementAt(i);
+ }
+
+ return out;
+ }
+}