Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bullet patterns do nothing after instancing #2

Open
MRSEEO opened this issue Nov 5, 2021 · 8 comments
Open

Bullet patterns do nothing after instancing #2

MRSEEO opened this issue Nov 5, 2021 · 8 comments

Comments

@MRSEEO
Copy link

MRSEEO commented Nov 5, 2021

When you just open bullet pattern scene, it works. But if i add it to other project, it do nothing.
How do i should use it properly?
изображение_2021-11-06_013925

@mavsm
Copy link
Owner

mavsm commented Nov 5, 2021

Hi!
So, it could be 2 things:
1- the bullet pattern is not enabled to shoot automatically! It only does so when its the root of a scene for testing purposes. To enable it simply call enable() on it!
2- the bullet pattern scene could be outside the viewport, as its default position is not (0, 0)
If neither help, let me know!

@MRSEEO
Copy link
Author

MRSEEO commented Nov 5, 2021

now i have this error

изображение_2021-11-06_015535

@MRSEEO
Copy link
Author

MRSEEO commented Nov 7, 2021

What am I doing wrong? i keep getting this error

@mavsm
Copy link
Owner

mavsm commented Nov 8, 2021

Hey, sorry for the late response. To correct your issue you'll have t register a bullet container (the node that you want to parent all your bullets) via PatternManager.register_bullet_container( node ). It seems I introduced this after the initial commit and forgot to add it to the ReadMe, sorry.

@MRSEEO
Copy link
Author

MRSEEO commented Nov 9, 2021

I'll try it. Thank you!

@MRSEEO
Copy link
Author

MRSEEO commented Nov 10, 2021

It works, but when i trying to register a bullet target i have this error
image

@MRSEEO
Copy link
Author

MRSEEO commented Nov 10, 2021

and can i remove a screen limit? because i need 1280x720 resolution, but bullets despawning suddenly at right side of screen

@mavsm
Copy link
Owner

mavsm commented Nov 11, 2021

The bullet target (usually the player) should have a grazed function! I made this thinking about the common bullet hell game, but if you don't need this you can remove the code segments related to it. And feel free to change the bullet boundary! It's defined in PatternManager's BOUNDARY_RECT.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants