|
|
|
|
|
|
|
Re: a new renhawk! [message #232056 is a reply to message #227348] |
Sun, 26 November 2006 16:17 |
|
jnz
Messages: 3396 Registered: July 2006 Location: 30th century
Karma: 0
|
General (3 Stars) |
|
|
so,
a string array maby 2560 elements
data recived appends to the array for 2 mins
[ loop ]
when a new peice of data arrives, read the 1st element then delete it.
shift the whole array -1
write the data recived to the first element
[/ loop ]
[Updated on: Sun, 26 November 2006 16:18] Report message to a moderator
|
|
|
Re: a new renhawk! [message #232059 is a reply to message #227348] |
Sun, 26 November 2006 16:36 |
|
danpaul88
Messages: 5795 Registered: June 2004 Location: England
Karma: 0
|
General (5 Stars) |
|
|
Yeah, that would do the trick. Be aware of the memory requirements of this though, a string array of over 2000 elements might eat up quite a bit of memory.
You should certainly consider processing it before putting it into an array or whatever, so that you get rid of any extra data you don't need, and then when two minutes is up it simply spits out the pre-processed data.
[Updated on: Sun, 26 November 2006 16:37] Report message to a moderator
|
|
|
|
|
|
|
|
|
|
|
Re: a new renhawk! [message #236525 is a reply to message #227348] |
Sun, 31 December 2006 09:10 |
|
jnz
Messages: 3396 Registered: July 2006 Location: 30th century
Karma: 0
|
General (3 Stars) |
|
|
yes, other bots can use this. but they have the task of putting the commands for the Seye into it, thats not a nice task.
EDIT: im not going to use gamelog.txt at all for this, mabe someone else's bot will butim not. im going to try and put a video capture type thing into it. ether that or get it to export a file that people can share and view other peoples games.
[Updated on: Sun, 31 December 2006 09:15] Report message to a moderator
|
|
|
|
|
|
|
Re: a new renhawk! [message #237036 is a reply to message #227348] |
Wed, 03 January 2007 13:48 |
|
Cat998
Messages: 1082 Registered: January 2004 Location: Austria, Vienna
Karma: 0
|
General (1 Star) Moderator/Captain |
|
|
Example:
[20:44:56] KILLED;SOLDIER;1500007864;CnC_Nod_Minigunner_3Boss;-14;107;0;168;1500009035;CnC_ GDI_MiniGunner_3Boss_ALT2;-128;130;14;-10;CnC_Weapon_RamjetRifle_Player
Do you really neeed anything of that ?
Instead of killed, you could just send a byte to the client for example, this would allow you to have 256 different events. And you can put every number into an integer of 4 bytes or a long.
This would drastically reduce the amount of data you have to send.
Then you could also compress it.
And... I don't think the client needs to have the data in realtime.
So you could just update the client every half seconds.. and woops
the used bandwidth is almost zero.
When people ask me "Plz" just because it's shorter than "Please" I feel perfectly justified to answer "No" because it's shorter then "Yes"
Programming is like sex: one mistake and you have to support it for the rest of your life
Want the best answers? Ask the best questions!
"So long, and thanks for all the fish."
[Updated on: Wed, 03 January 2007 13:52] Report message to a moderator
|
|
|
|
|