NoGo game script to execute admin commands
Moderator: OpenTTD Developers
-
- Engineer
- Posts: 2
- Joined: 03 Jun 2013 16:05
NoGo game script to execute admin commands
Hi Everyone!
I'm pretty new to OpenTTD so it might be a wrong way trying to achieve what I want to do but is it possible with NoGo to execute admin commands like restart, pause or say? If so, how? Or should I use some other way, because I played on a server where game was restarted after someone achieved the goal, and top companies were shown in chat at the start of every year.
Any help would be appriated!
superturban
I'm pretty new to OpenTTD so it might be a wrong way trying to achieve what I want to do but is it possible with NoGo to execute admin commands like restart, pause or say? If so, how? Or should I use some other way, because I played on a server where game was restarted after someone achieved the goal, and top companies were shown in chat at the start of every year.
Any help would be appriated!
superturban
-
- Engineer
- Posts: 79
- Joined: 12 Feb 2013 17:29
Re: NoGo game script to execute admin commands
only if you create an script yourself. to do so you need:
OpenTTD 1.2.x or above
Squirrel 2.2.5 stable (3.x may work)
Java JRE (JDK for help) 5 or above
Eclipse 3.2 or above
and the SQDEV kit for eclipse.
to get these here are the links:
Squirrel: at http://squirrel-lang.org/
Java 5: http://java.sun.com/javase/downloads/index.jsp
Eclipse: http://www.eclipse.org/
More intructions coming soon.
OpenTTD 1.2.x or above
Squirrel 2.2.5 stable (3.x may work)
Java JRE (JDK for help) 5 or above
Eclipse 3.2 or above
and the SQDEV kit for eclipse.
to get these here are the links:
Squirrel: at http://squirrel-lang.org/
Java 5: http://java.sun.com/javase/downloads/index.jsp
Eclipse: http://www.eclipse.org/
More intructions coming soon.
Activity-absent for now.
PLEASE DO NOT REPLY TO MY MESSAGES ANYMORE!
PLEASE DO NOT REPLY TO MY MESSAGES ANYMORE!
-
- Engineer
- Posts: 79
- Joined: 12 Feb 2013 17:29
Re: NoGo game script to execute admin commands
Part 2:
run eclipse.exe and click on "Help" and click on "Install New Software"
from there click on "Add" by the site toolbar and type in this:
Name: SQDev Update Site
Location: http://sqdev.sf.net/update/
click ok and select the new site.
download the SQDEV kit and reset eclipse
from there follow instructions at the wiki in
http://wiki.openttd.org/Game_script
you can use Zuu's minimal GS as basis at:
http://www.tt-forums.net/viewtopic.php?f=65&t=62163
these steps can be used to create your own AI too!
run eclipse.exe and click on "Help" and click on "Install New Software"
from there click on "Add" by the site toolbar and type in this:
Name: SQDev Update Site
Location: http://sqdev.sf.net/update/
click ok and select the new site.
download the SQDEV kit and reset eclipse
from there follow instructions at the wiki in
http://wiki.openttd.org/Game_script
you can use Zuu's minimal GS as basis at:
http://www.tt-forums.net/viewtopic.php?f=65&t=62163
these steps can be used to create your own AI too!
Activity-absent for now.
PLEASE DO NOT REPLY TO MY MESSAGES ANYMORE!
PLEASE DO NOT REPLY TO MY MESSAGES ANYMORE!
Re: NoGo game script to execute admin commands
Interesting approach, I never considered to use a development environment for writing squirrel.
Could be quite helpful.
I tend to do it at a smaller scale, I edit the squirrel code with a plain text editor, and use OpenTTD itself to run and test the code.
Could be quite helpful.
I tend to do it at a smaller scale, I edit the squirrel code with a plain text editor, and use OpenTTD itself to run and test the code.
-
- Engineer
- Posts: 2
- Joined: 03 Jun 2013 16:05
Re: NoGo game script to execute admin commands
Thanks for you answers.
I actually already wrote my game script and just wanted to use the commands to show the top companies via chat message, to pause and to restart the game. Could anyone point me in the right direction?
superturban
I actually already wrote my game script and just wanted to use the commands to show the top companies via chat message, to pause and to restart the game. Could anyone point me in the right direction?
superturban
-
- Engineer
- Posts: 79
- Joined: 12 Feb 2013 17:29
Re: NoGo game script to execute admin commands
it may take awhile to do that.
try looking at the wiki or look at other scripts codes.
or look at Superlib For NoGo, it has stuff that may help you.
was that good?
hope you're happy with that.

try looking at the wiki or look at other scripts codes.
or look at Superlib For NoGo, it has stuff that may help you.
was that good?

hope you're happy with that.

Activity-absent for now.
PLEASE DO NOT REPLY TO MY MESSAGES ANYMORE!
PLEASE DO NOT REPLY TO MY MESSAGES ANYMORE!
Re: NoGo game script to execute admin commands
You can pause/unpause the game from squirrel, however mind that the allowed acrions in pause setting should then not be at its most restrictive value or you may easily shoot yourself in the foot. (gs continues to run while in pause, but forbidden actions will fail. at the most restrictive level, users are unable to answer questions from the gs and cause the gs to lock up.)
If you want full acess to console commands you need to have an admin port bot that is connected to the GS. See the GS API to the admin port.
If you want full acess to console commands you need to have an admin port bot that is connected to the GS. See the GS API to the admin port.
My OpenTTD contributions (AIs, Game Scripts, patches, OpenTTD Auto Updater, and some sprites)
Junctioneer (a traffic intersection simulator)
Junctioneer (a traffic intersection simulator)
Who is online
Users browsing this forum: No registered users and 18 guests