Files

27 lines
863 B
Markdown
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# poker.js — schedulePokerRefresh() (satır 153)
[← poker.js](index.md) · [← Master](../../wiki.md)
```javascript
function schedulePokerRefresh(c, playerName, tableId) {
c.scheduleScript(40, function (context) {
var p = context.getServer().getPlayer(playerName);
if (p !== null) {
var uiContext = p.getUIContext();
if (uiContext !== null && !uiContext.isClosed()) {
var lobby = getLobbyData(context);
var activeTable = getTableData(lobby, tableId);
if (activeTable !== null) {
var pStates = p.getStates();
pStates.setNumber("refresh_active", Date.now());
openPokerUI(context, p, tableId);
schedulePokerRefresh(context, playerName, tableId);
}
} else {
p.getStates().reset("refresh_active");
}
}
});
}
```