[Dev] SVN: james/501 Math Marauders: Now saves any changes you make to the map
James Paige
Bob at HamsterRepublic.com
Fri Apr 11 13:43:06 PDT 2008
Well, for my current purposes, ~, Alt-B Select object type, Create
Asset, pick location and name, OK is adequate (a bit tedious, but it
works)
but what I really want is to be able to save an asset based on a
programmatically generate asset_id. I don't want to have to type in a
name. This would be for situations where the programmer, not the
user-of-the-editor would make the descision on what the asset name is.
How often that will be useful in a finished game is a mystery to me--
probably not very useful, but durring the development process it is
something I find myself wanting not infrequently.
---
James
On Fri, Apr 11, 2008 at 01:32:22PM -0700, Brian Fisher wrote:
> I'm just comparing alternatives here - how would a save as work? would it
> pop up a dialog? that's what creating a new asset in the editor does, and
> it's more consistent and explicit because it's an always available option,
> and isn't something that would just be used once (when editing the broken
> reference asset)
>
> I think ~, Alt-B, Select object type, Create Asset, pick location and
> name, OK is as good a way to make the initial asset as any.
>
> If there is a different model that makes more sense, we can invest in
> that.
>
> On Fri, Apr 11, 2008 at 11:56 AM, James Paige <Bob at hamsterrepublic.com>
> wrote:
>
> On Fri, Apr 11, 2008 at 11:50:15AM -0700, Brian Fisher wrote:
> > The error is bad there - but I think the correct solution is to
> create a
> > new map in the editor that is connected to a file, and then edit
> it. The
> > broken asset is really intended to be a "hey! you have a bad asset
> > reference" object and to be a bootstrapping device (i.e. you can
> run it
> > long enough to create an asset)
> >
> > basically it might be nice to have a "save as" mechanic, but I
> don't see
> > how any such mechanic would be any less work than creating a new
> asset in
> > the editor?
>
> It would be needed for something edited directly in the game window.
> ---
> James
>
> > On Fri, Apr 11, 2008 at 11:31 AM, James Paige
> <Bob at hamsterrepublic.com>
> > wrote:
> >
> > I was running into problems when saving a not-yet-existing asset.
> >
> > Basically, I have a map asset which I create like so:
> >
> > map = AssetRef(BaseMap, "default")
> >
> > So "data/default.map" does not exist anymore, but it correctly
> uses the
> > _BrokenMap object when I play, so I have a map, but when I try to
> call
> > map.asset_save() it crashes because map has no .asset_metadata
> property.
> > (which makes sense, because this was not deserialized from disk)
> >
> > So I have worked around the problem by manually creating
> default.map in
> > the editor, but is there some better way to say, "please save
> this
> > asset to disk even though it was not loaded from disk"
> >
> > You can reproduce the problem I was having by deleting
> data/default.map,
> > running main.py, and clicking anywhere (which triggers the
> > .asset_save() call)
> >
> > ---
> > James
> > On Fri, Apr 11, 2008 at 11:09:58AM -0700,
> subversion at HamsterRepublic.com
> > wrote:
> > > james
> > > 2008-04-11 11:09:57 -0700 (Fri, 11 Apr 2008)
> > > 58
> > > Math Marauders: Now saves any changes you make to the map
> > > ---
> > > A marauders/data/default.map
> > > U marauders/locals.py
> > > U marauders/main.py
> > > U marauders/map.py
> > >
> > >
> > _______________________________________________
> > Dev mailing list
> > Dev at lists.motherhamster.org
> > http://lists.motherhamster.org/listinfo.cgi/dev-motherhamster.org
>
> > _______________________________________________
> > Dev mailing list
> > Dev at lists.motherhamster.org
> > http://lists.motherhamster.org/listinfo.cgi/dev-motherhamster.org
>
> _______________________________________________
> Dev mailing list
> Dev at lists.motherhamster.org
> http://lists.motherhamster.org/listinfo.cgi/dev-motherhamster.org
> _______________________________________________
> Dev mailing list
> Dev at lists.motherhamster.org
> http://lists.motherhamster.org/listinfo.cgi/dev-motherhamster.org
More information about the Dev
mailing list