Hey folks, Adam DuPay here and today we're going to be looking at the Poneable.kr challenge mem copy. This is going to be a live hack through, I have not seen this code or looked at this at all yet. So, let's jump right in. So mem copy, 10 points. Are you tired of hacking? Take some rest here. Just help me out with my small experiment regarding mem copy performance. After that, the flag is yours. There's a link here to C code which I've downloaded and then SSH mem copy at Poneable.kr So when we go here we can see the mem copy.c and we can see the readme which has the compiled binary of mem copy.c source code with the real flag will be executed under mem copy Pone privilege. If you connect to port 9022, execute the binary by connecting to the daemon. Okay, so that's how we access the flag. That's good. So let's look at this source code. So teaching Pone Devils, Poneable.kr, mem copy, all right, and this is a 10 point challenge. So let's look at this, set buffers, okay, hey, I have a boring assignment for CS class. The assignment is simple. What is the best implementation of mem copy? Implement your own slow fast version of mem copy, compare them with various sizes of data. And your experiment has made a report. This time just help me out with my experiment and get the flag so maybe this looks like it's just going to be some kind of programming assignment. No fancy hacking, I promise, I don't really believe that but let's see. So what's happening here, variables, making a private memory mapping, M mapping, I believe this is the size but I have to look at all the flags of M map. We'll see if this is important. Some source is a character pointer, setup experiment parameters, do stuff, specify the mem copy amount between low and high, gets in a size, sleep one, okay, let's run the experiment. So we actually get to specify some kind of configuration, run the experiment for i0, i less than 10, i plus plus size sizes i experiment percent d where did low and high come from interesting oh size so we specify what is it 14, wait for e equals four less than 14 plus plus. So we specify different size amounts and those go into the sizes thing and so we're going to loop over them. So that's going to be 10 so four to 14 this is zero to 10. So it should be 10. So we're going to present d so I'll lock a destination buffer of that size, mem copy, what is this cash to to cash one says to eliminate cash effect, our DT actually don't know what this does our DTSC of the assembly instruction okay I'll need to look that up what that does I don't really remember then call slow mem copy source destination size okay slow mem copy looks like this for i equals zero i less than length i plus plus destination right so copy it byte by byte RT DSE is the number of CPU cycles right I see so a lap CPU cycles for slow mem copy T1 minus T2 mem copy then to eliminate another cash effect a lap CPU cycles for fast men copy so this looks at destination source 64 by if okay if length is greater than equal to 64 see how many blocks we need to do i minus minus oh it's using XMM thanks for helping in my experiment oh is this going to be something like it's super slow and C0 22 specify the men copy amount between 8 and 16 8 16 32 64 6 10 24 2048 yeah i'm thinking this is going to be super slow with this size oh size is the amount of memory 40 96 okay experiment five men copy with both their size 128 view cycles for slow men copy um okay super weird let's see what the heck this size thing is because that's the only input we have into this program I can't it's weird does it crash okay let's see it's allocating 40 right it was just 16k okay interesting okay so it stopped at so it's did mem copy CPU slow 128 so let's see if I can compile this locally on my machine and 32 syscdef.h because oh it's giving me a nice I need to install it must be some install so it looks like do I not have oh well oh the libc the 32 bit libc okay so installing that this goes to install this locally and see what happens it must be something weird about how they're doing this so you must have to be certain to give the right value here so I'll just do exactly what I did on that other one which was put the lower value 64 128 6 5 12 10 24 20 48 496 okay run the experiment oh it's like fault interesting huh I wonder why that is so we'll have to just run 8 16 32 I should just make this into a file 24 128 256 5 12 10 24 20 48 296 so seg fault in fast mem copy in fast mem copy move n tps oh now I do want I should reinstall Jeff so next time around gdb I'll have a nice Jeff environment but that's okay because let's look at this all right push ebp move ebp this move the stack pointer into ebp subtract 10 for the stack pointer if length is greater than or equal to 64 so this makes sense because this is the the only time we hit this branch is when we're actually at 128 which is the first time we're above 64 that makes sense jbe jump below equal plus 88 so skip all of this junk but we don't want to do that so we say okay we're in here so now move eax into I don't know move ebp plus 10 into eax this is going to be length shift right by 6 that's going to be divided by 64 move that into I which is going to be ebp minus 4 I should probably do this in hopper but I kind of like looking at it in here let's see ebp minus okay yeah eax into there so that's that shift right so it's 128 divided by 64 so that should be 2 right just calculating you know 28 divided by 64 2 let's see and l ebp 10 and it with 3f okay so that's a little weird oh that's this and equals 64 minus 1 so right so 3f looks like this so only keep the 1 2 3 4 5 6 bits there and then how did this get translated so then while I minus minus is greater than 0 so do this let that number of times jump to plus 75 and then jump up here so move ea move qda okay I have no idea what these instructions do move dqa xmm 0 into eax move aligned double quad word moves a double quad word from the source operand to the destination operand this instruction can be used to move a double quad word to from an xmm register and a 128 bit memory location between two xmm memory locations so first okay so dereference eax let's see move it into 0 then move eax plus what's that 16 yeah like 16 into 1 2 3 and then move it back but this didn't work but why didn't this work edx ntps it's 804c4a destination destination should be something all right I'm gonna quit this there we got our jeff okay breakpoint on fast mem copy let's see so I have actually the input here I'm going to create my input input file 8 16 32 64 128<PHONE_NUMBER> and I will obviously be playing with these later to bypass these checks or to somehow get this thing to work 8 192 so where am I there run input there we go I'm at the beginning pair okay so now I know this is the the stack so so now I have basically the stack pointer base pointer so that's so compare oh so yeah it's just gonna do push push push call slow mem copy to so I actually wish I could see more of the stack let's see if moving this down allows us to see more now so x 20 x yes p is this 40 is that the value is 40 128 not 64 there we go and then now this value should be 80 which is 128 80 128 great okay so now we can see what's happening here next instruction so now we check we don't take it we then are going to move ebp plus 10 into eax so this is going to be 128 into eax we shift it right by six so this is going to divide by 64 it's going to be two we're going to move that onto the stack until ebp minus four to the local variable i we're then going to and it with three f so and it with three f jump down move that there load effective address move ebx into there test eax to so this is the loop counter checking length greater than or equal to oh no this is while i minus minus greater than zero so because that's going to jump us back up that's a very common technique of how while loops are done so they first jump down to the bottom to the check and then jump up to the top so okay so move into eax ebp plus c so eax is going to have f 7 f c 90 and edx is going to have ebp plus eight so these are the parameters ebp plus eight test ebp plus c source so a should be source and this should be the destination why is this the destination i'm eight of four let's see so where is test okay source okay source is an end mapped value and test is scan f okay wait so no no desk sorry desk was a malloc yeah is malloc with the size that we passed in should only have 128 bytes is that why okay it was at that very location okay nothing in there it's on the heap i believe okay so now move to dereference eax and move that onto x mm 0 x mm 1 x mm 2 edx is this value six have move n tps move a line four packed single ft non temporal with the double quadward in the source operand which is the to the destination operand using a non temporal hint to minimize cash pollution during the right to memory the source operand is an x mm register which is assumed to contain four packed single precision floating point values the destination operand is 120 bit memory location the non temporal hint is implemented in using blah blah blah processor just not right down in the cash hierarchy nor is it fetched of course in cash line in the realign uh because the wc protocol uses a weekly ordered memory consistency muscle should be used in different operation protective memory exceptions for an illegal memory operand effective address than this if memory operand is not aligned on a 16 byte boundary regardless of segment edx so a 16 lined on a 16 byte boundary okay how do i tell if it's aligned on a 16 byte boundary well i guess that all of the bits would have to be zero so zero zero one zero zero zero one so one two four eight sixteen so i guess because that one so what if we redid that so what if i did adx still at eight four eight okay well we can do something different let's disable edx is now 0804c460 bits okay so i think this should work then interesting okay so to do this edx so to do this um x mm word i have to make sure that all the values that get returned these memory addresses have the first one though so the first bytes cleared so it's on a 16 byte boundary uh otherwise it will seg fault so now i can look at the next one so the question is will this actually work the same on the real one and that's something so this should be good this is actually something that i have no idea so let's see that's good this one's messed up yep so it's going to cause a seg fault and this is on towards the end then this was like the second to last one 4096 i don't know what did i just add bytes so let's see if that actually makes a difference um by doing it here so this is you know we want to so okay good so i did get past the no i did not see this is the problem 816 32 70 128 oh 128 did work there okay now how do i this maybe i can just essentially brute force this in some sense just try various offsets here two so that's plus four there we go i got me past that to 512 so 256 let's do plus so this isn't you know my preferred way to do it but basically we just need to keep incrementing these values until we end up getting on a 16 byte boundary um so 264 24 512 plus 8 right well so another 1024 plus 8 i can just use a max's calculator plus 8 and since i it looks like i'm just adding 2048 plus 8 let's see 2056 between 4096 so 4096 104 there we go all right so memory alignment i guess was the challenge there so hey you know what all types of challenges uh that was interesting i got to learn about um the semantics of these functions here this move dqa and move ntps so yeah that was interesting i'm happy i did that all right well thanks for watching see you next time


