Author Topic: Coding Admin panel  (Read 3037 times)

Coding Admin panel
« on: October 14, 2012, 03:16:03 pm »
I'm wondering how I could code the admin panel. What is the admin panel? Let me think... I think about menu list where are many options, like:
  • teleport on current map (click when you want to be teleport)
  • global map teleport
  • teleport to ID map
  • god mode (unlimited ammo, weight, dodge, no death, injury etc
  • spawn item ID (item ID/IDs and amount)
  • spawn critter ID (same as before but critters)
  • control critter NPC (move critter, use weapons, skill etc)
  • more options (ban, stun player etc)

And yes, I study C++ language but I'm begginer and I don't know anything about FOnline SDK. Could someone help me study SDK's language (is it other version of C++ isn't it?). At the moment I can only simply set config.fos it is not hard but I want to know more about SDK.

Re: Coding Admin panel
« Reply #1 on: October 14, 2012, 03:44:42 pm »
Almost all commands you asked already exists in test.fos and debug.fos, if you want create graphic menu you must look example client_screen_test.fos.
You can run commands from test.fos and debug.fos by command line, for example: ~run debug god 0 0 0 - this command will run function god from file debug.fos 

Re: Coding Admin panel
« Reply #2 on: October 14, 2012, 07:28:23 pm »
I think graphic menu is ok but I don't know how to start code it. Admin panel is the first feature which everyone want to have to easier move on maps, spawn and other. I could share it when I have it done but I can't.

Offline JovankaB

  • Rotator
  • JovankaB
Re: Coding Admin panel
« Reply #3 on: October 14, 2012, 08:17:50 pm »
it's easier to just make commands typed with some prefix, eg

!teleleport <location id>

etc. check out out_message client function (in SDK it should be in client_main.fos)
you can use RunServerScript and RunServerScriptUnsafe to invoke server function from client



or even just function like in test.fos which can be invoked with built-in command ~run
~run <module> <function> <param1> <param2> <param3>

scripting whole admin panel is huge thing
« Last Edit: October 14, 2012, 08:20:43 pm by JovankaB »

Re: Coding Admin panel
« Reply #4 on: October 15, 2012, 04:04:45 pm »
I prefer menu but I can't do this. This menu looks great.

<a href="https://www.youtube.com/watch?v=4E5mNOVX6Ms" target="_blank">https://www.youtube.com/watch?v=4E5mNOVX6Ms</a>