Dedicated server on raspberry pi

Post here if you need help setting up your server, etc.
User avatar
Galaxip
On Lightcycle Grid
Posts: 38
Joined: Wed Aug 24, 2016 10:49 pm

Re: Dedicated server on raspberry pi

Post by Galaxip »

I recompiled the server with the zthread and tried to redirect the output to a txt file, the game compiled ok but the output went to screen and not the file sorry

testing other stuff ...

put the following line into everytime.cfg
delay_command 20 console_message ************ test ************

which produces the following in the console.txt file
Delay Command: "console_message ************ test ************" with delay of 20 and interval of 0

but nothing appears in the game console and the server crashes !
what is the interval of 0 ? that does'nt sound good does it ?

ive not used the delay_command before so im not sure what the output should be

strange issues

User avatar
kyle
Reverse Outside Corner Grinder
Posts: 1843
Joined: Thu Jun 08, 2006 3:33 pm
Location: Indiana, USA, Earth, Milky Way Galaxy, Universe, Multiverse
Contact:

Re: Dedicated server on raspberry pi

Post by kyle »

It's been a while, but I think you want

Code: Select all

delay_command r20 console_message ************ test ************
r20 for repeating every 20 seconds
Image

User avatar
Galaxip
On Lightcycle Grid
Posts: 38
Joined: Wed Aug 24, 2016 10:49 pm

Re: Dedicated server on raspberry pi

Post by Galaxip »

thanks but I think it'll still crash , theres something wrong with this build




the thing ive noticed while compiling is a lot of warnings about auto_ptr, I still couldnt capture the output but i did take a screen shot of just a few of them, the screen scrolls with lots of warnings about auto_ptr
auto_ptr.png

User avatar
Galaxip
On Lightcycle Grid
Posts: 38
Joined: Wed Aug 24, 2016 10:49 pm

Re: Dedicated server on raspberry pi

Post by Galaxip »

I decided to test on another system so I installed ubuntu on an intel i3 laptop and compiled the same source code

I have the same issues when deathzone appears and server instanty crashes

any ideas ?

is there a problem with this source code ?

Im kind of stuck

User avatar
Galaxip
On Lightcycle Grid
Posts: 38
Joined: Wed Aug 24, 2016 10:49 pm

Re: Dedicated server on raspberry pi

Post by Galaxip »

i downloaded and compiled z-mans 0.2.8 sty ct

bzr branch lp:~z-man/armagetronad/0.2.8-armagetronad-sty+ct

it worked 1st time. no issues with zones , no problems with delayed commands, no crashes with respawn etc

great news

i needed the kill_all command so I pulled the few lines of source from gGame.cpp in the the 0.2.9 sty+ct+ap and pasted it into the 0.2.8
it compiled prefectly

im not sure what the issue is with the 0.2.9 ?

User avatar
kyle
Reverse Outside Corner Grinder
Posts: 1843
Joined: Thu Jun 08, 2006 3:33 pm
Location: Indiana, USA, Earth, Milky Way Galaxy, Universe, Multiverse
Contact:

Re: Dedicated server on raspberry pi

Post by kyle »

Some BZR branches may be stale See viewtopic.php?p=314468#p314468 and the first post of that thread viewtopic.php?p=314468#top Z-man feel free to correct me

basically you need to

Code: Select all

git clone https://github.com/ArmagetronAd/armagetronad.git
cd armagetronad
git checkout <branch name see below>
By default you are on the master branch which is 0.4
legacy_0.2.8.3 - that is basically the newest 0.2.8 line
hack-0.2.8-sty+ct - this should be a fairly up to date sty+ct, it is missing a few of the latest updates to legacy_0.2.8.3

You can look at other branches https://github.com/ArmagetronAd/armaget ... anches/all


Way off topic, but PHPBB format really bugs me a lot after using a few variations of markdown for just about all my formatting needs
Image

User avatar
Galaxip
On Lightcycle Grid
Posts: 38
Joined: Wed Aug 24, 2016 10:49 pm

Re: Dedicated server on raspberry pi

Post by Galaxip »

thanks kyle im looking into this

User avatar
Z-Man
God & Project Admin
Posts: 11253
Joined: Sun Jan 23, 2005 6:01 pm
Location: Cologne, Jabber: [email protected]
Contact:

Re: Dedicated server on raspberry pi

Post by Z-Man »

kyle wrote:
Thu Apr 09, 2020 2:29 am
Some BZR branches may be stale See viewtopic.php?p=314468#p314468 and the first post of that thread viewtopic.php?p=314468#top Z-man feel free to correct me
The bzr branches are not stale yet, they're still in sync with bzr. There is one issue with MY version of the ap and ct branches on both git and bzr, namely that I don't sync them from their actually maintained branches very often. And if I understand correctly, the ap branch has the additional problem that the 0.2.8 main branch where I do all the fixes hasn't been fully merged; they did a source code reformat a while back and that makes merging really painful. I dimly remember a zone appearance crash, but I can't find it now. It may even have been the nullptr checks fixed around the same time we got rid of the auto_ptrs.

User avatar
Galaxip
On Lightcycle Grid
Posts: 38
Joined: Wed Aug 24, 2016 10:49 pm

Re: Dedicated server on raspberry pi

Post by Galaxip »

things are going well although the pi is a bit underpowered and ive got an issue with my psu (also underpowered) so my pi's been running at 600mhz instead of 900mhz all this time and linux is unaware of this, i had to query the gpu which is in control of the cpu throttling ! anyways ...

i've been trying to find documentation for the commands for this sty+ct build but everywhere is incomplete, even the server help file has a lot of entrys that are missing or just end with _help without anything useful

