FIFE forums

Please login or register.

Login with username, password and session length
Advanced search  

News:

FIFE 0.4.0 has been released on 15th of January, 2017!

Author Topic: [FIFEdit Plugin] Object editor  (Read 3100 times)

chewie

  • Developer
  • Full Member
  • *
  • Posts: 123
    • View Profile
    • zero-projekt.net
[FIFEdit Plugin] Object editor
« on: September 11, 2008, 10:31:26 am »

Moin moin :)

I'm currently writing a small plugin for FIFEdit - an offset editor.

The goal is to add a possibility to the editor to adjust object offsets to the chosen map geometry, save the changes. The plugin should take care of wether the user wants to edit static images, rotated images and also frames of animations.

After some work, it seems that I can turn this plugin into a general "object editor".

Features so far:
  • Instance selection
  • Instance indication via InstanceRenderer (addOutline)
  • Manipulation of x / y offsets via GUI
  • Showing all (?) data of the instance / object in the GUI
  • Working offset changes for map objects which aren't providing wired rotations (33°, 67° etc...)
  • Manipulation of instance rotation

Changes to mapeditor.py plugin:
  • Instance rotation code was hardcoded to 90 degree steps - I tried to make this a little more flexible. But this isn't a long term solution

Problems / lacking features so far:
  • Different rotations are still an issue
  • Animations are not editable for now - they need quite some knowledge about the way FIFE is handling animations
  • Saving object data

Problems:

  • Instance rotation differs from object rotation (rotation value which you define in the XML files) due to camera tilt.
  • Animations doesn't provide something similar to "visual.getStaticImageAngles()"
  • In general the internal FIFE animation data is hard (?) to collect and needs a lot of code (so no animation['x'][alldata] structure, instead you have to build this on your own)

I guess I am missing something important due to image pool / animation pool handling - so I would be glad for any help about this issue.

Attachements:
  • (new) Screenshot

The plugin itself can be downloaded from here:

Edit: the plugin now has the name "object editor"
« Last Edit: March 17, 2009, 12:38:19 pm by chewie »
Logged

chewie

  • Developer
  • Full Member
  • *
  • Posts: 123
    • View Profile
    • zero-projekt.net
Re: [FIFEdit Plugin] Offset editor
« Reply #1 on: September 18, 2008, 11:47:55 am »

Just wanted to let you know that I uploaded an updated version of the plugin to the FIFE SVN repository. I am also about to change it to a object editor - instead of only adding the possibility to change / save offsets.

So the blocking and static information is editable. as well as the id of the clicked instance of the object.

ATM I am working on the data management (e. g. to provide undo steps) and the saver code for the XML files.
« Last Edit: September 18, 2008, 11:50:00 am by chewie »
Logged

chewie

  • Developer
  • Full Member
  • *
  • Posts: 123
    • View Profile
    • zero-projekt.net
Re: [FIFEdit Plugin] Offset editor / Update
« Reply #2 on: March 17, 2009, 07:24:55 am »

I (finally ^^) updated the objectedit plugin and fixed some issues.

New features:
  • instance ids now can be set via the plugin (editor saves them into the map)
  • namespaces and object ids are now labels instead of textboxes (they shouldn't be editable)

Solved issues:
  • dropped local undo feature which caused quite some trouble (changes were reverted once you clicked the modified instance again, crashes ...  ::))

All in all the plugin now is (hopefully) a better tool for a working environment, and I'm gearing it towards easier usage now (e.g. I'm thinking about adding offset manipulation via sliders and hotkeys).

Please let me know if you encounter any issues with the new version. Ideas for further improvments are also welcome :)

mvBarracuda

  • Administrator
  • Sr. Member
  • *
  • Posts: 411
    • View Profile
Re: [FIFEdit Plugin] Object editor
« Reply #3 on: March 17, 2009, 03:18:46 pm »

Looks cool chewie :-) is this version already in SVN or do you plan to change something before commiting?
Logged

chewie

  • Developer
  • Full Member
  • *
  • Posts: 123
    • View Profile
    • zero-projekt.net
Re: [FIFEdit Plugin] Object editor
« Reply #4 on: March 17, 2009, 04:01:37 pm »

I committed it yesterday to the client :)

-> rev 2728