There is that top right generator (made of blocks). When your electric rays (also made of blocks) hit it, it draws a blank sprite (first empty frame of "explosion") over it and detects the object, it picks it up and redraws the generator crashed using blocks, the explosion then goes on exploding
When I place the object over the generator, a blank one with dark red, it paints all those four block´s, including the lower black parts, hence why I would like an object with no visual data, but able to be detected. I have tried different approaches, but this one seemed like the most economic way to do the feat. The object # is also used to turn off its respective force field.
It is for aesthetic reasons, if that could be made, more colours could be used instead of 2 for the generator element and possibly others.
EDIT: Here is a video with it in action, notice how the empty object paints the 4x4 blocks on the generator with 2 colours. If fully empty could be achieved, I could use a max 8 colours there, 2 per block.
1) Create the generator as a sprite 2) Create four blank blocks each one set to have the desired two colours 3) Put the 4 blank blocks on the screen where you want to put the generator 4) Detect a collision with the generator sprite if hit by the ray 5) Switch the generator sprite type to the explosion sprite type 6) Do the PUTBLOCKs to replace the waterblocks with the broken generator 5) use GET x where x is the Object number that triggers the force field shutdown.
If you like, feel free to PM me the relevant bits of code and I'd be happy to take a look
There is up to 3 generators on screen. If using sprites, then I would need 3. Player is made of 2, while on elevators, another one is used. That would mean 6 sprites out of 9? Or would the 3 generator sprites be considered 1? If so, than that sure is a solution candidate
I thought of using objects as they seemed easier when dirty pixels is a concern, I end up having 3 dummy objects that way. Sprites I was saving for the more action elements to come.
Thanks again for the help!
edit: hmm, it occurred to me that I would need the 3 sprites as their image number is needed to locate the force field.
MPAGD, yep I read about the sprite limits, and some of the bugs here actually generated them... and it looked awesome, every block of the ray has an explosion going The double sprite has tearing when going up/down... hence I decide to add a multi feature Batman belt to him to try to hide it a bit. It is those times a design solution works better than attempting a code solution. Sideway movements were also quite troublesome, it seems adding or subtracting behaves a bit differently than normal math, but also consider I´m a noob on MPAGD so I´m probably doing stuff weirdly.
The object system together with the shock gun and field and explosion took quite a while to do, lots of trouble. Since it is now working and I´m short on time, I will prefer to use less colours unless I can find a way to use it transparently. Changing it will probably break something else
Again, super thanks for the help, I never tire of recommending your tutorials, they are the best!
Thanks man, your tutorials were a must for this to happen. While I know BASIC, it is not quite a straight forward conversion. If I ever get this done, you are a strong part of it.
Also, I did a little system to push crash and beep sounds to LOOP2, in order to have more control on the sound priorities. Also the generators are nothing more than levers that achieve a change in a different location on scenery. If any of those, as well as the shock gun, may help your tutorials, at least as an alternative, let me know so I will share it with you.