Goto https://www.stucuk.netGoto https://www.atlanticaonlinewiki.comGoto https://www.game-requirements.com


Menu


It is currently Tue Oct 17, 2017 6:48 am

All times are UTC [ DST ]




Post new topic Reply to topic  [ 17 posts ]  Go to page 1, 2  Next
Author Message
 Post subject: Original War Editor Ideas
PostPosted: Wed Dec 31, 2014 7:51 am 
Offline
OW Support Owner
OW Support Owner
User avatar

Joined: Wed Dec 28, 2005 11:13 pm
Posts: 4986
Location: UK, Scotland
I am looking for ideas on how to improve the editor. Ways to simplify map creation for example. One idea that i plan on implementing is to make it so the editor can setup a basic multiplayer map (Complete with sail code).

Extracting files from the OWP's when creating a new mod is currently implemented in the latest unreleased build.
Image

_________________
Image
Free Map Editor - Game Requirements - Stucuk.Net
-Stu


Top
 Profile  
 
 Post subject: Re: Original War Editor Ideas
PostPosted: Wed Dec 31, 2014 2:01 pm 
Offline
Moderator
Moderator
User avatar

Joined: Mon Mar 17, 2008 6:03 pm
Posts: 1129
Location: Denmark
Quote:
One idea that i plan on implementing is to make it so the editor can setup a basic multiplayer map (Complete with sail code).

That would be pretty sweet :)

Would also be nice to be able to use the mouse wheel to scroll in the SAIL editor instead of having to pull the slider every time.

And I know this has been mentioned before but is it completely impossible to get SAIL error messages telling you where in the un-compiled code the error occured (thinking especially reading out of bounds errors)? Just an estimate would also be ok. That's what I do manually. If you know how many lines of compiled and un-compiled code there is you can easily calculate roughly how many lines of compiled code goes per line of un-compiled code. From the error message (giving the line in the compiled code) you can then estimate where in the un-compiled code things went wrong.

_________________
I have an if that has an else, but that if has another if with an else inside... My question is... If an if has an else, if there is more than one line in that if, should it have a begin and an end?


Top
 Profile  
 
 Post subject: Re: Original War Editor Ideas
PostPosted: Wed Dec 31, 2014 6:19 pm 
Offline
OW Support Owner
OW Support Owner
User avatar

Joined: Wed Dec 28, 2005 11:13 pm
Posts: 4986
Location: UK, Scotland
Scroll Wheel was easy. But what's the actual error message the game gives? Need to know it so i can trace it.

_________________
Image
Free Map Editor - Game Requirements - Stucuk.Net
-Stu


Top
 Profile  
 
 Post subject: Re: Original War Editor Ideas
PostPosted: Wed Dec 31, 2014 8:23 pm 
Offline
Moderator
Moderator
User avatar

Joined: Mon Mar 17, 2008 6:03 pm
Posts: 1129
Location: Denmark
For reading beyond end of list it would be:

Runtime error at {line number}: reading beyond end of list: {index} of {list}, result set to 0, ignore further errors?!

_________________
I have an if that has an else, but that if has another if with an else inside... My question is... If an if has an else, if there is more than one line in that if, should it have a begin and an end?


Top
 Profile  
 
 Post subject: Re: Original War Editor Ideas
PostPosted: Wed Dec 31, 2014 8:39 pm 
Offline
OW Support Owner
OW Support Owner
User avatar

Joined: Wed Dec 28, 2005 11:13 pm
Posts: 4986
Location: UK, Scotland
McBenn wrote:
For reading beyond end of list it would be:

Runtime error at {line number}: reading beyond end of list: {index} of {list}, result set to 0, ignore further errors?!

But it has the compiled line number... You can look it up on the Debug Window's code bit. It shows the compiled code as well as the un-compiled (Commented out above the relevant compiled code) allowing you to see what line is causing the problem.

Image

_________________
Image
Free Map Editor - Game Requirements - Stucuk.Net
-Stu


Top
 Profile  
 
 Post subject: Re: Original War Editor Ideas
PostPosted: Thu Jan 01, 2015 9:19 am 
Offline
OW Support Owner
OW Support Owner
User avatar

