Skip to content

Twotter

In-game social media platform (Twitter-like). Create accounts, post tweets, and interact with the social feed.

No permission required.

Methods

createUser(options)

Create a Twotter user account.

typescript
Twotter.createUser({
    id: "mrx",
    username: "mr_x_official",
    displayName: "Mr. X",
    avatar: "./assets/mrx.png",
    followers: 15000,
    verified: true,
});

post(options)

Post a tweet from an account.

typescript
Twotter.post({
    accountId: "mrx",
    content: "The revolution begins tonight. #hackthecity",
});

getUser(id)

Get a Twotter user by ID.

typescript
const user = Twotter.getUser("mrx");

deletePost(postId)

Delete a tweet.

typescript
Twotter.deletePost("tweet_123");

Quest Integration

For quest-related tweets, use the TwotterAccounts and Tweets properties on the Quest class:

typescript
@RegisterQuest
class MyQuest extends Quest {

    TwotterAccounts = [
        { id: "mrx", username: "mr_x", displayName: "Mr. X", avatar: "./mrx.png" },
    ];

    Tweets = [
        { accountId: "mrx", content: "Something big is coming..." },
    ];

}

HotBunny Interactive Entertainment Inc.