The thermal expansion coefficients of T15 MOSI alloys were measured by dilatometry during heating and cooling cycles. The results showed that the presence of silicon reduced the beta-transist temperature and transformed the alloy into the omega phase. Additionally, the thermal expansion coefficient curves had an S-shaped pattern, indicating a transformation from the beta phase to the omega phase. This article was authored by Hayyam A. Ali, Mohammed M. L. Syed Seelman, Ashraf Butkar, and others.


One, two, three, four, five, six, seven, eight steps. It's the number of steps right there. I asked you whether Pythagoras is right, whether the numbers are real. If you say no, then where do the numbers come from? I mean, I guess what, we just make them up. I mean, if they're not real, they're created by us. Again, we don't see numbers around. So the only possible place for them to exist is somehow just in our minds. Okay, I mean, that's the way it can go. But if numbers are just created by us, why does, so here's a claim involving numbers in mathematics, four plus four equals eight. Why is that true? If it's just something we make up. There's all kinds of things we make up that don't seem to be either true or false. I mean, here's the claim. Sherlock Holmes lives at B221 Baker Street or 221 B Baker Street. Is that true? Well, and if you go to 221 B Baker Street, you find a Sherlock Holmes souvenir shop, but Sherlock Holmes doesn't live there. And Sherlock Holmes has never lived there because, you know, he's fiction, he doesn't exist. Here's another claim. Sherlock Holmes lives in New York. Is that false? I mean, why? Is it false because Sherlock Holmes lives somewhere else? No, he doesn't live anywhere. And, you know, there was a TV series that depicted Sherlock Holmes as an addict living in New York, and not only that, but Watson, who eventually became his detecting partner, was a, how did they phrase it? Basically, she helped addicts with their addiction and portrayed by a woman, portrayed by Lucy Liu. So was that just false? I mean, it's fiction. Again, off the gray is a wizard. Is that true? If so, how? Are there any wizards? Well, no. Right, wizardry is a fiction. How about again, off the gray is a stockbroker living in Decatur. But is that false? If you say it's false, why is it false? Is he doing something someplace else? He's not in Middle Earth. Middle Earth is a fiction. You know, fictions, things we just make up out of our head, they're not really either true or false. I could say Smaug is a dragon. Okay. But I haven't really said something true or false because there isn't a Smaug or no other dragons. If I said Smaug is a unicorn, haven't said something true or false? If I say there are no dragons, then yeah, I've said something that's true because we look on the world, we look at all the animals that exist and we don't find any dragons. We look at the expectant signs of dragons, right? K is filled with gold and burnt corpses on the outside and we don't find those. So when we say something true or false, we're talking about what's real. When we're talking about fictions, it's neither true nor false. So if you want to say mathematics is just something we make up out of our head and yet four plus four equals eight is true, whereas four plus four equals 72 is false. I'm going to want to know why it's either true or false because anything else we just kind of make up out of our head isn't. What's the difference? Simply because we say so? Well, hey, today I say that four plus four equals 72, right, doesn't work that way. We tend to think of numbers as rather immutable. You know, numbers are not the only form that we use, right? My scientific investigation itself is a form. Scientific investigation looks at these physical particular things, okay, but is itself a form? Botany looks at trees, botany is not itself trees. The scientific method is not physical. It's something that we understand, we comprehend. We don't see the scientific method out there. If form really just is something we make up and therefore fiction either true or false, we're kind of in trouble because the scientific, you know, scientific investigation relies upon numbers. You can't do science without numbers. And if they're just something we make up, scientific investigation relies upon a fiction. The scientific method itself is not a physical thing. It's a scientific method, merely a fiction. So you can say that numbers aren't real, that's your prerogative. Plenty of people do, including a significant number of mathematicians. So you could say the scientific investigation, or you could say that form numbers are not real, they're just something we make up. But then you're under the burden of answering the question, how do we get truth or error out of what we just merely make up? On the other hand, if you say numbers are real, you might have an even more difficult problem. Now we say four plus four equals eight, okay. How do I know that? I take the concepts of four, addition, eight, and equality, and I have a true statement, four plus four equals eight. These are all concepts. These are all abstracts. I never see concepts or abstracts. If I want to say I know four plus four equals eight, how do I know that? It's not by observation. It's this thing we call comprehension, whatever that is. So if you say that numbers are real, that's fine. That's your prerogative. Plenty of people say numbers are real. Okay. Then how do we know? You know, we say that there's an unending set of numbers. Numbers never end. If numbers are merely something that we just make up, there isn't an infinite set of numbers because nobody can conceive of an infinite set. We can't count that high. So if numbers aren't real, there's no infinite sets of them either. Uh-oh. If numbers are real, we're talking about the existence of literally an infinite amount of things without end. They're not here because they're not physical. They're abstracts. Then we say we know them. It's a difficult question to answer.


