Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //From my Amnesia Rebirth Tutorial Series
- //Episode 39 Randomness Pt.2!
- //https://www.youtube.com/playlist?list=PL4KkjlmOwLwwMVqedCNpi6caUxhgyf8Qr
- //-----------------------------------------------------------
- bool RandomChance(int percentChance){
- int randomNumber = cMath_RandRectl(1, 100);
- if(randomNumber <= percentChance){
- return true;
- }
- return false;
- }
- SwingDoor_SetLocked("door_1", RandomChance(50), true);
- Map_AddTimer("Timer_HallwayGhoulSpawn", cMath_RandRectf(1.0, 15.0), "OnTimer_HallwayGhoulSpawn");
- Entity_SetActive("ghoul_hallway", RandomChance(50));
- Entity_AddForce("bottle_1", cMath_RandRectVector3f(cVector3f(-10000.0f, 0.0f, -10000.0f), cVector3f(10000.0f, 10000.0f, 10000.0f)), false, false);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement