Alpha release

Alpha release

gajop's in-engine scenario and map editor

Moderators: Moderators, Content Developer

Post Reply
gajop
Moderator
Posts: 3051
Joined: 05 Aug 2009, 20:42

Alpha release

Post by gajop »

Download
You can obtain in a number of ways, but I would suggest you get it from rapid.
The rapid tags are:
scen_core:stable (Scenario Editor Core)
scen_ba:stable (Scenario Editor BA)

Alternatively you can get it from git:
https://github.com/gajop/Scenario-Editor-Core
and
https://github.com/gajop/Scenario-Editor-BA
Make sure you follow the instructions (get it with git clone --recursive), otherwise it might not pull the submodules.

In addition there are three git-only repos for other games:
https://github.com/gajop/Scenario-Editor-ZK
https://github.com/gajop/Scenario-Editor-XTA
https://github.com/gajop/Scenario-Editor-MCL
https://github.com/gajop/Scenario-Editor-EVO (currently broken)

The third option is getting the .sdz links from here:
Scenario Editor BA
Scenario Editor Core

Version: 0.4

Requirements:
Spring 98+ ideally, Spring Features v1.1 (should be pulled from rapid), Balanced Annihilation v8.00 (should be pulled from rapid)

Also, feedback is welcomed!

Release 0.4:

Major features:
- Texturemap saving
- Smooth and level tools
- Unit property editing
- Command queue saving
- Team changing
- Lots of bug fixes

Video: https://www.youtube.com/watch?v=L3g_DKVsXzE

Release 0.3:

I'm releasing the first alpha build now. This will contain Scenario Editor Core (the base module for any game), and Scenario Editor BA (the Balanced Annihilation module). For now I'm sticking to only one game even though it's designed to be game-agnostic - mostly because I don't want to deal with potential game-specific issues now. If you want to experiment you can always check my other repos and make your game run it.

Major features:
- Add/remove/rotate/copy/paste units & features
- Add triggers (program the game) - with variables, areas and other stuff
- Add/remove teams & setup alliances
- Modify the heightmap
User avatar
knorke
Posts: 7971
Joined: 22 Feb 2006, 01:02

Re: Alpha release

Post by knorke »

Nice. :)
Random things:

The .sdz are packed wrong (one extra folder inside)

1) I used spring 96.0 instead of 97+ because all test-versions I had were bit old
2) I did not have Spring Features v1.1 and could only find v1.0 http://springfiles.com/spring/tools/spring-features
So just removed that depends-line from modinfo.lua. But then had to look for three sneaky archivecache.lua files that had to be deleted until spring would recognize that this depency was removed. Guess should have just edited the one line instead of deleting whole file, now had to wait endlessly for it to rebuild..

First start via spring.exe: It crashed, infolog had some Lua-error about "terrain shader edit bla."
Second start it crashed again, http://pastebin.com/kQyRJ8PK but this time not so useful log :(
Third start it worked, but nothing from editor was visible on screen. Noticed the disabled "Scenario-Editor" widget and turned it on: now got useful error message.

Just in case tried the way manual explains it (springlobby and 2 NullAis) but same error:
http://pastebin.com/Y3JG64e4

Code: Select all

[f=0000339][f=0000339] Error in Initialize(): error = 2, scen_edit/state/terrain_change_texture_state.lua, [string "scen_edit/state/terrain_change_texture_stat..."]:97: attempt to call field 'CreateShader' (a nil value)
[f=0000339] Removed widget: Scenario Editor
[f=0000339] Cheating is enabled!
Enabled setting LuaShaders=1 - but same error. (Think my GFX card does not like some shaders, though some work.)


In triggers\core.lua noticed randomly something that seems strange, but that is just from looking not testing:

Code: Select all

humanName = "Repair position"
...
Spring.GiveOrderToUnit(unit, CMD.REPAIR, { x, y, z }, {"shift"})
wiki says that "CMD.REPAIR wants 1 parameter in return (unitid) or 4 parameters in return (mappos+radius)" but you give 3 parameters, missing the radius?

Is there some example missions to look at, eg the one from video?
Only found this old looking "trololo" example:
https://github.com/gajop/Scenario-Edito ... r/examples
It seems missions consist of two Lua-parts? One is generated by the GUI-editor and second part is extra files written by hand, for special functionality?

