Scripting
#1
Does anyone know the code the reset AC, because I want to edit the .cfg scripts while in-game.
Thanks given by:
#2
I have no idea what you mean by editing the .cfg scripts in-game, but if you want to reset AC just reinstall.
Thanks given by:
#3
Like just editing the scripts while I'm Playing AC, and I need to reload AC so it can load the scripts I edited. Lol
Thanks given by:
#4
Any scripts done in-game are automatically applied to the game during that moment, there's no need to reload anything.
Thanks given by:
#5
You can always re-execute a .cfg at anytime by using the exec or run commands.
Thanks given by:
#6
Nu, when I try to make a new menu in menus.cfg, it didn't work. Because it loads the data one time and thats when AC starts, lol.
Thanks given by:
#7
You can't edit .cfgs from in-game. Theres no other way of doing it.
Thanks given by:
#8
/writecfg ?

Though, yes, it would be nice to be able to write to cfg files other than saved.cfg in-game.

@CDan75:
If you want to modify a menu, in the current version you can add to the end of any already-existing menu in-game by invoking that menu using "newmenu". This is most easily done using a cfg file you can execute later.

It sounds like you're running AC and, while it is minimized, editing a menu in a cfg file. The issue with editing a menu while AC is running is that, in the current version, the menus don't reset unless you actually quit the game. In the next version, menus are resettable individually(yay!).

If you really want to do this while the game is running, you'd do it like this:
[cubescript]
newmenu main
menuitem [Just adding some stuff to the bottom of the main menu...] -1
[/cubescript]
Save that as a config file the game can access, such as "editedmenu.cfg" in the scripts directory. Then, in-game, type:
/exec scripts/editedmenu.cfg
and your menu should be added on to!

Keep in mind, however, that each time you do this without resetting the game, the custom menuitem will be added to the main menu. Only by resetting the game can you clear it out and start over.
Thanks given by:
#9
Thank ya V-Man, lol. Other thing I can do is "Bind F9 [echo Script Executed ; exec auto.cfg]", and when my game is Minimized or not in use, I can just write a script in "auto.cfg", then Save it. Now only thing I have to do is Press F9 when I enter the game again, and it will execute the script. :D
Thanks given by: