Impact

This forum is read only and just serves as an archive. If you have any questions, please post them on github.com/phoboslab/impact

1 decade ago by sleenee

I have the following strange thing happening:

I have an entity that can be selected in the Weltmeister (at least it is visible in the lists of entities) but cannot be added to a level anymore.

I say anymore because I was able to add it at some point in time before changing a great amount of code on it.

The annoying part is that the entity is perfectly ok in my eyes, I still have the level from when I could add it and it works perfectly fine, it's just impossible to add another one anywhere or even load the old level in weltmeister.

The code for this entity is pretty complex so I don't expect anyone to look into it,
however I would like to know if anyone has already had similar problems and what the cause was?

It must be something in the entity code that is wrong to weltmeister but not when actually running the game.

thanks in advance,

Sleenee

1 decade ago by MikeL

Did you check the browser's error console while running Weltmeister? I have had certain errors which show up in Weltmeister and block the program from being used.

1 decade ago by igr

Had the same experience. If there are errors in the console Weltmeister can behave strangely. Fix the errors first.

1 decade ago by dominic

To quote myself from this thread:
Weltmeister calls the init() and draw() method for each entity, so you have to make sure there, to guard stuff that should only run in the actual game with an if-statement:

if( !ig.global.wm ) {
    // Do something only when NOT running in Weltmeister
}

1 decade ago by sleenee

Indeed Dominic, putting most of my init-code behind this if-clause seems to do the trick.

thanks alot

Sleenee

1 decade ago by aandnota

I have this issue, too.

These are the errors I'm getting in Weltmeister:

Uncaught TypeError: Cannot read property '0' of undefined jquery-1.7.1.min.js:3
f.event.dispatch jquery-1.7.1.min.js:3
h.handle.i
Page 1 of 1
« first « previous next › last »