ive been trying to setup a target zone and even for this simple task im looking through the server source code to try and work out how it functions and what commands are available for set_target_command

is there a full documentation of all armagetron commands anywhere that I can download ?

thanks

User avatar
kyle
Reverse Outside Corner Grinder
Posts: 1843
Joined: Thu Jun 08, 2006 3:33 pm
Location: Indiana, USA, Earth, Milky Way Galaxy, Universe, Multiverse
Contact:

Re: Dedicated server on raspberry pi

Post by kyle »

There is a list of console commands http://wiki.armagetronad.org/index.php? ... nds_sty_ct (at the top you can switch between version)
I agree our documentation for sty+ct hacks is bad, We did have it somewhat documented on the CT wiki, which is down now, I'm hoping to find time near the end of the year to restore some of the CT stuff.

Most zones you have to use SPAWN_ZONE to spawn them, If you do Type just SPAWN_ZONE into the console, you should get this message

Code: Select all

 Usage:
SPAWN_ZONE <win|death|ball|target|blast|koh> <x> <y> <size> <growth> <xdir> <ydir> <interactive> <r> <g> <b> <target_size>
SPAWN_ZONE rubber <x> <y> <size> <growth> <xdir> <ydir> <rubber> <interactive> <r> <g> <b> <target_size>
SPAWN_ZONE teleport <x> <y> <size> <growth> <xdir> <ydir> <xjump> <yjump> <rel|abs> <interactive> <r> <g> <b> <target_size>
SPAWN_ZONE <fortress|flag|deathTeam|ballTeam> <team> <x> <y> <size> <growth> <xdir> <ydir> <interactive> <r> <g> <b> <target_size>
SPAWN_ZONE sumo <x> <y> <size> <growth> <xdir> <ydir> <interactive> <r> <g> <b> <target_size>
SPAWN_ZONE zombie <player> <x> <y> <size> <growth> <xdir> <ydir> <interactive> <r> <g> <b> <target_size>
SPAWN_ZONE zombieOwner <player> <owner> <x> <y> <size> <growth> <xdir> <ydir> <interactive> <r> <g> <b> <target_size>
instead of <x> <y> one can write: L <x1> <y1> <x2> <y2> [...] Z
Image

User avatar
Galaxip
On Lightcycle Grid
Posts: 38
Joined: Wed Aug 24, 2016 10:49 pm

Re: Dedicated server on raspberry pi

Post by Galaxip »

yeah i do have all the commands from the server by typing armagetronad-dedicated --doc

and all the wiki's just have a dump of that same output from --doc

but a lot of stuff is missing and just have the command_name_help as the help which is no help :P

some commands like set_target_command which is what I would really like to try are dangerous because they need the zone number supplied, if you type that command without parameters you wont get any help but you will get an instant server crash !

User avatar
Galaxip
On Lightcycle Grid
Posts: 38
Joined: Wed Aug 24, 2016 10:49 pm

Re: Dedicated server on raspberry pi

Post by Galaxip »

i hard wired a new psu 5V 3A directly soldered to the back of the pi and it should get rid of that pesky lightning bolt the gpu keeps spitting out

screwed everything to a bit of wood, it looks messy but trust me its really tidy compared to my usual projects

the larger board below the pi is just some junk router that im using as a lan hub
20200507_202831.jpg
20200507_225903.jpg

User avatar
kyle
Reverse Outside Corner Grinder
Posts: 1843
Joined: Thu Jun 08, 2006 3:33 pm
Location: Indiana, USA, Earth, Milky Way Galaxy, Universe, Multiverse
Contact:

Re: Dedicated server on raspberry pi

Post by kyle »

Wow, this has been a while (11 years since that was added) and I knew it was not my code despite initially seeing me as the blame :) from reformatting the spacing.

Anyway I looked into it some more, when you use SPAWN_ZONE you can also specify a name, this is the "zone number" that you mentioned as part of SET_TARGET_COMMAND

To inject this zone ID, the first thing after SPAWN_ZONE that you put is n followed by the name you want to use.

EX:
SPAWN_ZONE n T1 target ......

then
set_target_command T1 [add] (onenter | onvanish) (command to execute)
The optional "add" parameter I believe is so you can have multiple commands run, and I think you first have to use it without it for the first command you place on it. (not 100% sure on that though, as I did not dg that deep yet)

So basically this allows you to run a command when a target zone is entered and when it disappears.
Image

User avatar
Galaxip
On Lightcycle Grid
Posts: 38
Joined: Wed Aug 24, 2016 10:49 pm

Re: Dedicated server on raspberry pi

Post by Galaxip »

the vital part i was missing was "n zonename" during the creation, up until now I had been using a script to monitor the server output to grab the server assigned number of the zone and was trying everything i could think of with it to set the commands

thanks kyle the information you just gave me seems is working, as a quick test I created a zone called test1 and assigned kill_all command to it and it worked perfectly

where did you find this information ? ive been searching for ages

any documentation you could supply would be much appreciate

is there a document out there somewhere that has help on all the commands ? the english_base.txt file thats supplied with the source has lots missing

User avatar
kyle
Reverse Outside Corner Grinder
Posts: 1843
Joined: Thu Jun 08, 2006 3:33 pm
Location: Indiana, USA, Earth, Milky Way Galaxy, Universe, Multiverse
Contact:

Re: Dedicated server on raspberry pi

Post by kyle »

A little bit of memory, I was thinking there was a way to set the ID with Spawn_zone, even though it was not documented. I ended up going to the source in src/tron/gWinZone.cpp Having written my own zone hack extensions to that, I knew where to look and how to read it.
Image

Post Reply