diff options
Diffstat (limited to 'doc/tutorials')
-rw-r--r-- | doc/tutorials/networking/09.chat-server.pd | 38 | ||||
-rw-r--r-- | doc/tutorials/networking/10.chat_client.pd | 50 |
2 files changed, 35 insertions, 53 deletions
diff --git a/doc/tutorials/networking/09.chat-server.pd b/doc/tutorials/networking/09.chat-server.pd index eff0ec2d..59511141 100644 --- a/doc/tutorials/networking/09.chat-server.pd +++ b/doc/tutorials/networking/09.chat-server.pd @@ -1,21 +1,21 @@ -#N canvas 32 44 620 460 10; -#X declare -lib maxlib -lib cyclone -lib zexy; -#X obj 258 73 import maxlib cyclone zexy; -#X obj 141 172 netserver 47292; -#X obj 68 143 prepend broadcast; -#X obj 155 284 prepend; -#X obj 199 256 makesymbol client%s_%s; -#X obj 199 231 pack float symbol; +#N canvas 47 23 620 460 10; +#X obj 211 231 pack float symbol; #X obj 18 20 cnv 15 400 40 empty empty chat_server 20 12 0 24 -228992 -66577 0; -#X symbolatom 220 283 30 0 0 1 last_client - -; -#X floatatom 170 197 5 0 0 1 connections - -; -#X connect 1 0 3 0; -#X connect 1 1 8 0; -#X connect 1 2 5 0; -#X connect 1 3 5 1; -#X connect 2 0 1 0; -#X connect 3 0 2 0; -#X connect 4 0 3 1; -#X connect 4 0 7 0; -#X connect 5 0 4 0; +#X symbolatom 232 283 30 0 0 1 last_client - -; +#X floatatom 160 197 5 0 0 1 connections - -; +#X obj 72 112 list prepend broadcast; +#X obj 72 132 list trim; +#X obj 142 284 list prepend; +#X msg 211 252 symbol client\$1_\$2; +#X obj 142 172 maxlib/netserver 47292; +#X connect 0 0 7 0; +#X connect 4 0 5 0; +#X connect 5 0 8 0; +#X connect 6 0 4 0; +#X connect 7 0 6 1; +#X connect 7 0 2 0; +#X connect 8 0 6 0; +#X connect 8 1 3 0; +#X connect 8 2 0 0; +#X connect 8 3 0 1; diff --git a/doc/tutorials/networking/10.chat_client.pd b/doc/tutorials/networking/10.chat_client.pd index b58cb841..365e9eb3 100644 --- a/doc/tutorials/networking/10.chat_client.pd +++ b/doc/tutorials/networking/10.chat_client.pd @@ -1,12 +1,6 @@ -#N canvas 37 45 638 458 10; -#X declare -lib maxlib -lib cyclone -lib zexy; -#X obj 413 12 import maxlib cyclone zexy; +#N canvas 514 22 638 458 10; #X msg 159 205 disconnect; -#X obj 137 233 netclient; -#X obj 49 153 prepend send; #X obj 77 269 print; -#X obj 27 66 trigger bang bang; -#X msg 27 88 clear; #X text 242 204 <-- disconnect when you are done to free the port; #N canvas 238 612 454 304 (subpatch) 0; #X obj 101 10 inlet; @@ -37,34 +31,22 @@ #X connect 11 0 9 0; #X connect 11 0 7 0; #X coords 0 -1 1 1 25 25 1 100 100; -#X restore 205 250 pd; -#X msg 27 37 send; -#X obj 137 344 flatspace/entry 300 100 grey90 black; -#X obj 49 121 flatspace/entry 300 20 grey90 black; -#X text 81 345 message:; +#X restore 241 253 pd; #X text 30 10 type your message in the box below and hit return to send; -#X obj 394 83 select return; #X msg 137 176 connect localhost 47292; -#X obj 137 304 prepend append; -#X msg 260 305 key 10; -#X obj 137 282 trigger anything bang; -#X text 305 305 send return to make new line; #X text 286 176 <-- first connect to the chat-server.pd; -#X connect 1 0 2 0; -#X connect 2 0 4 0; -#X connect 2 0 18 0; -#X connect 2 1 8 0; -#X connect 3 0 2 0; -#X connect 5 0 6 0; -#X connect 5 1 11 0; -#X connect 6 0 11 0; -#X connect 9 0 5 0; -#X connect 11 0 3 0; -#X connect 11 1 14 0; -#X connect 14 0 5 0; -#X connect 15 0 2 0; -#X connect 16 0 10 0; -#X connect 17 0 10 0; -#X connect 18 0 16 0; -#X connect 18 1 17 0; +#X obj 137 304 pddp/print; +#X symbolatom 49 104 50 0 0 0 - - -; +#X obj 49 143 list prepend send; +#X obj 49 165 list trim; +#X text 52 305 last message:; +#X obj 137 233 maxlib/netclient; +#X connect 0 0 12 0; +#X connect 5 0 12 0; +#X connect 8 0 9 0; +#X connect 9 0 10 0; +#X connect 10 0 12 0; +#X connect 12 0 1 0; +#X connect 12 0 7 0; +#X connect 12 1 3 0; |