Joined: Wed Dec 28, 2005 11:13 pm
Posts: 4986
Location: UK, Scotland
New Build:
-OWOGL_2015-01-01.rar

I looked into it and output.txt was never generated, so only altars maps would have it for the debug window to load. Also the debug window would not load the output.txt if it had too many lines in it.

I have modified the editor to create output.txt_lines.txt (I was too lazy to remove the .txt ext) which maps the un-compiled lines to the compiled lines.

Image
Image

_________________
Image
Free Map Editor - Game Requirements - Stucuk.Net
-Stu


Top
 Profile  
 
 Post subject: Re: Original War Editor Ideas
PostPosted: Thu Jan 01, 2015 12:17 pm 
Offline
Moderator
Moderator
User avatar

Joined: Mon Mar 17, 2008 6:03 pm
Posts: 1129
Location: Denmark
Awesome :D :D Out of curiosity: What's the difference between ow_editorDD.exe and ow_editorOGL.exe?

_________________
I have an if that has an else, but that if has another if with an else inside... My question is... If an if has an else, if there is more than one line in that if, should it have a begin and an end?


Top
 Profile  
 
 Post subject: Re: Original War Editor Ideas
PostPosted: Thu Jan 01, 2015 12:55 pm 
Offline
OW Support Owner
OW Support Owner
User avatar

Joined: Wed Dec 28, 2005 11:13 pm
Posts: 4986
Location: UK, Scotland
McBenn wrote:
Awesome :D :D Out of curiosity: What's the difference between ow_editorDD.exe and ow_editorOGL.exe?

DD stands for Direct Draw, OGL stands for OpenGL. Just the Graphics Library used for rendering. DD will force your monitor colours to 16 bit, OGL won't (OGL doesn't care what the colours are set to). DD is what the game has used since the beginning of time and which Windows 8 doesn't like (Though windowed like the editor seems to work fine).

I would recommend OGL over DD. OGL with the editor is only missing the in-game help bit which is not rendered right and the fact you can use it in 32bit is great.

_________________
Image
Free Map Editor - Game Requirements - Stucuk.Net
-Stu


Top
 Profile  
 
 Post subject: Re: Original War Editor Ideas
PostPosted: Fri Jan 02, 2015 5:48 pm 
Offline
OW Support Owner
OW Support Owner
User avatar

Joined: Wed Dec 28, 2005 11:13 pm
Posts: 4986
Location: UK, Scotland
Managed to get the Breakpoints working. They were being cleared every time the map was compiled/ran and altar's maps never re-compiled to generate the information needed to apply the breakpoints (Due to crc.bin existing).

Breakpoints allow you to see the values of variables in the Debug window but what they are at a certain point in the code (You don't need breakpoints to see there values, it just lets you know what they are at a certain point). I am thinking about mirroring some of the Information in the SAIL Editor window so you can easily see the values of variables while the game is running.

_________________
Image
Free Map Editor - Game Requirements - Stucuk.Net
-Stu


Top
 Profile  
 
 Post subject: Re: Original War Editor Ideas
PostPosted: Fri Jan 02, 2015 8:40 pm 
Offline
OW Support Owner
OW Support Owner
User avatar

Joined: Wed Dec 28, 2005 11:13 pm
Posts: 4986
Location: UK, Scotland
Image

Work in progress, still need to make it display the global variables. Its all thanks to the SAIL Editor having the ability to return the word thats under the mouse (Which can then be looked up to find the variable's value). I'm not sure if SAIL is case sensitive but the hints are done all in lowercase.

_________________
Image
Free Map Editor - Game Requirements - Stucuk.Net
-Stu


Top
 Profile  
 
 Post subject: Re: Original War Editor Ideas
PostPosted: Fri Jan 02, 2015 11:21 pm 
Offline
Moderator
Moderator
User avatar

Joined: Mon Mar 17, 2008 6:03 pm
Posts: 1129
Location: Denmark
Omg this is like going to make it a 1000 times easier to debug SAIL :mrgreen: No more display_strings or debug_strings :D You are really on a coding spree atm stu :P

Btw SAIL is not case sensitive.

_________________
I have an if that has an else, but that if has another if with an else inside... My question is... If an if has an else, if there is more than one line in that if, should it have a begin and an end?


Top
 Profile  
 
 Post subject: Re: Original War Editor Ideas
PostPosted: Sat Jan 03, 2015 12:21 pm 
Offline
OW Support Owner
OW Support Owner
User avatar

Joined: Wed Dec 28, 2005 11:13 pm
Posts: 4986
Location: UK, Scotland
McBenn wrote:
Omg this is like going to make it a 1000 times easier to debug SAIL :mrgreen: No more display_strings or debug_strings :D

It won't display variables declared inside functions as there is no way that i can currently see to work out which function your currently in. But i will create a bit that lists the variables of each function in the module your currently viewing so you can see what they are set too.

Currently iv managed to get it to display EXPORT variables, module variables (which are ones not marked as export and which are not inside a function), SAIL Variables (As in ones like uc_nation) and SAIL Constants (class_soldier, etc).

McBenn wrote:
You are really on a coding spree atm stu :P

Well so far these are the easy things to implement, simply because most of the functionality was already coded in.

With the breakpoints they technically would have always worked, if you actually set them while the mission was running and if the mission had compiled while the editor was running. One thing to remember with them, when you want to resume you need to just hit CTRL + E, not the Run/Trace/Etc. I don't actually know what Trace is meant to do.

_________________
Image
Free Map Editor - Game Requirements - Stucuk.Net
-Stu


Top
 Profile  
 
 Post subject: Re: Original War Editor Ideas
PostPosted: Sat Jan 03, 2015 3:32 pm 
Offline
OW Support Owner
OW Support Owner
User avatar

Joined: Wed Dec 28, 2005 11:13 pm
Posts: 4986
Location: UK, Scotland
New Build:
- OWOGL_2015-01-03.rar

This version includes:
  • Ability to create "Includes" from the add include bit in the SAIL Editor
  • Ability to hover over most variables/constants in the SAIL Editor to get there value
  • Ability to use Breakpoints
  • Re-Organised Menus (Restart is now Reset Map, Goto Game Mode moved to File Menu, etc)
  • Zoom Out ability (WIP, you can place units/trees/grass/etc while zoomed out, but the information overlay won't display correctly)

I hit a snag with function variables. I don't know how to get there values. I can get there names, but there doesn't seem to be anywhere that holds there values which can then be linked back to there name(So you know what value goes with what variable).

So you would have to create a variable in the module's scope (As in outside of a function) and set it to the variable you want to check from a function.

I.E
Code:
var Check;
function Bla();
var avalue;
begin
 avalue := 1;
 Check := avalue; // Hover over check during a breakpoint.
end;

_________________
Image
Free Map Editor - Game Requirements - Stucuk.Net
-Stu


Top
 Profile  
 
 Post subject: Re: Original War Editor Ideas
PostPosted: Sat Jan 03, 2015 7:20 pm 
Offline
Moderator
Moderator
User avatar

Joined: Mon Mar 17, 2008 6:03 pm
Posts: 1129
Location: Denmark
Nizzle :P
Zoom works but as you say not everything is displayed correctly. Still useful imo.

_________________
I have an if that has an else, but that if has another if with an else inside... My question is... If an if has an else, if there is more than one line in that if, should it have a begin and an end?


Top
 Profile  
 
 Post subject: Re: Original War Editor Ideas
PostPosted: Sat Feb 21, 2015 11:18 am 
Offline
Moderator
Moderator
User avatar

Joined: Mon Mar 17, 2008 6:03 pm
Posts: 1129
Location: Denmark
Another thing but it's not the editor as such (I presume it's the compiler). You can comment out multiple lines by using curly brackets { } but you can nest these. If you have something like

Code:
{
aa = 1;
{
bb = 1;
}
cc = 1;
}


Only the code from the first { to the first } is commented out leaving uncompilable code behind. I guess what's happening is that the second { is also commented out.

_________________
I have an if that has an else, but that if has another if with an else inside... My question is... If an if has an else, if there is more than one line in that if, should it have a begin and an end?


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 17 posts ]  Go to page 1, 2  Next

All times are UTC [ DST ]


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group

Original War is an RTS / RPG game by Altar Games
Original War Support is not part of Altar Games but is maintaining Original War for Altar Games

Privacy Policy