This commit is contained in:
azw 2023-08-19 00:04:40 +08:00
parent a20f329c6d
commit 39989d56da
3 changed files with 12 additions and 25 deletions

View File

@ -8,26 +8,6 @@
#include "player.h"
class ConnectedPromise : public a8::Promise
{
protected:
virtual void DoAwait() override
{
}
};
class JoinSuccessPromise : public a8::Promise
{
protected:
virtual void DoAwait() override
{
}
};
void Player::Update()
{
@ -51,9 +31,16 @@ void Player::Init(int idx,
void Player::CoLogin(f8::Coroutine* co)
{
auto a = struct{}{};
co->CoAwait(std::make_shared<ConnectedPromise>());
co->CoAwait(std::make_shared<JoinSuccessPromise>());
co->CoAwait
([] (std::shared_ptr<a8::Awaiter> awaiter)
{
});
co->CoAwait
([] (std::shared_ptr<a8::Awaiter> awaiter)
{
});
}
void Player::CoGame(f8::Coroutine* co)

2
third_party/a8 vendored

@ -1 +1 @@
Subproject commit 0d5c381b38618310d7b438a03c8942b14c0e0725
Subproject commit 888275763feaf537f01c190b23402325ebe1f9da

2
third_party/f8 vendored

@ -1 +1 @@
Subproject commit 4384bc7ac05ef6bad5e1dfe94b7d4211b81930c0
Subproject commit 8eb3db11139b9a4d9b9056e2cd3412f7ebb48718