there's some basic concepts that you need to know before you actually start in cryptocurrency investigations. And one of them is how the blockchain works. There are a lot of different cryptocurrencies and they all have their own feature that makes them special. But underneath all of that is this core concept of a blockchain that pretty much all of them use. Now the way those blockchains individually work may be a little bit different. But as long as you understand that core concept of blockchain, you should be okay. So let's think about how blockchain works. Let's say we have a transaction and we want to record this transaction somewhere. We'll say this line represents where we're going to record it or our ledger system where we're going to write information about our transaction. Now I want to exchange money. So I want to give some currency to my friend, for example, we make a transaction record on this ledger system. And it has, for example, the amount of money that I'm going to include it has who the money is going to. And then of course where it's coming from. So now we have the amount of money we have to in from and then that's recorded on a ledger system. We'll come back to where this ledger system actually is in a second. Somebody else is also using this ledger system and they want to transfer money to their friend. So they create another transaction record. And then it also has, for example, the amount of money that they're transferring, who it's going to where it's coming from. And then the next thing that they add is also information about the first transaction that happened. So specifically the hash value, we create a hash value and I'll just call it h1. And we put h1 into the transaction record. And now what I can do is use h1 to verify this past record. Now we can keep doing this all day long, adding more and more transactions to the chain. Once I get to my last chain, then I have, for example, the dollar sign to from and then h in. So whatever the most recent value is, I can use that hash value to validate the previous block in the block chain. And if that hash value is correct, then all of the other hash values are correct down the chain. So this is a very basic system for making sure of the integrity of the overall chain. This is really all blockchain is, it's just a transaction record with information about hashes for prior transactions that are in the current record. That way we can do validation all the way back. This also means the more transactions we have, the harder it is to modify prior transactions. So for example, I would have to modify everything in the line if I wanted to go back and modify the h1 value. This ledger system that we're writing everything on is distributed. I can have my own node or my own computer keeping track of all of the transactions. Everyone else who's participating in that particular network can also have their own node monitoring and validating transactions. All of these nodes have their own copy essentially of all of these records. They're constantly doing validation against all of those records and making sure that everything actually is valid. So if one of these nodes comes in and says the value of h1 was 23, then all of these other nodes will go, no, that's not what I have in my record. And then they would reject that nodes update pretty much all blockchains have some type of validation network. And usually it's distributed. So for example, Bitcoin, people really like Bitcoin because the ledger system that they use is globally distributed. A lot of different countries, organizations now are in that network. So that's a lot of different groups validating a blockchain or all of the transactions on the blockchain all the time. There's other systems that aren't quite as distributed. So for example, one company might own all of the nodes that validate transactions. Banks can use blockchain to keep track of all of their records. It's a really good use case for banks. But the banks themselves probably don't want to distribute their node validations with other organizations. They wouldn't want to make it public necessarily. They could have, for example, several nodes running their own blockchain and then doing all the validation themselves. This is where blockchain gets a little bit tricky, a little bit interesting. If we have a fully public blockchain, then that means that anyone can join the network and then try to validate and potentially try to maliciously alter some of the transactions in that chain. We could have a globally distributed blockchain system or we could have a blockchain system that is controlled essentially by one or only a couple companies or just a single entity. One node validating those transactions would still work in terms of blockchain. Now, when we talk about most of the popular cryptocurrencies, they are globally distributed and lots of different competing interests can validate transactions on that ledger system. The way that the blockchain is maintained determines how susceptible it is to certain attacks. So we have a ledger system and this ledger system, this information is completely distributed to all nodes on the network. It could be public, which means everyone can get access. It could be private, which means a single organization has that information. Some layer is validating new transactions that are added to this ledger system. So we have a way to record transactions that is very, very difficult to modify. And over time, it just strengthens the overall chain. So we can put all sorts of information into this ledger system.  I could record, for example, user names, let's say that I own a website, I have a transaction, I have the username here for let's say user one, and this user obviously could update their username. We don't modify this particular transaction. Instead, we write a new transaction update the username to you in to something like that, right? So I've edited now the username in my system. Whenever I'm going through it, I can just check for the latest version of that username that's in the blockchain. And then that gives me history of all of the username changes that have happened. In most ledger systems, you cannot edit transactions that's completely against the point. But what you can do is submit a new transaction that updates prior information, and then prefer the newest copy or version of that information. In the ledger system, we have this kind of validation layer, and we have transactions, we can develop it so that way we can store anything in this ledger system. And the ledger system is extremely powerful. So when we're talking about blockchain, think about keeping records, records that should not be able to be changed. So if this is our ledger system, where does cryptocurrency come into play? Cryptocurrency kind of sits on top of this ledger system, and most popular cryptocurrencies tend to have their own kind of ledger system in place, or they ride on the back of another cryptocurrencies ledger system that that it's already well established. So we have this application layer, and that can usually be something like a cryptocurrency exchange, or maybe a cryptocurrency wallet that a user has. And these wallets can do a couple of different things, which is why it can be a little bit confusing. They can, in some cases, try to validate transactions through the wallet. They can also interact with the ledger system and add new transactions to the ledger system. Basically, they're participating in a network with other nodes on that network. So think of a wallet as essentially a unique identifier. And this is what would be your, for example, your Bitcoin address. And using that Bitcoin address, you can both submit new transactions and also receive transactions. So a wallet is essentially just an interface for the ledger system. And cryptocurrencies are just value that's created at this application layer. So that's kind of the basics of blockchain. We have some sort of ledger system, and that is a chain of blocks or a change of transactions that happen. We have some sort of validator system network sitting underneath there, continuously validating transactions and adding new transactions to the chain. And then this application layer, which is where the users are using a wallet to interact and attempting to submit new transactions or read transactions from that ledger system. In most cases, if you just think about cryptocurrencies in terms of the ledger system for investigations, it's going to be way more straightforward. So I hope that was helpful. A little quick introduction into the basics of blockchain. Validation mechanisms are different even the way the blockchain works and what types of information can be stored are a little bit different. But this will at least get you started. Thank you very much.


