AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Plugins (https://forums.alliedmods.net/forumdisplay.php?f=108)
-   -   [CS:S] Blackjack (Version 1.0) - Play blackjack while waiting for respawn! (https://forums.alliedmods.net/showthread.php?t=166133)

Peace-Maker 08-31-2011 02:31

[CS:S] Blackjack (Version 1.0) - Play blackjack while waiting for respawn!
 
2 Attachment(s)
Blackjack

Play your favourite casino game ingame! This is a blackjack implementation using the most common rules. Only hit, stay and doubling the bet is allowed (no split and insurances).
Ever got bored when dead and waiting for the round to end? Now you're able to make some money playing blackjack - just needs some luck :)
This plugin is based off sega74rus' eventscript version, but improved to apply the rules more strictly. Can't stress this enough - this guy does some great plugins!

Currently this is only 1 player against the dealer. No multiplayer yet :P

Player Commands:
  • sm_bj - Opens the blackjack game.
  • sm_blackjack - Alias
  • sm_bjhelp - Displays the blackjack help and settings.
Players may set the game to show automatically on death and hide on spawn in their !bjhelp menu. If clientprefs is running, the decicion is saved and restored on rejoin.

https://forums.alliedmods.net/attach...1&d=1475014075

Rules:
You are dealt an initial two card hand with the option of drawing cards to bring the total value to 21 or less without exceeding it, so that the dealer will lose by having a lesser hand than the player or by exceeding 21.
If you've a value of 21 with only your first 2 cards you've got an blackjack and always win; except if the dealer has a blackjack too.
If you exceed 21 you "overbuyed" (busted) yourself and lose. If both players have less than 21 points, the one closer to 21 wins. If both have the same value, it's a draw, except one has a blackjack and the other one just has 21 with more than 2 cards.

You've got 3 options ingame after placing your bet:
  • Hit: Draw another card.
  • Stay: Stay with your current cards and let the dealer start to draw cards.
  • Double: Double your current bet, draw one last card and stay.
Number-cards count as their natural value; the pictures count as 10; aces are valued as either 1 or 11 according to the player's best interest.
So if you have an ace on your hand and e.g. a 2 you'll see two possible values as "3/13".
Note that the dealer has to draw a card if he's less than 17 points and stops to draw if he reaches 17. He also has to count the ace as 11 if he wouldn't exceed 21 by doing so.

You win 3x your bet with a blackjack, 2x if you win and 1x on a draw. You will only lose your bet if you fail.

ConVars:
  • sm_blackjack_version - ...
  • sm_blackjack_maxbet - Set the maximal amount of money a player is able to bet per game. (Default: 5000)
  • sm_blackjack_advertondeath - Show an advert on death, if player didn't play already? (Default: 1)

Did you see...:


musosoft 08-31-2011 03:47

Re: [ANY] Blackjack (Version 1.0) - Play blackjack while waiting for respawn!
 
Awesome! Trying it right now!

edit: works excellent :) GJ!

Feature request: optional chat messages about wins & losses

Despirator 08-31-2011 04:40

Re: [ANY] Blackjack (Version 1.0) - Play blackjack while waiting for respawn!
 
what about sega74rus's IpToCity plugin, can you make it?

Peace-Maker 08-31-2011 06:44

Re: [ANY] Blackjack (Version 1.0) - Play blackjack while waiting for respawn!
 
duh, that one queries ip-whois.net.. I don't think that's that interesting :) I prefer the tetris one!

Despirator 08-31-2011 10:22

Re: [ANY] Blackjack (Version 1.0) - Play blackjack while waiting for respawn!
 
but there is need encoding to the UTF-8

delachambre 08-31-2011 10:58

Re: [ANY] Blackjack (Version 1.0) - Play blackjack while waiting for respawn!
 
Yeiiih !

Good job, thanks for plugins

Delachambre.

Leonardo 08-31-2011 13:14

Re: [ANY] Blackjack (Version 1.0) - Play blackjack while waiting for respawn!
 
how about in-game solitaire? :3

musosoft 09-05-2011 17:51

Re: [ANY] Blackjack (Version 1.0) - Play blackjack while waiting for respawn!
 
Players cheat with this when warmup ends, is there any way to disable bj at buy time? thanks :)

Peace-Maker 09-05-2011 18:24

Re: [ANY] Blackjack (Version 1.0) - Play blackjack while waiting for respawn!
 
They cheat with blackjack? How so? Kick them out of your casino!

musosoft 09-06-2011 06:08

Re: [ANY] Blackjack (Version 1.0) - Play blackjack while waiting for respawn!
 
Quote:

Originally Posted by Peace-Maker (Post 1549103)
They cheat with blackjack? How so? Kick them out of your casino!

I have mp_startmoney 800, they withdraw money after warmup round end, and get twice, so first normal round they get mp5 instead of usp and so.


All times are GMT -4. The time now is 17:44.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.