/*Instructions:
To use this, simply open up the dev console (in Chrome and Firefox, this is done with CTRL+SHIFT+I)
Select all in this file, then literally copy-paste it into the console that comes up, and hit enter.
Call the function by writing it's name, and subbing out the parameter names for the values you want to use, for example:
stripAllToLevel(2)
*/
/* Suits:
* 0: Spades
* 1: Hearts
* 2: Clubs
* 3: Diamonds
*/
var spnati_cheat_suits_list = [0, 1, 2, 3]
function validSuitOrDefault(suit, def){
/* Takes a suit as input. If the suit isn't a valid SPNATI suit name, then the specified default value is returned instead.
suit - The suit string to test.
def - The default value to return in the invalid case.
*/
return (spnati_cheat_suits_list.indexOf(suit) !== -1) ? suit : def;
}
function stripAllNaked(){
/*Strip everyone (except the PC) naked such that one round is left before they lose.*/
stripAllToLevel(1);
}
function stripNaked(player){
/*Strip all layers off of a given player (0 is the PC, 1-4 are NPCs).
Params: player - Integer (0 is the PC, 1-4 are NPCs)
*/
stripToLevel(player, 1);
}
function autoWin(){
/*Automatically win.*/
stripAllToLevel(0);
}
function stripAllToLevel(level){
/*Strip all players (except the PC) down so that they have at most _level_ number of layers left.
Params: level - Integer (The number of layers to leave left on a player.)
*/
for(var i = 1; i < players.length; i++){
stripToLevel(i, level);
}
}
function stripToLevel(player, level){
/*Strip a player down such that they only have (at most) a certain number of layers left.
Params: player - Integer (0 is the PC, 1-4 are NPCs)
level - Integer (The number of layers to leave left on a player.)
*/
for (var c = countClothing(player); c >= level; c--){stripChoice(player);}
}
function countClothing(player){
/* Count the clothing the player has remaining.
Params: Player - integer (0 is the PC, 1-4 are NPCs)
*/
var clothes = 0;
for (var i = 0; i < players[player].clothing.length; i++) {
if (players[player] && players[player].clothing[i]) {
clothes++;
}
}
return clothes;
}
function multiStripChoice(player, times){
/* Strip the indicated player of multiple layer.
Params: Player - integer (0 is the PC, 1-4 are NPCs)
times - integer (The number of layers to try to strip.)
*/
for(var i = 0; (i < times) && (countClothing(player) != -1); i++){
stripChoice(player);
}
}
function stripChoice(player){
/* Strip the indicated player of a single layer.
Params: Player - integer (0 is the PC, 1-4 are NPCs)
*/
stripPlayer(player);
updateAllGameVisuals();
}
function randomBackground(){
/*
Choose a random background from those available.
*/
//Note this randint helper function could either be inlined or broken out into an actual function.
var randint = function(a,b){
return (function(n,x){
return Math.floor(Math.random()*(x-n)+n);
})(Math.min(a,b), Math.max(a,b));
};
setBackground(function(){var a = randint(0,23); console.log(a); return a;}());
}
function unlockAllEndings(){
/*
Unlocks all the endings in the gallery mode.
NOTE: You can access the gallery by using the
command "loadGalleryScreen()" from the main menu.
*/
for(var i = 0; i < galleryEndings.length; i++)
{
galleryEndings[i].unlocked = true;
}
}
function givePlayerRoyalStraightFlush(player_number, suit){
/*
Gives the target player a royal straight flush of any desired suit.
player_number - An integer representing the player index getting the cards (0 -> player, 1-4 -> npcs)
suit - An integer representing the suit (options are shown in the suits array)
*/
var chosen_suit = validSuitOrDefault(suit, spnati_cheat_suits_list[0]);
players[player_number].hand.cards = [new Card(chosen_suit,10), new Card(chosen_suit,11), new Card(chosen_suit,12), new Card(chosen_suit,13), new Card(chosen_suit,14)]
}
function giveSelfRoyalStraightFlush(suit){
/*
Gives the player a royal straight flush of the target suit.
suit - suit - An integer representing the suit
*/
givePlayerRoyalStraightFlush(0, suit);
}
function makeLose(player_number){
players[player_number].hand.cards = [new Card(2,2), new Card(2,3), new Card(2,4), new Card(2,5), new Card(3,7)]
}
//not updated
var givePlayerRoyalStraightFlushFunctorMap = function(){
//This auto-gens a lookup table for the enableAutoRoyalStraightFlush functions.
var map = {};
for(var i = 0; i < players.length; i++){
map[i] = {}
for(var j = 0; j < spnati_cheat_suits_list.length; j++){
map[i][spnati_cheat_suits_list[j]] = function(i, j){return function(){givePlayerRoyalStraightFlush(i, spnati_cheat_suits_list[j])};}(i,j); //This double annon function is because closures in javascript are weird.
}
}
return map;
}();
//not updated
function enableAutoRoyalStraightFlush(player_number, suit){
/*
Constantly gives the player a royal straight flush of the chosen suit, every single turn.
Note if this is done multiple times for different suits on the same player, only one of the suits will be shown
depending on order of application.
player_number - An integer representing the player index getting the cards (0 -> player, 1-4 -> npcs)
suit - A string representing the suit (either "heart", "clubs", "spade" or "diamo")
*/
suit = validSuitOrDefault(suit, spnati_cheat_suits_list[0]);
document.getElementById("main-game-button").addEventListener("click", givePlayerRoyalStraightFlushFunctorMap[player_number][suit]);
}
//not updated
function disableAutoRoyalStraightFlush(player_number, suit){
/*
Disables a previously set "enableAutoRoyalStraightFlush" for a particular player and suit.
player_number - An integer representing the player index getting the cards (0 -> player, 1-4 -> npcs)
suit - A string representing the suit (either "heart", "clubs", "spade" or "diamo")
*/
suit = validSuitOrDefault(suit, spnati_cheat_suits_list[0]);
document.getElementById("main-game-button").removeEventListener("click", givePlayerRoyalStraightFlushFunctorMap[player_number][suit]);
}
//not updated
function disableAllAutoRoyalStraightFlush(player_number){
for(var i = 0; i < spnati_cheat_suits_list.length; i++){
document.getElementById("main-game-button").removeEventListener("click", givePlayerRoyalStraightFlushFunctorMap[player_number][spnati_cheat_suits_list[i]]);
}
}
//not updated
function enableSelfRoyalStraightFlush(){
enableAutoRoyalStraightFlush(0, "heart");
}
//not updated
function disableSelfRoyalStraightFlush(){
disableAutoRoyalStraightFlush(0, "heart");
}
Spnati Cheats updated - Pastebin.com (2024)
Top Articles
German Christmas Cookie Recipes
How to Best Pair co*cktails with a Dinner Menu
Skylar Vox Bra Size
Nehemiah 4:1–23
Www.metaquest/Device Code
PRISMA Technik 7-10 Baden-Württemberg
Craigslist Mexico Cancun
Evita Role Wsj Crossword Clue
Violent Night Showtimes Near Amc Fashion Valley 18
Heska Ulite
Jesus Revolution Showtimes Near Chisholm Trail 8
Best Private Elementary Schools In Virginia
B67 Bus Time
Vcuapi
DoorDash, Inc. (DASH) Stock Price, Quote & News - Stock Analysis
Echat Fr Review Pc Retailer In Qatar Prestige Pc Providers – Alpha Marine Group
Cyndaquil Gen 4 Learnset
Rams vs. Lions highlights: Detroit defeats Los Angeles 26-20 in overtime thriller
Wicked Local Plymouth Police Log 2022
St Maries Idaho Craigslist
Air Force Chief Results
R Personalfinance
Panic! At The Disco - Spotify Top Songs
Hewn New Bedford
THE FINALS Best Settings and Options Guide
Scheuren maar: Ford Sierra Cosworth naar de veiling
Ou Class Nav
Inbanithi Age
Coindraw App
Publix Near 12401 International Drive
8002905511
Downtown Dispensary Promo Code
What we lost when Craigslist shut down its personals section
Ncal Kaiser Online Pay
Things to do in Pearl City: Honolulu, HI Travel Guide by 10Best
How rich were the McCallisters in 'Home Alone'? Family's income unveiled
Kacey King Ranch
Baldur's Gate 3 Dislocated Shoulder
Los Amigos Taquería Kalona Menu
Myhrconnect Kp
RUB MASSAGE AUSTIN
Mississippi State baseball vs Virginia score, highlights: Bulldogs crumble in the ninth, season ends in NCAA regional
Today's Final Jeopardy Clue
Build-A-Team: Putting together the best Cathedral basketball team
Invalleerkracht [Gratis] voorbeelden van sollicitatiebrieven & expert tips
Wunderground Orlando
Ig Weekend Dow
Hazel Moore Boobpedia
Leland Nc Craigslist
Samsung 9C8
786 Area Code -Get a Local Phone Number For Miami, Florida
Adams County 911 Live Incident
Latest Posts
Martha Washington Candy Recipe - Mom On Timeout
Super Bowl Desserts | Ideas | Ain't Too Proud To Meg
Article information
Author: Patricia Veum II
Last Updated:
Views: 6662
Rating: 4.3 / 5 (44 voted)
Reviews: 83% of readers found this page helpful
Author information
Name: Patricia Veum II
Birthday: 1994-12-16
Address: 2064 Little Summit, Goldieton, MS 97651-0862
Phone: +6873952696715
Job: Principal Officer
Hobby: Rafting, Cabaret, Candle making, Jigsaw puzzles, Inline skating, Magic, Graffiti
Introduction: My name is Patricia Veum II, I am a vast, combative, smiling, famous, inexpensive, zealous, sparkling person who loves writing and wants to share my knowledge and understanding with you.