This movie should be high on most people's lists of great 80 slasher's. Yeah, and it's really not actually. It's really forgotten. Hello and welcome to another episode of Frightfully Forgotten Horror Movies, but before we get started, what are we drinking? Today we're drinking the last two bottles of Caprini Green Smoked Porter. Nice.  Y'all get attacked by the candy, man. Today we're going to bring to you 1989's Intruder, a very underrated slasher. That's right. Intruder is directed by Scott Spiegel, and he actually co-wrote Evil Dead 2 with Sam Raimi. He's from that whole camp of guys, right? He's part of that Sam Raimi camp, where he buddies with all those guys. He also co-wrote the screenplay for The Rookie, the 1990 movie with Clint Eastwood and Charlie Sheen.  He's produced a lot of movies, but he's directed from Dust Till Dawn 2. Oh yeah, straight into video, baby. And Hostel 3. Dan Hicks is in this, and he's from Evil Dead 2. Bobby Joe! 45. 100 buck. Sam and Ted Raimi are in this, as well as Bruce Campbell. For two seconds. Intruder starts were introduced to our cast of characters here, all working at a supermarket together.  Yeah, that old man.  They're just about to close up, and one of the girls, Jennifer, her ex-boyfriend, shows up and starts harassing her. And they end up getting into this big fight, then all the other co-workers get in on it, and they're all trying to throw this guy out.  He's doing a pretty good job. Yeah, he's all throwing everybody into those display cases here. Sam Raimi goes and all that display, beating them up. They finally usher them out. All the commotion is settled. The two owners of the supermarket can hold a little staff meeting, and they break the bad news that they're going to be selling the store, and shortly all of you guys will be out of jobs. So they're all kind of sad, you know? They all like the place. You know, a lot of them have worked there for a long time.  Two owners are up in the office talking, and kind of get the impression that one guy, Bill, is not too happy about this sale. He doesn't really actually want it to go down. And the other guy is like, ah, whatever, just sign the papers, get it over with. Yeah, let's get this done with and get the money. We see a POV shot of somebody looking for a way to get into the supermarket. Craig keeps calling too in the meantime, and he keeps making threats and harassing Jennifer. I don't know why they keep answering the damn phone. Well, yeah, it's after hours too. It's like, you don't need to answer it. Linda leaves the store to go home, and when she opens up her car, there's a knife there just dang stabs her. So there's the first kill of the whole movie. Bill hears some stuff outside, and he figures that it's Craig kind of hunting around. He goes outside with a hammer. He's to take care of business one last time, I guess. He runs into Craig, and they get into it, and he ends up getting knocked out by Craig. With the hammer? Yeah, with the hammer. Somebody gets into the store and starts knocking the employees off one by one, and quite brutally too, I might add. And quickly. Yeah, and that's where we're going to end the plot. So if you want to keep watching and see what happens with all the employees, keep watching 1989's Intruder. But why should you watch Intruder? We're going to give you all the reasons why right now, because it's a pretty damn awesome slasher. That's right. One of the best things about this movie, and it's glaring, is the setting, right? The supermarket itself. It's an awesome place to have a horror movie. You've got all of these little nooks and crannies where somebody could be hiding. You've got these different rooms, different areas. The meat department. Yeah, the meat lockers. Yeah, the attic too, the attic space. It's all that cool like Halloween stuff and everything. Oh, the Halloween and Christmas decorations. Yeah, it's cool. And then the downstairs area where you have to go down those rollers to get down. Like a lot of really neat areas. The supermarket is almost a character in itself, right? And all these little rooms are almost little characters too. They've got little quirks about them. Yeah, it's great. Every movie should be like that, I think. Every movie, the setting should be the other character. That's right. One extra character is the setting, and this movie nails that. I like too how they're isolated. You don't know exactly where they are, but you assume that it's this small, dinky town, right? So after hours, it's like nobody's coming around. You also feel like they're in the middle of nowhere, because you look out, they show like a lot of shots from the inside looking out, and you see just darkness. Blackness, yeah. Darkness. Darkness! Darkness is spreading!  Yeah, so it really gives you that sense of foreboding, and that where are these characters gonna go, right? They need to stay in the store, because the store is like salvation almost, right? Yeah, you do really get that sense of isolation, and it really does feel like this store is plopped literally in the middle of nothing. There's nothing around. The characters in this movie are really good too, and there's a lot of them, so it's kind of actually hard to keep track of them all. There are some really memorable characters, like both Sam and Ted Raimi, are very good in this. Funny and quirky. Ted Raimi always has his headphones and his Walkman on, and you never know, he's completely oblivious to everything. So listen to that shitty song. Like even when they all get fired, he's completely oblivious. Guy walks by, hey, you lost your job. He's still working, cutting up that watermelon. Like who cuts up a watermelon like that? He's all digging it, just destroying it. You're gonna put that on the shelf? Like one character always talks like this all the time. Right. He's like, what's this guy's problem? But you realize, ah, he's just playing a character, and he's doing that for the sake of being campy. That's right, yeah. It's forgivable, right, with the sort of movie that it is. The camerawork in this movie really sets it apart from a lot of other slashers. Oh yeah. There are some great, very interesting, original camerawork and shots happening throughout the whole movie. Start to finish, you know. A lot of POV, like even the POV of the shopping cart and everything. Like, when do you see the POV of a shopping cart? Yeah, that's right, yeah. It doesn't have eyes? Yeah. But it all helps to put you there, right? Yeah. It makes you feel like you're part of the action. A lot of cool overhead shots where you see like the whole scope of the supermarket. Yeah, how big it really is. Yeah. Like where these people have to run to to get away from things. A really interesting, cool shot where one of the owners is up in his office and he's having a drink and the glass is in front of the camera, right?  It's a really neat way to keep the killer a mystery. All the little subplots for the characters are neat too, the way they flesh the characters out a little bit because it makes you care about the characters and if they're gonna get killed or not, right? That's major to a horror movie.  He owns 51%, I own 49. I mean, there's a little love interest happening between two of the characters which is another kind of subplot. So there's a lot of other things happening besides just the killing. That's right, yeah. And then the cops show up too and they don't do anything. You can totally use it. They're all old, they're like 80 years old, like bumbling. What are you gonna do? It took five strapping young men to take care of this craig. Yeah, I need these two old cops. What are you gonna do? And the humor is really good in this movie too, right? Like it's intentionally funny in the right places. That's right, yeah. And a lot of it's dialogue driven too, but a lot of it, the settings help, right? There's things that they're doing that's funny as well. And the kills for this movie, they're awesome. Absolutely awesome.  Half of his head? Half, yeah. Oh, it looks so good. It doesn't look cheesy. It looks spectacular. It reminds me a lot of two other kills. The fly too. Security guard gets his head crushed in the elevator. And toxic Avenger when he kills a guy with the weights. Oh yeah, that's kind of the same idea. But this is really good. Yeah. On a low budget. There's a bandsaw kill too, which is even better. Oh yeah. Like they show more of it and it's like the teeth and all that getting all ground up. It's like, yeah, you'll feel it. It puts the guy's head vertically through the bandsaw. Like this dot looks so good. I like how the killer too. He's all strong. Super strong. Like yeah, he can just lift these people up with one hand and everything. The killer and the beer cooler is really good. He stabs the guy and it goes through him into all the beer cans. And then the beer starts spraying everywhere. Yeah. The generic beer. This is beer. Slams his eye into that spike thing that nobody uses anymore. Like a super outdated thing. Those spikes to put receipts or whatever on it. Aren't you wrecking the paper? Kind of like numbers and stuff that might be on it. They've all been outlawed because too many people have been killed with them. Like this was looking. The way the kills are shot are really neat too. Like the way the blood splatters. Like when that one guy gets killed outside of the supermarket. Yeah. And his blood sprays onto the outside glass. And then like everything turns red on the inside. Because the light shining through the glass is like really stylistic. The music is really good for this movie too. And it really helps to build the mood and foreboding for a movie like this. Yeah. That's what I thought too. And even just the opening credits. It's just a shot of the moon. Yeah. With some clouds going through it. And then this music. And it sets the tone for the movie perfectly. You kind of feel at home. The moon and the clouds and this music. This is going to be good. Here we go. Yeah. You're settling in. Now we're going to get into some spoiler territory.  Come back and watch this. There's a reveal at the end where you find out the killer actually isn't the boyfriend Craig. It's the co-owner Bill. And it's a really cool bait and switch. Yeah. Because you're not expecting it to be Bill whatsoever.  And his motive is hilarious. Yeah. Because he doesn't want the store to close.  I love this store. It's like so why do you have to kill all of us? Well I can't let you stop me. What? Kind of like the way we felt when the movie store is closed. I can't let you close the store. Yeah. I love this store. And then the final showdown between Bill and the final girl is epic. Yeah. It goes throughout the whole supermarket. Spills to the outside. Get a really good payoff. The ending also reveals how, I guess how silly the killer is for his motives. But also how twisted and deranged he is too. It's like that head scene. He tells that story with the ham sandwich in the head early on. And then he's actually doing that later eating the sandwich. Yeah. And then he starts beating the guy with the severed head. And watching this a second time knowing that Bill is the killer. Yeah. It's really cool to see how they hide the fact that Bill's the killer. Now that you know watching a second time it's like okay yeah they did a really good job of like not cluing you in whatsoever and really fooling you to think that Craig is the killer. That's right. They did a really good job with that. They didn't cram that down your throat. They just kind of had it sort of nonchalantly. Yeah. And you wouldn't be surprised if it wasn't Craig but you are surprised that it is Bill. And even at the end end the killer still gets a one-up on everybody else even though he's dead.  Yeah. They killed everyone in the supermarket. And then he died. And then they arrested them the final girl in Craig. Yeah. So he still kind of wins. Cool thing about Intruder is it's kind of half cliche and half very original. So that the cliche parts really feel familiar to you but the originality makes it stand out amongst a lot of other really shitty slashers. That's right. Yeah. You know this this this movie should be high on most people's lists of great 80 slashers. Yeah and it's really not actually it's really forgotten in terms of that. And it is better than most higher end slashers or more familiar slashers like Friday the 13th. Yeah I think this is a way better slasher than Friday the 13th. A million times better. It's more enjoyable that's for sure. Yeah. Fun watch. It's the the original Friday the 13th is actually boring. Yeah. It kind of feels like it goes nowhere. Tell me if I'm wrong if you can think of a better one let me know. But I think that this might be the last great slasher of the 80s. Yeah. This came out in 89 the 90s are about to happen slasher genre is pretty much going to be dead now until Scream comes out. So this is probably the last great slasher before Scream revived it. It's an end of an era this this movie kind of stamps an end of the 80 slasher era you know. That's right yeah because then after this then you start getting into different effects too and then computers start to take over it just doesn't have the same feel. Yeah so if you want a really good fun slasher this in the vein of the Evil Dead movies because it's done by those guys that whole crew of guys yeah it's got Ted Raimi in it Sam Raimi Bruce Campbell is directed by the co-writer of Evil Dead 2 how can you go wrong.  Yeah so if you haven't checked it out and you're a slasher fan or just a fan of fun campy movies definitely check out Intruder it won't disappoint. No not at all and until next time keep drinking. I can't let you finish this beer I love this beer.