Out of interesst, what are your thoughts on mission-GUI that the player sees?
In the video-test-mission you just use normal chat & markers, but that just for testing.
Think that is big step from tech-demo to really enjoyable missions.
At least it needs some mission-chatlog, where player can re-read what he has to do. (especially important for tutorials)
Or some mission-objectives list that get checked off once goals are completed:
http://www.visualwalkthroughs.com/chaser/assault/11.jpg
Possible some pre-mission briefing.
Then imo needs some GUI to mark special units or areas:
"Destroy the enemy shield generators" *shield generators get marked with some circle around them.*
Would these things be included in editor or be left for games to implent? Imo it is bit problematic either way....If one adds some "mission-objectives"-button somewhere, there is chance it will overlap with other parts of game GUI. GUI is not only different from game to game but also from player to player because everything is so customizeable.
gajop
Moderator
Posts: 3051
Joined: 05 Aug 2009, 20:42

Re: Alpha release

Post by gajop »

knorke wrote:Nice. :)
Random things:

The .sdz are packed wrong (one extra folder inside)
Thanks, will fix.
knorke wrote: 1) I used spring 96.0 instead of 97+ because all test-versions I had were bit old
97+ fixes building rotation and adds SetAlly which are used by Scenario Editor.
knorke wrote: 2) I did not have Spring Features v1.1 and could only find v1.0 http://springfiles.com/spring/tools/spring-features
It should be possible to get Spring Features v1.1 from rapid: http://packages.springrts.com/builds/sp ... s-v1.1.sdz .
knorke wrote: First start via spring.exe: It crashed, infolog had some Lua-error about "terrain shader edit bla."
Second start it crashed again, http://pastebin.com/kQyRJ8PK but this time not so useful log :(
Third start it worked, but nothing from editor was visible on screen. Noticed the disabled "Scenario-Editor" widget and turned it on: now got useful error message.
Shader issues it seems. I'll rewrite that code so it doesn't load it unless you use the terrain painter and make it checks for shader support. It seems to be an engine issue that gives a seg fault.
knorke wrote: In triggers\core.lua noticed randomly something that seems strange, but that is just from looking not testing:

Code: Select all

humanName = "Repair position"
...
Spring.GiveOrderToUnit(unit, CMD.REPAIR, { x, y, z }, {"shift"})
wiki says that "CMD.REPAIR wants 1 parameter in return (unitid) or 4 parameters in return (mappos+radius)" but you give 3 parameters, missing the radius?
Seems like it, thanks.
knorke wrote: Is there some example missions to look at, eg the one from video?
Only found this old looking "trololo" example:
https://github.com/gajop/Scenario-Edito ... r/examples
Not really, the "trololo" is way outdated, I'll get the video one uploaded.
knorke wrote: It seems missions consist of two Lua-parts? One is generated by the GUI-editor and second part is extra files written by hand, for special functionality?
Yep, it consists of meta-models (special functionality as you call it) which are filled by hand and optional, and of the output of the GUI editor, that has data about triggers, variables, units, features, teams, etc. in model.lua file, heightmap stuff in the heightmap.data file, and a modinfo.lua.
Technically if you put stuff in luaui/widgets and luarules/gadgets of the project file, it would contain those widgets and gadgets when you export it - but it's not well supported yet and can't be used in development mode.
knorke wrote: Out of interesst, what are your thoughts on mission-GUI that the player sees?
In the video-test-mission you just use normal chat & markers, but that just for testing.
Think that is big step from tech-demo to really enjoyable missions.
At least it needs some mission-chatlog, where player can re-read what he has to do. (especially important for tutorials)
Or some mission-objectives list that get checked off once goals are completed:
http://www.visualwalkthroughs.com/chaser/assault/11.jpg
Possible some pre-mission briefing.
Then imo needs some GUI to mark special units or areas:
"Destroy the enemy shield generators" *shield generators get marked with some circle around them.*
Would these things be included in editor or be left for games to implent? Imo it is bit problematic either way....If one adds some "mission-objectives"-button somewhere, there is chance it will overlap with other parts of game GUI. GUI is not only different from game to game but also from player to player because everything is so customizeable.
This could be done in a couple of ways but I think the best thing would be for the game itself to add whatever widgets and gadgets it needs to process and display mission objectives to the game-specific version of Scenario Editor, e.g. Scenario Editor BA. In addition to this they should supply the meta programming files (mostly actions I guess) that would allow players to specify objectives and their status.
Alternatively I could include the objective "model" and meta programming stuff in the Scenario Editor Core, and have games provide a GUI.
SpikedHelmet
MC: Legacy & Spring 1944 Developer
Posts: 1948
Joined: 21 Sep 2004, 08:25

Re: Alpha release

Post by SpikedHelmet »

Well I tried it, but get this massive list of errors that I don't understand:

http://pastebin.com/YGiTf3d2
gajop
Moderator
Posts: 3051
Joined: 05 Aug 2009, 20:42

Re: Alpha release

Post by gajop »

What exactly is "Scenario Editor MCL 0.3"? It seems to me you based it on Scenario Editor BA, correct?

