Welcome to Open Carnage

A resource for Halo 1 modding and tech, with unique means of rewarding individual content creation and support. Have a wander to see why we're worth the time! EST. 2012


  • Content count

  • Joined

  • Last visited

  • Raffle Tickets


About Nickster5000

Recent Profile Visitors

907 profile views
  1. INTRODUCTION If you have written advanced LUA scripts for SAPP, you will quickly realize that the size of the file can grow dramatically, to well over 1k+ lines. This can be very inefficient for busy bodies like myself who don't have a lot of time to work on halo projects. In my experience of LUA scripting, I have realized there are 4 main components of a LUA script that can be abstracted: API version, Global values used by LUA scripts (BIPED_ID tables for biped switching, tables that store directories for biped models, etc.) Callbacks (OnScriptLoad callback definitions & implementations) Functions (That you can call from callback implementations to make them look neater. This also includes utilizing the prototype model to implement complex classes) Cleanup for OnScriptUnload Using this utility, you can now initialize an empty project that gives you a template project to start from. This template consists of: callbacks (directory) callbacks.lua --> allows you to implement your callbacks in this single file. NOTE: You can make as many files in here as you want. You can even implement each callback in a separate file. definitions (directory) config.lua --> allows you to define basic config (API version) definitions.lua --> allows you to define callbacks in this file (OnScriptLoad) garbage_collection.lua --> allows you to define your garbage collection in this file. (OnScriptUnload) variables.lua --> allows you to define global variables in here. NOTE: You can make as many files in here as you want. functions (directory) functions.lua --> utility functions that you call from your callback functions (So that you don't clutter your callback implementations) NOTE: You can make as many files in here as you want. You can implement all of your utility functions in separate files. config.lua --> For the API version, and Global values used in LUA scripts (listed above in #1) Figure 1 - Shows the working directory in VSCode. Once you are done, you can use the utility to build all of the lua files into one working .lua file. Figure 2 - Shows the built lua file from the files in Figure 1. GETTING STARTED Simply download lua.py located here: https://github.com/Nickzster/Lua-Projects-for-Halo There are three commands for this utility: python3 lua.py init <name> Run this command to initialize a new project. It will create a new directory named the specified <name>, and create the respective files and directories listed in the Introduction section. Write your LUA script. When you are done, run this command: python3 lua.py build <name> This will take all of the LUA files located within the specified directories, and build them into one file, named <name>.lua, that you can then use for Halo. To better understand how to set up your scripts, the build process builds in the following order: Builds all of the files in definitions directory, in alphabetical order. Builds all of the files in the functions directory, in alphabetical order. Builds all of the files in the callbacks directory, in alphabetical order. Running python3 lua.py help Displays the two commands in the terminal for reference. Admittedly, it has been a while since I have messed with SAPP LUA scripting. Before getting back into it, I wanted to build a utility for myself to make this workflow more efficient. If there is anything that I missed, forgot, or made a mistake on, please let me know! I hope this is helpful for some of you! *Made some major edits to the original workup, as I thought this was a better layout.
  2. If I were to develop my own multiplayer map with AI, could I use hsc to spawn AI? (for instance, me and a group of people walk through a trigger volume to spawn the AI) Or do all of the AI need to be spawned in on match start in order for this to work properly? Great work on this stuff!
  3. I built it for me personally. I've learned that being able to highlight and differentiate functions from types helps me speed up my productivity, and allows me to cut wasted time reading scripts in notepad. Being able to save time developing maps in my busy day-to-day life is a win for me. I decided to release the extension because I felt it would be selfish to withhold this tool as it might be useful to someone else. Plus, since it is open sourced, someone who is better than me at Regular Expressions, Context Sensitive and Context free grammars can make a contribution to make it better.
  4. Title and image describes it all. Installation instructions can be found at: https://github.com/Nickzster/hsc For those who like old school Halo LISP scripting. Thanks DSali for pointing out the errors in my original image. Fixed the image to fix the errors.
  5. The purpose of the website is, when a noob asks "What is Halo Custom Edition?", www.haloce.org will serve all of their needs. I would also like to make it a one-stop-shop for resources for the community. DSali, I like how you mention that each website can be ran with its own "tastes" and "spice", and I absolutely agree. However, how do you find these different communities? Where do you start? I want this website to be able to bring these new players to these communities. As soon as I posted this thread, I was invited to several discords that I didn't even know existed. Wouldn't it be nice to have everything in one place? I appreciate the comments everyone, please let me know what you think. Also, for those web developers / programmers out there, the website is open source, so if you wanna contribute: https://github.com/Nickzster/haloce
  6. Hey everyone! I was thinking of a way to contribute to this community, as I feel that Sector 09 wasn’t enough. I have a bunch of projects (as you might have read on my release thread a while back) that requires too much work for me to complete in this day and age. So I got thinking, and I realized my contribution was under my nose this entire time… I am currently majoring in Computer Science (I graduate in December, woo hoo!), so a big thought on my mind is landing a job when I graduate. I am a firm believer that the web browser and mobile applications is going to be a big part of the future. Now isn’t a better time to get into Web Development, and learn serious skills like designing websites and building full stack web applications. I have been learning HTML / CSS / Javascript, Front End frameworks like React & Redux, Node JS on the Backend, and other backend frameworks like Express. The answer to my contribution is in the form of a website / web applications, of course! Now let me ask you a question… When someone asks you “What is Halo Custom Edition?” or, you try your best to explain what Halo Custom Edition is to your friends… how do you explain it? After pondering these questions, I came to the realization that this community has two problems: 1. It is very fragmented (Some users actively participate in Discord Servers, some users actively participate on Halomaps, and some users actively participate on OpenCarnage, some users actively participate on Youtube, and the list goes on) 2. With the tremendous amounts of projects, it can be very difficult to explain what Halo Custom Edition is, what Halo Custom Edition is capable of, and what you can actually do with it. Now I get to the point of this post, and my solution to this problem: www.haloce.org I have built a simple landing page that is designed to “describe” what Halo CE is, how to install it for those folks who are new to the community, and to have a central HUB for the entire community. If you follow the link above, you will see this landing page in full (note, that it is not responsive yet. I will make a pass to make it mobile friendly). You’ll probably also notice a lot of Gibberish on the pages (This is Latin text placeholder, called Lorem Ipsum) and you’ll also notice ugly empty images (that display 1900x1080 rather than a pretty image). This is why I am writing this post today. Have you ever gone through the same spiel that I have, not having any ideas to contribute to the community? Or not having the technical experience to make a map? For those who want to contribute something to the community, I ask for you to help me replace the Lorem Ipsum text with actual content that clearly describes Halo Custom Edition. I also ask for you to help me create or find images to replace the ugly 1900x1080 images. I also want to reach out to the mappers / modders of this community, and direct you to this page: www.haloce.org/sector09/sector09.html Now, I am not trying to toot my own horn with Sector 09, but I am very intimate with the project (I made it, for those who are unaware), so it was easier for me to build a sample “Project” page. I wanted to come up with a proof-of-concept “Project” page, and build project pages for those in the community that are deserving of one. So I ask of you, the modders / mappers to take a look at the Sector 09 page, critique it, and think of other content that a “Project” page might need. I thank you for taking the time to read this post, and to contribute to this website for the fellow community! -Nickster5000
  7. I have received a request for source for Sector 09, so I figured I'd publicly release it (I know, its been long overdue.) Sector09 RAW Release - ALL BSP's - Nickster5000 NOTE: Files preceded in _ means that they are important. I marked them with this underscore as I was going through the files. Description: Included in this release is ALL of the iterations that sector09 went through from 2012, all the way to its release in 2016. Included in this release is the following directories, and notes about what this directory consists of: ***bitmaps -RPG_Rips and RPG_Rips2 should contain all of the bitmaps that I ripped from halo 3 ODST. NOTE: SOME OF THE FILES WILL HAVE BROKEN REFERENCES. I DID NOT RENAME ANY OF THE FILES, but they may be in different locations. I recommend that you rip your own version of the Halo 3: ODST bitmaps using adjutant to suit your needs. ***misc -Contains files that were used in showing sector09, and other documentation used in its development. ***sector09-2012 -The very first iteration of sector09. I could not find the original... however, I found two animation demos that I created on the original model, which should suffice. ***sector09-2014 -Old sector 09 build. I believe one of these didn't even make it ingame. Don't remember a whole lot about these files, so have fun playing around with them! ***sector09-2014-b -Another old sector 09 build. More files that I made for sector 09. Don't remember a whole lot about this one either, so have fun playing around!!! ***sector09-ce3-2015 -Second to most significant file in this pack. This was the demo that was showcased at CE3 2015. ***sector09-2016 -Most significant file for sector09's release. Contains the version of the BSP that was in the final release, as well as some updates to it. xtra -Extra files that I found laying around. README.txt - this file. Download Here! Please let me know if there is anything missing. Enjoy! -Nickster5000
  8. Hello Halo CE Community, I know you were probably expecting a really cool "GTA" mod for Halo CE, and we want to deliver on that. However, we have recently done a couple of thorough play tests and decided that the mod is not ready to be released as quickly as anticipated. We want to take some time and really polish the mod, and perhaps remake some aspects of the mod. I deeply apologize for showing this off before it was ready. I feel terrible revealing all of these details, and then not delivering them as soon as we are anticipating. To make up for this, we are going to deliver a high quality GTA Halo mod in the future that is extremely fun to play. Most of the features we announced will still be there. Thank you for your understanding, and I hope you guys are looking forward to what we are making. Happy New Year! -Nickster5000
  9. I agree. I try to stay away from doing too much memory access outside of the SAPP functions, but that implementation is much more concise. I changed it to your implementation if that's okay with you.
  10. I figured since I couldn't find a command to do this in SAPP's documentation, and I needed it heavily in the mod I am working on, I thought it'd be a nice utility function to release: function getDistance(Player1, Player2) --returns the distance between two players Player1X = get_var(Player1, "$x") Player1Y = get_var(Player1, "$y") Player1Z = get_var(Player1, "$z") Player2X = get_var(Player2, "$x") Player2Y = get_var(Player2, "$y") Player2Z = get_var(Player2, "$z") local diffX = Player1X - Player2X --x1-x2 diffX = diffX * diffX--((x1-x2)^2) local diffY = Player1Y - Player2Y diffY = diffY * diffY local diffZ = Player1Z - Player2Z diffZ = diffZ * diffZ local sum = diffX + diffY + diffZ return math.sqrt(sum) end
  11. -snip- I'm dumb and didn't read the tutorial thoroughly enough.
  12. Because I put the tags together quickly. I wanted to focus my effort on the team-switch aspect.
  13. Very simple project that I made today. Red team plays as spartans, blue team plays as elites. All the files are included. Chimera has been tested with the version in the .zip, 560, and 572(unstable release). Download The source is also on my github Wanna make your own team bipeds? bSwitch.lua, scroll until you find: BIPEDS = { [0] = "bourrin\\halo reach\\spartan\\male\\mp masterchief", [1] = "cmt\\characters\\elite_v2\\player\\elite_v2_mp", } Simply change the directories to the models. [0] = red team, [1] = blue team. Make sure to reference both of your team's bipeds in guerilla's reference section. hvc.lua (you will obviously need to rename this .lua file to your map name), scroll until you find: --redTeamHands = "halo reach\\objects\\characters\\spartans\\fp\\fp" --DEFAULTED to currently set hands in globals. blueTeamHands = "cmt\\characters\\elite_v2\\fp\\minor" --Set the hands you want for blue team here. Change the blue team hands to the directory of where your blue team hands are located. The script will automatically pull the tag from the red team's hands. You also need to reference these fp hands in the guerilla reference section. Credits: Kavawuvi / 002 - Biped switch script, making such an amazing client-side app. aLTis - bigass_mod.lua fp hands changing. Nickster5000 - Putting it together, setting it up for red team and blue team Anyone else I forgot to mention.
  14. clua_version = 2.04; set_callback("tick", "OnTick"); set_callback("command", "OnCommand"); set_callback("map load", "OnMapLoad"); --set_callback("",""); musicPlayer = false; --this controls whether the music player is off or on skipSong = false; --this allows the player to skip a song in the playlist songCount = 6; --amount of songs in the playlist --used for array access minSongs = 0; maxSongs = songCount - 1; isPlaying = false; --checks to see if a song is playing or not. Controlled by tick count. tickCount = 0; --used to determine if a song is over or not. songSelection = nil; --used for array access SONGS = --playlist { [0] = " twisted_metal\\music\\loops\\dragula ", [1] = " twisted_metal\\music\\loops\\gentlemenStartYourWeapons ", [2] = " twisted_metal\\music\\loops\\objectIdentified ", [3] = " twisted_metal\\music\\loops\\raceToDestruction ", [4] = " twisted_metal\\music\\loops\\ready2Die ", [5] = " twisted_metal\\music\\loops\\readySetDestroy ", } --to calculate song lengths: -- given a song length of 3:15 as an example. -- 1. Multiply 3 * 60 (since there are 180 seconds in 3 minutes) -- 2. add + 15 (since there are 15 additional seconds in the song -- 3. multiply the entire result by 30 (since there are 30 ticks in one second) -- RESULT: (3 * 60 + 15) * 30 for a 3:15 long song. SONGLENGTHS = --lengths of each song in the playlist. They align with their respective slots in SONGS { [0] = (4 * 60 + 37) * 30, --8310 [1] = (3 * 60 + 23) * 30, --6090 [2] = (3 * 60 + 9) * 30, --5670 [3] = (3 * 60 + 17) * 30, --5910 [4] = (3 * 60 + 50) * 30, --6900 [5] = (3 * 60 + 37) * 30, --6510 } function OnTick() if musicPlayer then --if player wants music if isPlaying == false then --if a song is not playing --pick a random song to play, math.randomseed(os.time()); songSelection = math.random(minSongs,maxSongs); --and play the song playMusic(songSelection, 1); isPlaying = true; else --if a song is playing if tickCount >= SONGLENGTHS[songSelection] or skipSong == true then --if the song has ended or the player wants to skip the song --stop the music. tickCount = 0; playMusic(songSelection, 0); isPlaying = false; skipSong = false; else --if the song has not ended --increment the tick count. tickCount = tickCount + 1; --console_out(tickCount); end end else --if the player does not want music for i = 0, maxSongs do playMusic(i, 0); --safely stop all songs from playing. end isPlaying = false; end end function playMusic(songSelection, toggle) --playMusic is a utility function if toggle == 1 then execute_script("sound_looping_start"..SONGS[songSelection].."none 1"); else execute_script("sound_looping_stop"..SONGS[songSelection]); end end function OnCommand(command) if command.sub(command,0,4) == "play" then --if the command is play musicPlayer = true; --turn on the music player return false elseif command.sub(command,0,4) == "stop" then --if the command is stop musicPlayer = false; --turn off the music player return false; elseif command.sub(command,0,4) == "skip" and musicPlayer == true then --if the command is skip skipSong = true; --skip the song return false; else return true; end end A music player that I made for Chimera. Hopefully someone will find it useful!
  15. Count me in.