All right, so let's start this off by creating that base rigid body script. All right, and like I said, I like to do this just because it separates kind of the responsibilities of the classes, you know, this base rigid body script is going to be Responsible for setting up and just getting the rigid body up and running I like doing things like weight conversion and just checking to see if it's even there first off and Then the you know the drone controller is going to handle Controlling the actual drone and doing all the you know banking and rolling and pitching and yawing and all that stuff. So Let's jump into unity and get started. All right, so let's go over into the code folder and into our scripts folder And let's make a new script and I'm gonna call this IP Or actually we're gonna call this base Rigid body. I Got ahead of myself there for a second. I also want to change a little icon On my scripts just so to note that you know, they're my scripts instead of just the default C-sharp scripts So if you go and look into that zip folder that I included with this particular course this mini course There's this any pixel icon now you can use that if you want I just asked that you don't use it in your regular work that you might sell or You know, I would highly recommend just making your own icon. It's really simple It's just a 32 pixel by 32 pixel image But let's drag and drop this into the editor here editor folder. All right And let me show you guys how to set up that little icon So it's really easy you just select the script that you want to change and then you go to hit the little icon on it over Here and the inspector and then select the other button and then just go look for the particular texture So I just typed in indie up here and that comes up with the indie pixel icon And then you just kind of click off of it and it'll go and update the icon for you So just nice little, you know, customized thing to do for your scripts makes it feel like a pro at least Again, yeah, I highly recommend making your own, but I just wanted to show that too. They also show up inside of the Editor the scene editor and they they actually become selectable too So really cool stuff and that actually reminds me. I should turn this guy back up here like so there we go All right, cool. So let's do our base rigid body So I'm going to double click that to open it up into visual studio 2019 And let's take care of our namespace just like we usually do so say any pixel like so And remember this particular script is really just responsible for dealing with the rigid body All right, and just getting things set up just so we don't have you know a bunch of Rigid body based controllers in our projects and they all have their own functionality to set up a rigid body We can just extend or inherit from this one particular script for all of our vehicles All right, so I'm going to do a require component and it's going to be a type of rigid body So again, this will just make sure that the rigid body is actually assigned to our game object Okay, so with that done, let's go and create a region. So I'm going to do variables Like so and there's actually a way to set this up. So you don't have to type this in if you have a common Setup that you always use for your particular scripts like like I do I always basically do this over and over again You can actually there's a template file and I just can't remember off off the top of my head What where it is it is in the unity engine folder There's some temp file that you just need to update and I'll fix all this stuff up So I'm sure you could Google it and it'll there's be like a million different Resources about it. So all right. So the first thing I want to do is I want to allow users To assign a weight to this. Okay.  All right, so this is just a nice way to keep things organized in the Inspector, okay, and then I'm gonna do a public on actually, let's just do this. Let's do a private float Weight in pounds and I'm gonna set that to one. Let's say, you know, these drones are pretty light And it really depends on the type of drone. Obviously the larger they get the heavier they get All right, so I'm just gonna initialize it to one pound But we made a private so this means it's not, you know, accessible by other scripts But it also means that it doesn't show up in the inspector But we want to be able to change this in the inspector, but I don't want other classes to change this value So we make a private and then we do the serialized field Attribute, all right, and that basically makes it so it shows up in the the inspector All right, so the we also need another private variable and this is going to be the rigid body So we're gonna say rigid body. I usually call that RB for short All right, and what we need to do is right when the game starts We need to assign this rigid body variable with the actual rigid body that's being attached by this required component Okay, so to do that I'm actually going to change this void start to awake So it gets called before all the start functions get called. Okay, so I'm ensuring that you know We're gonna look for the rigid body first All right, so we're gonna say RB is equal to get component and we're gonna be looking for a rigid body That type, okay cool Awesome, so now we got that all set up. We're gonna get the rigid body So we could do some setup here what with this weight in pounds All right, and that basically means I want to allow users to set the how much this weighs in pounds Okay, and I'm just sticking the pounds because it's what I'm used to What I'm gonna do is I'm actually going to create a constant value.  It's gonna be called pounds to kilograms or kg Okay, so if you're used to kilograms and by all means that the reason why I'm doing this is because unity by default works in kilograms So not pounds, but because I'm used to working in pounds, right? Because you know just the region I live in basically and how I was raised I Do this conversion. So you don't have to do this. That's my point. So the conversion is To we want to multiply whatever pounds we have here that's been assigned by the user by this Constant ratio value basically so 0.454 Okay, so let's do that. Let's take care of that now. We're gonna go in here. I'm gonna say if RB if we have a rigid body basically, okay, then let's set the mass so we're gonna say RB dot mass is equal to our weight in pounds times our pounds to kilograms conversion All right, and you can look up if you have other conversions you want to do you can look them up on Google Just type in, you know, whatever unit of measure you want to start in and the unit of measure you want to convert to and Google will tell you what The conversion factor is Okay Cool. So the next thing I want to do is I want to if we're going to be inheriting from this particular script I want some sort of Overrideable function in here that handles the actual physics processing. Okay, so and we'll talk about overrides once we get to the drone controller So what we want to do is we want to say if Inside of our update function and actually we need to set this to a fixed update because we're working in physics All right, so I'm gonna say if not RV So if we didn't find an original body for some reason it got detached somehow or destroyed Who knows but you should always check for this So if we don't have it, we should return and not execute any code below this particular statement here Okay, so I'm gonna say if not rigid body Okay, so if this is null basically we're gonna return and so the fixed update will just constantly be returning And no any code below here won't be run and the code that I want to run down here is Function that I'm gonna call handle physics And I'm gonna make this overriderable Okay, so you're gonna get a red squiggly line there because we haven't actually implemented the handle physics So let's do that now. So we're gonna make another region. This is gonna be custom methods like so Don't say and regent like so and then we'll say We're gonna say protected right because I want to be able to I want to protect this class But I also want to have all Classes that inherit from this base rigid body class to be able to to see this function So I make a protected not private and I don't I'm not making it public because I don't want any other script to see this Okay, so I say protected virtual void. It's not gonna return anything. It's virtual because we want to override it All right, meaning the implementation in the other scripts are gonna have its own set of code Okay, we're gonna say handle physics like so And then our squiggly marks or curly braces Awesome, and we don't need to put anything in it because the script is not gonna do anything with it I just want to set it there and then in the drone controller will go and add the actual meat or the code that goes in there All right, so that is pretty much everything. I think the next thing I want to do let's Let's actually create two more protected variables here. I really only need the weight and pounds to be Exposed so I'm gonna do a protected start drag All right, so this is a good idea to do And we actually need to give it a type. So there's gonna be a float value. There we go This is a good idea to do because When you want to start to do Dynamic drag, which you should write for some sort of physics-based Object or a vehicle You want to update the drag as something is going faster, right? Obviously the faster we're going the more drag we're creating Right because we're you know having to force ourselves through the air basically in the case of a drone So you want to increase the drag. You don't want it just a constant drag and that won't feel as realistic, right? cool, so with these two variables Let's go and Assign it so I'm gonna say start drag is equal to whatever, you know, the drag has been Set to in the inspector. All right, so that is if I go back in the unity over here and select the drone Oh, we don't have a rich body So I'll point that out once we finish up the script here But it's basically whatever value Is is set in the inspector there. So we'll say RB dot angular drag All right, we just want to initialize those values and make it protected so any you know Class that's inheriting from the script has access to the data and these variables All right, so with that we're pretty much good to go. So let's go back in the unity now and Let's assign it to the drone and see all the awesomeness happen. So let's Let's click and drag this over onto our drone and you can see it created a rigid body And we have the weight and pounds and our header look at that Nice and organized now. We're not actually going to be putting this base rigid body script I really just want to put that on there Just to show you guys how it works. We're gonna in the next lecture We're going to create the drone controller which inherits from this base rigid body class So it will also create the rigid body for us as well Okay, so with that let's close out the lecture and move on to the next