Anyway it seems like MCL was conflicting with savetable.lua so I made a few changes to it, should be usable now.

I've also created this repo for Scenario Editor MCL, and I suggest you check that out. It uses "Scenario Editor Core git" and "MechCommander: Legacy $VERSION" so be sure to have those.
User avatar
FLOZi
MC: Legacy & Spring 1944 Developer
Posts: 6240
Joined: 29 Apr 2005, 01:14

Re: Alpha release

Post by FLOZi »

Progress!

It is usable now, still an error with beacons;
[f=0000188] Error: LuaRules::RunCallIn: error = 2, UnitCreated, [string "LuaRules/Gadgets/dbg_scenario_editor.lua"]:187: GiveOrderToUnit() recursion is not permitted
stack traceback:
[C]: in function 'GiveOrderToUnit'
[string "LuaRules/Gadgets/dbg_scenario_editor.lua"]:187: in function 'UnitCreated'
[string "luagadgets/gadgets.lua"]:1234: in function <[string "luagadgets/gadgets.lua"]:1232>
(tail call): ?
[C]: in function 'CreateUnit'
[string "LuaRules/Gadgets/unit_beaconbuild.lua"]:220: in function 'SetDropZone'
[string "LuaRules/Gadgets/unit_beaconbuild.lua"]:437: in function 'AllowCommand'
[string "luagadgets/gadgets.lua"]:1059: in function <[string "luagadgets/gadgets.lua"]:1056>
(tail call): ?
[C]: in function 'GiveOrderToUnit'
[string "scripts/beacon.lua"]:52: in function <[string "scripts/beacon.lua"]:49>
[C]: in function 'sp_CallAsUnit'
[string "LuaRules/Gadgets/unit_script.lua"]:303: in function 'CallAsUnit'
[string "LuaRules/Gadgets/lus_helper.lua"]:352: in function 'MoveCtrlNotify'
[string "luagadgets/gadgets.lua"]:1167: in function <[string "luagadgets/gadgets.lua"]:1164>
(tail call): ?
gajop
Moderator
Posts: 3051
Joined: 05 Aug 2009, 20:42

Re: Alpha release

Post by gajop »

Well I'm not sure how this is recursion..
Anyway, fixed hack-fixed that here
User avatar
smoth
Posts: 22309
Joined: 13 Jan 2005, 00:46

Re: Alpha release

Post by smoth »

are you getting a recursion error or something? build a table of commands and execute it on gameframe?
User avatar
FLOZi
MC: Legacy & Spring 1944 Developer
Posts: 6240
Joined: 29 Apr 2005, 01:14

Re: Alpha release

Post by FLOZi »

Use DelayCall for all your 'recursion' avoidance needs.
gajop
Moderator
Posts: 3051
Joined: 05 Aug 2009, 20:42

Re: Alpha release

Post by gajop »

FLOZi wrote:Use DelayCall for all your 'recursion' avoidance needs.
Yes, I know, I use it in some other cases (all messages aka commands are delayed by one frame), and I might do it here, but just pointing out it's not actually my code that does the recursion, but an odd combination: something in MCL calls GiveOrderToUnit which then creates a unit (a beacon I guess) and then UnitCreated gets invoked in my gadget, which also tries to send a GiveOrderToUnit. Spring detects that as an attempt of 'recursion' and complains :/
User avatar
FLOZi
MC: Legacy & Spring 1944 Developer
Posts: 6240
Joined: 29 Apr 2005, 01:14

Re: Alpha release

Post by FLOZi »

It is the dropzone, it is spawned when a certain command is given to a beacon (and this command is automatically given to beacons spawned as player start units)
gajop
Moderator
Posts: 3051
Joined: 05 Aug 2009, 20:42

Re: Alpha release

Post by gajop »

Release 0.4:

Major features:
- Texturemap saving
- Smooth and level tools
- Unit property editing
- Command queue saving
- Team changing
- Lots of bug fixes

Video: https://www.youtube.com/watch?v=L3g_DKVsXzE

Some of the features require develop engine version but it should hopefully not break without them.
You can get them via rapid, github or dropbox links from the first post.
gajop
Moderator
Posts: 3051
Joined: 05 Aug 2009, 20:42

Re: Alpha release

Post by gajop »

In addition there are three git-only repos for other games:
https://github.com/gajop/Scenario-Editor-ZK
https://github.com/gajop/Scenario-Editor-MCL
https://github.com/gajop/Scenario-Editor-EVO (currently broken)

Ideally they would be put on rapid and in sdzs in some future releases, but currently I don't have the time to test anything more than the most basic functionality, so if you want to use it, you will have to try the git version.
Post Reply

Return to “SpringBoard”