Posted by: xSicKxBot - 12-06-2020, 02:45 AM - Forum: Python
- No Replies
Python bool() Function
Python’s built-in bool(x) function converts value x to a Boolean value True or False. It uses implicit Boolean conversion on the input argument x. Any Python object has an associated truth value. The bool(x) function takes only one argument, the object for which a Boolean value is desired.
Argument
x
A Python object for which a Boolean value should be determined. Any Python object has an associated Boolean defined by the method object.__bool__().
Return Value
True, False
Returns a Boolean value associated to the argument x. The object will always return True, unless: The object is empty, like [], (), {} The object is False The object is 0 or 0.0 The object is None
But before we move on, I’m excited to present you my brand-new Python book Python One-Liners (Amazon Link).
If you like one-liners, you’ll LOVE the book. It’ll teach you everything there is to know about a single line of Python code. But it’s also an introduction to computer science, data science, machine learning, and algorithms. The universe in a single line of Python!
The book is released in 2020 with the world-class programming book publisher NoStarch Press (San Francisco).
You can observe multiple properties of the bool() function:
You can pass any object into it and it will always return a Boolean value because all Python objects implement the __bool__() method and have an associated implicit Boolean value. You can use them to test a condition: 0 if x else 1 (example ternary operator).
The vast majority of objects are converted to True. Semantically, this means that they’re non-empty or whole.
A minority of objects convert to False. These are the “empty” values—for example, empty lists, empty sets, empty tuples, or an empty number 0.
Summary
Python’s built-in bool(x) function converts value x to a Boolean value True or False.
The bool(x) function takes only one argument, the object for which a Boolean value is desired.
Where to Go From Here?
Enough theory, let’s get some practice!
To become successful in coding, you need to get out there and solve real problems for real people. That’s how you can become a six-figure earner easily. And that’s how you polish the skills you really need in practice. After all, what’s the use of learning theory that nobody ever needs?
Practice projects is how you sharpen your saw in coding!
Do you want to become a code master by focusing on practical code projects that actually earn you money and solve problems for people?
Then become a Python freelance developer! It’s the best way of approaching the task of improving your Python skills—even if you are a complete beginner.
The 242nd GalaQuiz will be LIVE soon, win up to $50 in GalaCredit!
[www.indiegala.com] The GalaQuiz will take place in less than 120 minutes from this announcement Today's GalaQuiz[www.indiegala.com] hints are up. The theme will be Freebie #4 Redux Redux.
Wave Engine recently released version 3.1. Wave Engine is a completely free to use 3D game engine capable of targeting most platforms and XR devices. We have been keeping an eye on this engine since 2015 when we featured it in the Closer Look series. More recently we looked at Wave Engine again in 2019 when WaveEngine 3.0 was previewed after a long period of silence. After another long period of silence we received the 3.1 release which brings .NET 5 and C# 9 support as well as graphical improvements.
We are glad to announce that, aligned with Microsoft, we have just released WaveEngine 3.1 with official support for .NET 5 and C# 9. So if you are using C# and .NET 5, you can start creating 3D apps based on .NET 5 today. Download it from the WaveEngine download page right now and start creating 3D apps based on .NET 5 today. We would like to share with you our journey migrating from .NET Core 3.1 to .NET 5, as well as some of the new features made possible with .NET 5.
From .NET Core 3.1 to .NET 5
To make this possible we started working on this one year ago, when we decide to rewrite our low-level graphics abstraction API to support the new Vulkan, DirectX12 and Metal graphics APIs. At that time, it was a project based on .NET Framework with an editor based on GTK# which had problems to support new resolutions, multiscreen or the new DPI standards. At that time, we were following all the great advances in performance that Microsoft was doing in .NET Core and the future framework called .NET 5 and we decided that we had to align our engine with this to take advantage of all the new performance features, so we started writing a new editor based on WPF and .NET Core and changed all our extensions and libraries to .NET Core. This took us one year of hard work but the results comparing our old version 2.5 and the new one 3.1 in terms of performance and memory usage are awesome, around 4-5x faster.
Now we have official support for .NET 5 and this technology is ready for .NET 6 so we are glad to become one of the first engines to support it.
In the video below we review Wave Engine 3.1. All of the samples used in the video are available on GitHub. Please note this repository should not be cloned, it simply links to a different repository for each sample.
Deal alert: Apple’s latest iPad (8th Gen) on sale for $299
Apple’s new 8th Generation iPad is back on sale for $299 at Amazon, with inventory expected to be in stock by Dec. 13 for Christmas gift-giving.
Pick up Apple’s standard 32GB 2020 iPad (Wi-Fi) in Gold for $299, a $30 discount off retail. Or opt for the 128GB version for $395 and save $35 off MSRP. Both of these deals deliver the lowest 10.2-inch iPad prices available on the latest models with delivery dates at press time scheduled just in time for Christmas.
Review: John Wick Hex – Stylish Turn-Based Action With Too Many Rough Edges
John Wick Hex is a rather clever turn-based action/strategy effort that sees you step into the blood-caked boots of Keanu Reeves’ stylish and unstoppable killing machine – a man who’s always ready, willing and more than able to punch, kick, shoot and fling his gun at the heads of as many bad guys as it takes to do the bidding of the High Table of Assassins.
There are some really neat ideas and a nifty time-manipulation mechanic at the core of this one that can do a great job of making you feel as though you’re taking part in carefully choreographed fight sequences straight out of the movies – however, it’s all held back somewhat by slightly unreliable mechanics, janky character animations and a lack of variety running through its seven somewhat samey levels.
The story that’s told here ties nicely into the events of the John Wick movie franchise, and fans will no doubt be pleased to see the likes of Ian McShane and Lance Reddick reprise their roles as Charon and Winston, with Troy Baker also joining in the fun as the titular Hex, an angry man with a bloody score to settle. It’s all told through graphic novel-style cutscenes that bookend each of the action-packed levels and, although it doesn’t particularly go anywhere interesting or throw up any real surprises, it certainly gives proceedings a nice air of authenticity having the actors from the movies lend their voices to the tale – and Austin Wintory’s score does a fantastic job of setting the right mood.
Kicking off with a very quick tutorial, John Wick Hex wastes no time in flinging you into its turn-based battles, giving you a quick overview of its tricksy timeline mechanic, tactical options, movement, focus points, gunplay and so forth. Upon jumping into a level, you’ll find yourself in a Superhot-style world where time is paused until you make a movement. You pick your way across enemy-infested areas via nodes and slowly reveal your surroundings which are covered in a fog of war that hides your foes beyond a certain distance. Once you’ve got your eye on a bad guy, you can choose to take them out by shooting from range – an action which will draw the attention of anyone within earshot – or, more preferably, get up close and personal for some of Wick’s signature CQC bad-assery.
Where shooting an enemy may be loud, it’s also quick and easy, and doesn’t cost you any of your precious focus points – a vital resource for pulling off close-range strikes, takedowns or flashy stunt-rolls that can pull you quickly out of range of a bullet, foot or fist. Focus points can be replenished by finding a quiet spot and some space to refocus Wick, an action which results in him shaking his head in a very “woah, dude” Keanu way, giving you a fresh bar of points with which to take down anyone dumb enough to get too close.
Every single action you take in John Wick Hex also takes a certain amount of time to complete, a factor which is indicated via a timeline sat at the top of your screen. John has his own timeline and any enemies he’s currently engaging with also have their incoming action times represented alongside. An assailant who’s about to pull the trigger or throw a fist at you will have the duration of that action flagged up, giving you the opportunity to cycle through your choices in order to find a counter-measure that can be pulled off quick enough to beat them to the punch or interrupt their action. A parry is a quick option that will beat an incoming attack if you’re fast enough to get it in, for example, and simply stepping to the nearest node, crouching or rolling is a fairly reliable way of dodging a bullet.
The more complex the manoeuvre you want to pull off, the longer it takes to complete, with bandaging up wounds to heal yourself, reloading your gun or performing sick takedowns the most expensive options in this regard. It’s all very simple to understand and, when it’s flowing well, it does a fantastic job of making you feel like you’re a stone-cold killer capable of taking down a gangster, stunt-rolling across the floor to pick up a discarded gun and rising to your feet just in time to throw it at an incoming goon, nailing him right between the eyes before finishing him off with some CQC. Once you’ve completed a level, you can then watch the entire thing back in a replay from various camera angles, an element that would have really added an addictive, perfectionist aspect to things if it wasn’t for the fact it looks so glitchy and janky as it plays back your performance.
Indeed, there’s a level of jankiness here that really begins to eat into your enjoyment of John Wick Hex as time goes on. Animations are stiff and shoddy, replay camera angles are glitchy and enemies have a tendency to disappear into the fog of war when it seems you should definitely still be able to see them. More frustratingly, bad guys also often appear, as if out of nowhere, from a direction you’ve just been through and cleared out; this leads to frustrating deaths, with your best-laid plans falling apart in the process; stealth comes across as rather pointless when you get caught out by some unseen foe emerging right in front of your face.
As we already mentioned, there’s also a real lack of variety to proceedings; the core gameplay is undoubtedly quite fun, but what you’re doing in the opening level is more or less exactly what you’ll be doing by the time things wrap up some six or seven hours later. Yes, there are some tougher armoured bad guys who take more of a beating and a handful of bosses who you’ll need to grapple with in order to whittle down their focus levels before finishing them off but, overall, you’ll find yourself utilising the same small number of manoeuvres against the same small selection of grunts from start to finish. Randomized enemy patrol routes help to alleviate this repetition to an extent, and this is the kind of game that encourages you to perfect a level from start to finish, but – especially for the rather steep asking price on Switch – there really isn’t a lot to this one when all is said and done.
Performance in this Switch port is, thankfully, on a par with the PC and PS4 versions of the game with everything running smoothly in both docked and handheld modes – so if you’re already a fan you’ll be pleased to find this one arriving here in decent shape – but we just can’t help wishing there was more care taken with the finer details as this is so close to being a cracking little movie tie-in. With a bit more fluidity to those animations and replays, more variety over the seven levels on offer, some meaningful stealth and enemies who perform a tad more reliably overall, this would be an easy recommendation. As it stands, it’s a very clever idea that’s fun for a time, but winds up feeling fairly middle-of-the-road thanks to some disappointingly clunky execution.
Conclusion
John Wick Hex is a clever turn-based strategy offering with some cool mechanics that, when everything comes together, can absolutely make you feel like you’re Keanu Reeves’ unstoppable assassin, kicking, punching and shooting your way through an endless procession of hapless goons. However, there’s an unpolished element to proceedings, with a lot of repetition across the seven levels on offer, janky animations, shoddy replays and some unreliable AI behaviour that begins to grate after a time. With some more variety and a touch of polish, this could have been a really nice little movie tie-in, however, as it stands it’s just alright; a brilliant idea that needed more time in the oven.
Destiny 2's Trails Of Osiris Is Finally Coming Back--But Not This Week
Destiny 2's toughest multiplayer challenge, the Trials of Osiris, has been disabled for more than a month. Bungie says it has found the issue that led it to cancel Trials soon after the release of the Beyond Light expansion, and we now have a date for when we can expect Trials to return: December 18.
Bungie released the date on Twitter alongside its This Week at Bungie blog post. The fix for the issue is coming in a future update--but since Bungie didn't identify it as part of a hotfix coming to the game on December 8, we can probably expect the patch with the weekly reset on December 15.
The team has identified the issue and is currently developing a future Hotfix. Trials of Osiris is currently planned to return on 12/18. https://t.co/tfGUvyG2lL
Trials of Osiris is the peak player-vs.-player challenge that Destiny 2 offers, with loot rewards to match. Available only on weekends, it requires players in teams of three to take on other teams in a series of elimination matches. The goal is to win seven matches in a row without losing any, which is known as "flawless." Starting with Beyond Light, teams that can manage a flawless Trials run can win special Adept weapons, which offer stat boosts that aren't available anywhere else in the game.
BFF or Die: Finding the Best Friends in Your Household
Summary
BFF or Die is a couch co-op game that you can enjoy with friends, family, and your significant other.
Sitting around the TV together you’ll have fun playing as time traveling aliens who help each other survive through ancient Egyptian mazes, puzzles, and dangers.
For our team of three, this is a big deal — our passion project is coming out on Xbox One!
I’m Shaz, the game designer of BFF or Die. As a lifelong gamer, I’ve grown up playing video games. My most memorable gaming moments come from when I used to meet up with a group of four friends and play local multiplayer games all weekend. I look back on those times fondly – they made me appreciate how gaming can be the social glue to build lasting friendships.
We’ve been developing BFF or Die for a long time. We started out with a demo and took it out to some local events where indie developers meetup to talk about games, make friends, and learn from each other. People really seemed to have fun playing together, even as a super early demo with no graphics. Those first playtest sessions made us want to make it into a proper console game.
That dream marked the beginning of a road that led us… here! Over four years we continued to take it around gaming events in the UK, seeing thousands of people play it throughout all stages of development. Their reactions shaped the game and helped us figure out which features to keep or change.
We took the demo out to some great events like EGX and Insomnia Gaming Festival. Encouragingly, it won a few awards like Best Multiplayer Game in GameOn 2.0! In those early days, BFF or Die was relatively unpolished. We were making it in our spare time which took a lot of perseverance as we didn’t have any financial backing. At the same time, we were all working “normal” day-jobs so that we could afford to make this game.
Further into our development journey, we received some amazing news – the UK Games Fund had selected BFF or Die to be one of the few games to receive funding that year! That kicked us into gear and we were able to spend more time on the project, re-work the code, improve the art style, and polish the gameplay. We also formed ASA Studio, our company name based on the first letters of our forenames.
Things seemed to be going well. We self-published on PC, gathered feedback, and made some much-needed updates! The excitement from streamers and players made all the effort worthwhile. After a few more changes to the game in collaboration with our new publishing friends over at 2Awesome Studio, BFF or Die is now available for you to play on Xbox One.
We really hope you have fun playing it, whether you try in single-player mode or in local co-op mode with a friend. Once you beat the story mode there’s an “infinite trials” mode. I can get about 8 challenges into the infinite trials before I die – see how far you can get!
BFF or Die
2Awesome Partners
☆☆☆☆☆
★★★★★
$7.99$6.79
BFF or Die is a cozy and crazy cooperative puzzle game that you can play with up to four players! You’re a time traveling alien sent to Earth on a risky rescue mission. Utilize your gadgets to overcome danger and survive! As time traveling aliens, you must venture to a strange planet called “Earth” in order to rescue the Orbees, a mysterious species who help you build your crucial set of gadgets. Take charge of each gadget, combine your abilities and strategize to save your friends. Use your cunning wit and camaraderie to survive, but never forget the Academy motto: “BFF or Die!” If you love couch co-op’s with friends and family then BFF or Die is for you! BFF or Die in 2-4 local player mode is a completely new and amusing cooperative experience. A mix of puzzles and action gameplay will make you think carefully and sometimes – panic in excitement!
In this 2017 GDC talk, Two Hat Security’s Chris Priebe explains the impact that trolling and toxic behavior have on a game’s success from a business perspective, and how companies can properly manage toxic players.
In addition to this presentation, the GDC Vault and its accompanying YouTube channel offers numerous other free videos, audio recordings, and slides from many of the recent Game Developers Conference events, and the service offers even more members-only content for GDC Vault subscribers.
Those who purchased All Access passes to recent events like GDC already have full access to GDC Vault, and interested parties can apply for the individual subscription via a GDC Vault subscription page. Group subscriptions are also available: game-related schools and development studios who sign up for GDC Vault Studio Subscriptions can receive access for their entire office or company by contacting staff via the GDC Vault group subscription page. Finally, current subscribers with access issues can contact GDC Vault technical support.
Best of 2020: Behind the dizzying ride to the top for Among Us
<!– –>
Gamasutra: Simon Carless’s Blog – Behind the dizzying ride to the top for Among Us
Gamasutra is part of the Informa Tech Division of Informa PLC
This site is operated by a business or businesses owned by Informa PLC and all copyright resides with them. Informa PLC’s registered office is 5 Howick Place, London SW1P 1WG. Registered in England and Wales. Number 8860726.
If you enjoy reading this site, you might also want to check out these UBM Tech sites:
The following blog post, unless otherwise noted, was written by a member of Gamasutras community. The thoughts and opinions expressed are those of the writer and not Gamasutra or its parent company.
Had originally planned a round-up, but it turns out something else came up that I just had to write about. You may recall me mentioning, in the last newsletter, the amazing ‘out of the blue’ success of multiplayer party game Among Us on Steam. (It’s the top global seller right now.)
Well, somebody was kind enough to point out that the Brace Yourself Games Discord has a ‘Clark Tank’ chat channel – twinned with Ryan Clark’s Twitch stream/YouTube videos on game discoverability.
Turns out Forest (ForteBass on Twitter!) of Among Us devs InnerSloth had been sharing his story there. So I got permission from ForteBass to share some of his insight with you all, which I augmented with research. (Yes, Ryan, I’m sneaking around your Discord server stealing content now!)
What’s the big deal, anyhow?
I’ve been watching YouTube videos of Among Us, and it plays so, so well as a social online game. It has big influence from Mafia/Werewolf, obviously, but also reminds me of a ‘you’re actually in the world’ version of Spaceteam.
The tension as you wander around the level trying not to get killed (if you’re not the impostor!) while accomplishing tasks is great. And then voting off potential impostors really ups the ante. Check out this video from Blitz if you want to get a good idea of the social dynamics at play:
So, some background. Among Us actually launched in June 2018 on Android and July 2018 on iOS. After launching in November 2018 on Steam, and having an extremely slow start there, the game has just exploded in recent weeks – in ways almost unprecedented on Steam for a title that’s been available for some time.
Just check out Among Us’ reviews graph on its Steam page since launch.
On Steam the game is only priced at $4.99, but it also has a bunch of DLC such as in-game pets. You can see a similar but slightly later ‘reviews explode’ effect on Android for the Google Play version of the game (amusingly, the URL is ‘Space Mafia’), if you look on SensorTower:
Interestingly, Among Us is free on Android and iOS, where it monetizes with similar cosmetic IAP as the Steam version. And it turns out that even ignoring the recent spike, there were millions of downloads on mobile – especially Android – before the game broke out on Steam. (SensorTower is estimating 11 million Android downloads, even ahead of this big August 2020 boost.) I had no idea about this.
ForteBass’ comments bear this out: “It’s the end of 2019. America and Europe are not our big customers: Brazil, Korea, and the Middle East are. Google Play is our breadwinner & IAP for maps and pets are why.”
So it turns out that YouTubers have covered this game extensively before, just not English-language ones. Some of those early spikes “..started with Godenot (3.6M sub Youtuber) [earlier in 2019] who found our game on Google Play (probably recommended by players? Possibly via Itch.io, even… I know he streamed from mobile before switching to PC.) We had considered wrapping up Among Us back then, because profitability was not in sight. But the Brazilian audience drove us to create more content, and that was wise.”
As for another major territory in question: “Our first audience was Korea, and they still constitute 50% of our Steam Among Us sales. That all started in Dec 2018 with Kevin Choi. He found Among Us via itch.io, and I think that’s because we got a day of promotion on the front page. This is literally the only promotion we have expressly asked for.”
So as we can see, Among Us was popular and had good retention in other territories way before this big viral spike in North America and Europe. But it looks like those who saw streamers playing the game gravitated towards the free mobile version – also because those territories play more mobile than PC games. And heck, the game hit a million downloads overall in May 2019. So, it wasn’t exactly ‘unknown’.
Taking it over the top on Steam
Was there any hint that the game could also do well on Steam? Well, yes – not least because Valve itself took notice. ForteBass takes up the story here: “In February 2020, Steam reached out to us for a daily deal, and we went for 50% off. If I remember rightly, each of those two days produced an entire month of sales, and left us with a higher baseline of sales after, as well as a boatload of wishlists. So that in turn made our Summer sale worthwhile – which snowballed into minor top seller visibility. (#35-ish).”
So, sounds like the Steam featuring helped step the game up visibility-wise. And at this point, Among Us – which was already great – had been polished and had extra maps, pets, and many rounds of bugfixes in place. So it was well set-up to break out, if somebody noticed it.
ForteBass speculates: “But why did we get a daily deal [in Feb]? Well, I didn’t ask, but at the beginning of the year, Kaif (a… UK streamer) and his friends picked us up. We were already profitable by that point and actually had just announced Among Us as complete, which caused a sizable drop off of players. Kaif completely reversed that and brought in a wave of new European players (a new-ish market for us), particularly on Steam (which was our #2 marketplace at that time).”
And that gets us to the current day. Or at least to mid-July, where things got really crazy for the team. Rounding the story off: “First, yes, Twitch streams are the cause of our [most recent] spike. This started just after the Steam Summer sale, which is actually pretty important for us as a 2 year-old game which cost 5 dollars that has already reached 75% off. Pluto and Sodapoppin’s timing was impeccable… I haven’t talked to Pluto yet, but I’d bet that he found Among Us during the 2020 summer sale, which frankly, is the only Big Steam Sale that’s gone well for us.”
And indeed, Reddit sleuths have pinpointed the exact Twitch VOD where everything took off. Sometimes it takes one big streamer to ignite his peers, and looks like that’s what happened in this case. (Among Us is particularly good for streamers because it pulls in the ‘play with your streamer buddies, and you can cross-promote between your channels’ thing. Plus – the drama!)
Conclusion – the path to the top goes where?
Well, I have to say that my research in writing this article didn’t go where I expected. The team behind Among Us made a really amazing game that succeeded in a very unconventional way across a free mobile and an inexpensive PC version.
It rode multiple viral streamer waves while the team desperately upgraded the infrastructure to keep up, it constantly improved, and it’s a great (and vanishingly rare?) example of a multiplayer-only title that’s not an obvious Fortnite-y AAA beast becoming a smash.
As ForteBass notes, the odds are often stacked against multiplayer-first titles: “I initially didn’t want to make Among Us because of the multiplayer aspects. We had seen stuff like Bombernauts flop and the added complexity of multiplayer made it really unappealing. But our other game idea wasn’t panning out, so I prototyped Among Us and it was immediately fun and interesting.”
So if you really want to go for it with multiplayer, you have to have all of the right elements in place. ForteBass concludes: “Everything else has been patience, a high retention game, and frequent public updates. Discord is very important for this. It goes nuts when we announce literally anything.”
So, onward – and congrats again to Forest and his team, who are planning a sequel and all kinds of good things. And good luck to ‘em!
Destiny 2's Prophecy Dungeon Coming Back With Next Update
The Prophecy dungeon launched in Destiny 2 back in June, adding another inventive, high-level activity to the game that wasn't one of its six-player raids. But when the Beyond Light expansion was released, a whole slate of Destiny 2 content was removed from the game, with no information as to when (or if) it might return. Prophecy wasn't quite in the same boat as destinations like Mars, Mercury, Titan, Io, and the Leviathan--Bungie always said it would come back after Beyond Light's release--but we didn't know exactly when, until now.
Bungie included an update on Prophecy's return in its latest This Week at Bungie blog post. We now know that Prophecy will be back in the game very soon: December 8. That's the date of the game's next weekly reset, which will see a new patch, Update 3.0.1, that fixes some issues and adds a few extra elements along with Prophecy.
Those extra goodies are the next-generation upgrades that Destiny 2 will receive for PlayStation 5 and Xbox Series X/S players. Right now, the game is available on both platforms, but only as the backwards compatible version for the PlayStation 4 and Xbox One. The update coming to Destiny 2 on December 8 upgrades the game for next-gen players, amping up framerates to 60 fps, offering 4k resolutions, and speeding up load times.