Player vs Player tvOS Games

所在平台: Udemy

课程主页: https://www.udemy.com/course/how-to-program-player-vs-player-tvos-games/

课程评论:没有评论

第一个写评论        关注课程

课程简介

**课程名称:** tvOS 玩家对战游戏 **课程概述:** 本课程旨在教授如何为 tvOS 创建支持多玩家对战的游戏。课程内容涵盖以下重点: * **控制器连接与管理:** * 查找已连接的控制器。 * 定义不同按钮的功能。 * 设置玩家索引(如“玩家 1”、“玩家 2”等)。 * 处理控制器的连接和断开。 * 确保控制器正确分配给玩家。 * **多玩家游戏开发:** * 使用 Swift 和 Sprite Kit 代码实现对多个扩展/标准游戏手柄(包括 Micro Gamepad)的支持。 * 实现本地多人对战(同一房间内的玩家)。 * 控制玩家身份和角色分配。 * 开发单人模式,允许 CPU 控制第二个玩家。 * **游戏功能实现:** * 添加游戏暂停菜单,提供返回主菜单或继续游戏的功能。 * **游戏玩法:** * 碰撞检测。 * 生命值递减。 * 失去生命/重新开始回合。 * 其他适合双人游戏的机制。 **更新说明:** 本项目源文件已更新至 Swift 3。如果您按照视频内容进行实践,Xcode 8 的自动建议功能将帮助您轻松过渡到 Swift 3。

课程评论(0条)

课程详情

***SOURCE PROJECT FILES UPDATED FOR SWIFT 3 (see change notes below) In the first section of videos, you'll learn how to find connected controllers, define which buttons do what, set player indexes (i.e. Player 1, Player 2, etc) and work with a basic character. In section 2, you'll learn the Swift / Sprite Kit code to work with multiple Extended / Standard Gamepad controllers (as well as the Micro Gamepad controller), to go head to head versus players in the same room. After we look at the finer points of connecting and disconnecting controllers and getting each in the right player slot, we'll discuss how to control who is who in any type game, and even go into a one-player mode where the CPU takes control of the second player. This way your two-player game can also be enjoyed by single players. We'll also discuss adding a Pause menu to your game, where players can go back to a Main menu or keep on playing. Now that we've covered all our bases in terms of controlling each player and dealing with controllers disconnecting and reconnecting, section 3 allows us to have some fun. This session we'll loosen things up a bit and just talk game play. Topics include collision detection, decrementing health, losing lives / restarting rounds, and other topics worthy of a good two-player game! ***CHANGE NOTES FROM SWIFT 2 to 3 We've included updated source files for Swift 3. If you choose to follow along, line-by-line with the video code, you should have no problems, as Xcode 8 will auto-suggest the correct code for Swift 3.

课程标签

0人关注该课程

主题相关的课程