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

Basic Multiplayer Functionality #53

Merged
merged 115 commits into from Nov 28, 2015
Merged

Conversation

pastaq
Copy link
Collaborator

@pastaq pastaq commented Nov 7, 2015

Stable development branch of Tuxemon multiplayer basic functionality. Players can do the following:
1.) Host a local game
2.) Join a local game
3.) Move around within the world and remain synced with all other players
4.) Run
5.) Switch maps and remain synced with all other players
6.) "I got 99 commits and a pull ain't one"

the same time.

- Neteria is now a prerequisite module for installation.
- python-netifaces is now a prerequisite module for installation.
Universal menu navigation logic in the get_menu_event() function.
New state, PC Menu. It consists of a log off button and a multiplayer
menu. The multiplayer menu has options to host a server or autodiscover
a local server and join as a client. THere is also logic to prevent
joining your own server as a client if you wish to use a network
controller.
Added descriptions to functions.
- Multiplayer_Join_Menu added. It will populate based on the number of
detected games. Once a server is selected it will join the server.

Bug Fixes: 
- Fixed an issue where your current state could override your previous
state in change_state, putting you in a loop that prevented you from
returning to your original state.
- Fixed an issue where a menu could only return to one level previous.
if you went 2+ levels deep it could only return to the last level,
preventing you from exiting the menu's. YOu will now need to set "next
menu".previous_menu = self before switching to the next menu.
- Various minor fixes.
Conflicts:
	tuxemon/core/tools.py
	tuxemon/tuxemon.cfg
main loop of the core.tools.Control class.

Added ability for a player to populate an NPC at his location on the
server.
comparing the map of the client and the host. Now uses the relative path
IRT the map name.
spawining and moving.

TODO:
- Add more checks and events to update position and map_name on server.
Specifically add notification to the server that a client has changed
maps, moving the check out of the key event entirely.
- Game will not constantly try to stop animation of a character if it is
not animating.
- Player location will now be updated when the animation completes.
was with faulty if/then logic in the populate_client function.
development

Conflicts:
	tuxemon/resources/maps/bedroom_test.tmx
# Update the server/clients of our new map and populate any other players.
if game.isclient:
game.add_clients_to_map(game.client.client.registry)
game.client.update_player(player.facing)
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lines 128 -131 should be removed.

@pastaq
Copy link
Collaborator Author

pastaq commented Nov 8, 2015

Pull request adds two dependencies
netifaces module, sudo apt-get install python-netifaces
neteria, https://github.com/ShadowBlip/Neteria

@@ -0,0 +1,33 @@
eclipse.preferences.version=1
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please do not include IDE preferences in pull requests.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Woops. Will be removed.

@ShadowApex
Copy link
Contributor

The README.md file should also be updated to reflect the new dependencies introduced.




class PsudoAI(object):
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't this be "Pseudo"?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes.

Derek J. Clark and others added 9 commits November 15, 2015 18:34
remove file from branch for pull request
Fixed multiple issues present after code review in pull request.
Forgot to specify non-default port on the client side.
- Changed all instances of menu_event back to get_event
development

# Conflicts:
#	tuxemon/core/tools.py
- Cleaned up some mistakes from the merge.
ShadowApex added a commit that referenced this pull request Nov 28, 2015
Basic Multiplayer Functionality
@ShadowApex ShadowApex merged commit 9506882 into Tuxemon:development Nov 28, 2015
bitcraft pushed a commit that referenced this pull request Jan 6, 2020
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

Successfully merging this pull request may close these issues.

None yet

2 participants