Member Controls

Developers > Echos Graphical Footprint Editor (was:Code submission?)
EchoLink to postposted: Sun Oct 14, 2007 6:59 am
Avator for Echo

Member since:
 2005-03-06
From:
 Melbourne, Australia
Posts:
 83

Hi Quaxi et al,

 

I have a small code change/feature addition that I'd like to submit for your approval and possible addition to the next version of SimPE. I couldn't find any formal process, so I guess posting here will have to do. It's not particularly ground breaking, but I felt like playing with something non-BHAV related for a bit of a change. :)

 

It's basically a footprint editor for the existing CRES editor. If it identifies a node as a footprint node, it provides an additional "draw" button which opens a dialog that uses checkboxes to show which parts of the footprint are traversable and which are not.

 

draw button

 

gorilla statue footprint

 

kid's oven footprint

 

It seems to have worked reasonably well for me. It's a little bit slow because of the number of controls on the form, but it is created on-demand and should not slow down any existing tasks. This is my first experience of C# (although it's similar to Java so not a big shift), thus if I've broken any style rules feel free to chastize me for it. :)

 

The altered file is here: http://www.eternal-echo.net/remoteimg/tExtension.cs

Inge JonesLink to postposted: Tue Oct 16, 2007 9:35 am
Avator for Inge Jones

Member since:
 2005-03-06
Posts:
 1899
Neat idea!
pljonesLink to postposted: Sun Oct 21, 2007 8:32 pm
Avator for pljones

Member since:
 2005-04-02
From:
 London, UK
Posts:
 610

The easiest format to merge into the SVN repository is a diff against between your source tree and the repository's latest version.  Then just attach the diff file to an appropriately named thread ("Patch to XXX to allow YYY") here and hope it catches Quaxi's eye next time he passes :).

Inge JonesLink to postposted: Sat Dec 15, 2007 8:16 pm
Avator for Inge Jones

Member since:
 2005-03-06
Posts:
 1899
Was this ever done?  Now's the time to implement it.
pljonesLink to postposted: Sun Dec 16, 2007 10:04 am
Avator for pljones

Member since:
 2005-04-02
From:
 London, UK
Posts:
 610
No - I think there must be some additional changes as the .cs file alone isn't enough, usually.  I'd expect the .resx, too?  That, or I'm not looking in the right place for the new option.
EchoLink to postposted: Sun Dec 16, 2007 12:49 pm
Avator for Echo

Member since:
 2005-03-06
From:
 Melbourne, Australia
Posts:
 83

Sorry for the delay, Inge just pointed out to me that this thread got updated while I wasn't looking!

 

I'm pretty sure that's it. I don't recall touching the resx. It's a pretty specific case to get the button to show up though. Open an object which sits on the floor (a table or a statue is good). Open the cres file. Open the footprint block. Click on the "Array" entry in the list. The button's on the right.

 

I'm happy to make a diff of the code tomorrow evening after work and post it, if that is easier for you to merge?

Inge JonesLink to postposted: Sun Dec 16, 2007 1:18 pm
Avator for Inge Jones

Member since:
 2005-03-06
Posts:
 1899

Echo, for the period of time we're taking care of SimPE, we've set up a section over at the PJSE forum for interested parties and developers: http://simlogical.com/SMF/index.php?

 

You'll probably find it easier to deal with this there, as you should be able to upload any files you need us to have.

pljonesLink to postposted: Mon Dec 17, 2007 8:51 am
Avator for pljones

Member since:
 2005-04-02
From:
 London, UK
Posts:
 610
Ah, found it!  I was looking in completely the wrong place.
EchoLink to postposted: Mon Dec 17, 2007 10:45 am
Avator for Echo

Member since:
 2005-03-06
From:
 Melbourne, Australia
Posts:
 83

Thanks Inge, I'll have to migrate over there. :)

Peter, does that mean you don't need the diff any more? 

pljonesLink to postposted: Mon Dec 17, 2007 1:17 pm
Avator for pljones

Member since:
 2005-04-02
From:
 London, UK
Posts:
 610
Yes.


viewthread, 0, 0, Code-submissions