Fangames > Engines

RegalPrime-UnityEngine v1.4.1 - 8-18-15

<< < (7/13) > >>

RegalPrime:
https://www.mediafire.com/download/a9awltjiqgw7fhi/I+Wanna+Help+the+Cat+v1.1.zip
Found some last minute bugs and got them fixed (that Reset function on the boss screen messing up again).
If you tested the first version, let me know how this version feels. There are still a couple of things I wish I could smooth out, but things are better than before.
If you haven't tested this game / engine yet, feel free to this version. There is a scene select on the main loading screen, so you can jump around to any place in the game.

Ooohh, also the new Unity version was just released this week. Which means I can update my version (hopefully nothing breaks)
They added in the new GUI stuff, which means I will have to watch all the tutorials and start testing it out. When I get things settled I can update the main loading game screen.
It should be a lot easier to create and design with the new patch. Seems like a fun mini-project.


Well, it is time for the new game / engine release. I will end up being gone all next week so I worked on getting this put out this week.
The amount of backend things I have changed, I would bet there are some bugs somewhere. I ended up adding in a few things I wasn't planning, but the game should run a lot better now (I'm sure its not 100% perfect, but its a big improvement).

** Update Notes **
I put back in the default unity pregame screen to allow for changes in resolution size.
It also has options to change the button settings, but do so at your own risk.
I have not messed around with that window and I have no clue how it interacts with my in game settings.

Platforms pull less when jumping through them (horizontally)
Vertically is still a bit pully though.

Torch pickup / drop is now the X button.

Changed how Button presses were done. They should be more immediate.
Hopefully this should lessen the unresponsiveness.

The below were added to detect when the character is close to a solid object and will move them a shorter distance to prevent the physics bug (where you could clip a deadly object in another block and die)
- Added in ground check
- Added in wall check
- Added in ceiling check (no preventive movement checks yet)
-- There is still a small possibility that you will clip a ground object when falling (you fall way faster per frame than moving), but it is an extreme improvement over the default.
-- This is because the AoE ground check is not as big as I would like atm due to another problem that arose (when I fix that, I should prevent this from happening)

Reset Data on the Loading Scene is no longer an option
- Difficulty options were added in instead (easy / medium / hard)
- Items without the proper difficulty permissions will be disabled
- Nothing in this game uses the difficulty option, but the option and script have been written

Boss Room - cant go backwards a screen
Boss - Spinny hands attack - No RNG on the attack, there should always be a safe spot.
Boss - Paws have 5hp each. 10 was just too much.
Boss - I noticed the death timer on the projectiles was too high and objects were hanging around too long.
-- Changed the death timers based on each attack to the smallest time needed for an object to leave the screen (less objects active at once, less calculations)

Object Pooling put in the new object spawner script (has a variable to disable it if needed)
- This effects any screen with constant spawning of objects (including the boss)
- Objects are now reused instead of constantly creating and destroying themselves (this should increase efficiency).

Object Pooling added to shooting script (reuses bullets)
I think the spike treadmill uses object pooling now as well (Im sure there are others as well).

Added the Reset() Event to every script
- This allows one script to call the Reset() function on all available scripts that are loaded in the scene
- The Reset() function is added to each script that needs it and will change the script back to the initial settings / position / etc
- Instead of constantly deleting and reloading the same scene (and its objects), using this will allow the scripts to reset themselves giving the illusion they have been reloaded
- More efficient, but there is the possibility that some of the Reset() functions could be wrong and thus have bugs.

Reloading the same scene will now call the Reset() Event instead of deleting and reloading the scene (and off of its objects)
- This will allow for key presses to be active when constantly reloading on the same screen (this however may not hold true between scenes)

Commented on every script and sorted them all out

Object pooling went in ok, but the Reset() event on some scripts was a pain (ie the boss / spinny room).
Im sure it is a lot easier to write a script from scratch with the Reset() event in mind instead of modifying an already existing script
It wouldn't surprise me if a few bugs might show up now.

Scene select is available on the loading page - This is for the people who want to jump to a certain scene to test (or just want to browse through my game).
Just move the slider bar to the correct scene number and click "Jump to scene"
Using the jump to scene will use either your current used slot or slot 1 by default.

It gets fairly old writing the back-end scripting so I took a few days off and wrote a nifty background effect.
When this script is triggered, it sends a shockwave-like color changing effect outwards through out the valid tiles.
+1 test scene - Has a few of these trigger objects on a empty scene with different variables set to give a feel of what this script does
+3 new scenes using this script - Created a simple gimmic involving this script.

For ease, I created a button on the loading screen that allows you to jump to these new scenes.
For now, they are in the game, but not attached to any other scenes (they are actually after the "you win scene". After I find they are bug free, I will put them somewhere in the middle of the game.

Picture of the first new scene
(click to show/hide)

RegalPrime:
https://www.mediafire.com/download/slyxbav7kimpf3a/I+Wanna+Help+the+Cat+v1.2.zip

- New GUI system hype !! -
Took me a bit of time to figure how to use it, but I am getting the hang of it. I am also glad I waited instead of learning the old system then learning this one.

Created a new Loading screen using the new GUI. It look nice and crisp and allows for me to change design and whatever without totally breaking the connections anymore <3
It is pretty plain at the moment, but it is a lot better than the old version.
(click to show/hide)
Created a HP Bar GUI + prefab. The HPModule script can use this and it works well displaying the objects / enemies hit points.
Has various options on when to display the HPbar / speed of hp removal / etc.
- Enabled the option to show the HP bar when the bosses paws are hit.

Replaced the basic label script with the new GUI system. Signs and character chat boxes look better. I didn't go overboard creating boxes. Just a simple bordered square that can be expanded upon later. A lot cleaner to work with compared to the old script based GUI.

Created a game over screen using the new GUI. It looks 100% the same, but it needed to be updated.


Finally got around to totally rewriting the camera script. Whereas it worked well before, it was a huge ugly inefficient mess. After sketching out the design, the rewrite went smoothly.
Also updated the script that triggers the camera manipulations when the player trips a spot. This one had a few problems just because I totally changed how the camera script worked from before, but now I think it is all fine.

Save point added an option to reset the default camera position on trigger, which is helpful when resetting the camera on larger scenes (where the camera follows the player).

Put the 4 scenes added last patch into the main game scene lineup.

- Stuffs -
I am a bit disappointed in not being able to smoothly access preventive measures when using physics. Physics are calculated all the time (when there is free time), whereas my preventive checks are calculated once a frame. Most the time the guy will move very well and other times you notice a bit of a snapping effect when running into a wall. I mean its better than dying to objects inside of walls, but I need to dig more into how to do this better. I will probably flesh out the 100% transform 2d-controller and see how it works in game. Sadly it will not have the power to move up slopes and I will have to change a few things if that happens (will have to figure how to do slope climbing later I would guess).

I have been cleaning up the engine files as of late (when I haven't been programming) and am getting to the point where I am feeling better about releasing the engine to the public.
As long as people understand the state the engine is in (not perfect), I have no qualms about releasing it in a somewhat messy state.

RegalPrime:
Hmm, didn't know it was that long since my last update. I probably said this above somewhere, but I really hate programming the more complex back end stuff for a long period of time, but it seems that's all I have been doing since the last update. Also, took some time to learn more about the inner workings of unity so I can program smarter.
No engine / game update, but I am working on a testing room I can use to test some problems / get feedback and might release that later.

Did some research on when unity polls key inputs and when the screen is rendered and changed how key inputs are done again.
Updated and cleaned up both movement scripts. After updating my pixel movement script I found a logic problem where even when not moving, the script was grabbing no movement as an input for that frame. This could cause a one frame delay when actually wanting to move. Knowing when the frame renders now allowed me to clean up the scripts and fix the weird snapping that happened at times when getting close to a wall.

Made the velocity and pixel movement scripts the child of the 2dcontroller and thus can be used interchangeably in the engine. Rewrote the parent to be more generic and encapsulated most of the variables. Was worried about getting this to work right, but the pixel based guy script interacts with all the game objects like he should, so I guess it worked.
IN SHORT, there is a prefab for the physics based movement and a prefab for the pixel based movement character. Both can interact with all of the other objects in the engine without having to change any other scripts.

Put a line of code in the spawn controller so that I can force which guy spawns through the entire game

After having some time, I finally found the new settings to change the size of the collider buffer (came in with the newest patch).
Previously, the default setting caused the player to have a 1.5 pixel extra buffer when "touching" another collider (ie a wall or even the triggering of a deadly object). This buffer made the character much fatter than its normal collider size and caused some weird issues (poor accuracy of jumping / bonking head early / etc)
The settings now allow to go down to 0.01 pixel buffer (a pretty big difference)

This is good HOWEVER, this buffer is used in the physics to help calculate collisions of solid objects. The physics guy collides with corners of certain square objects very weirdly when the buffer is set extremely low. He will kind of bounce off of edges a bit. I am not sure if there are settings that can increase the accuracy of these collisions or the rate in which they are calculated. The good news is that the pixel movement based character does not have this problem and no longer has this collider problem.

Of course, having lost this buffer, some of my objects started acted weird at times (falling through moving platforms and whatnot)
I spent a bit of time updating some major scripts. I haven't had the time to test many of the other object interactions to see if they held up.

I also took this time to figure how and when colliders trigger so that I can create more accurate "deadly objects"
Previously the spike's edge collider was just thrown on "by eye," but now I have a better idea of what to do next.
With that 1.5 pixel fatty buffer before, objects triggered before they should have and were inaccurate, so I shrunk the collider size to compensate. I no longer have to do this and I need to change it back.

Serious update on CalculateChecks script (used to calculate the distance between 2 object's colliders)
- This script is used to detect when the character is grounded and near other solid objects (for movement / gravity reasons)
- AoE calculations to detect wall / ground / ceiling / pits are now generic and will know how to calculate the offsets based on that objects current settings
- Took out the need to have separate code for if the object is flipped / if facing a certain direction / scaled a certain size / etc
- Increased the accuracy of these checks (there was a few places when the character was on the edge of a platform, but this script said he was not grounded and thus played the falling animation and caused him not to be able to jump / refresh the jump)

- Updated the formula to calculate the distance to a wall / ceiling / ground object to deal with all of the variables in one formula
- Calculating the distance to the ground for an edge collider was updated as well (distance to an edge collider for wall / ceiling are not in yet)

AI script now uses check surroundings script to detect walls / ground / etc (same script that is used on the main character. CalculateChecks.cs)
- Added pitcheck to the script to detect if there is a pit in front of the object (used to tell the AI to turn around when patrolling)
- No longer need the offset objects on the AI gameobjects, which should simplify things a bit.
- AI acts more stable because there is no need to manually set the offsets on the gameobject.

Climbing changed to detect walls so there is no studdering / wiggling when climbing and humping walls (also Uses the CalculateChecks.cs script)

Teleport in room script - maintain offset was bugged and fixed.

So, overall, a lot of progress in fixing some major problems that were plaguing the core of this engine (those colliders :/).
Next thing to fix is the aftermath of shrinking that collider buffer and its effect on interaction with other gameobjects (will involve going through most of the prefabs / scripts that interact with the character). Also need to figure how to make the physics movement guy collide with corners better when the collider buffer is set very small.

RegalPrime:
The whole collider issues was one of the main reasons why I haven't released the engine. With solving a majority of these issues + having a workable alternative character that works well (the pixel movement guy), I've found there's no reason to not release it in its current state.

There is still a lot of old items in the engine I wish I had time to rewrite or even add, but for now it is stable enough.
- Uploaded and downloaded and tested to make sure I could open it and whatnot.
- Seems everything is in order
https://www.mediafire.com/download/x1w70hkaq8b11y8/RegalPrime+-+UnityEngine+v1.1.zip


Updated the engine and released game version 1.03
- There are 2 downloads, one uses the physics guy and one uses the pixel based movements as the main player
- Pixel guy moves via transforms and requires almost no collider buffer. Only con is the inability to go up slopes
- Physics guy moves via physics forces but requires a larger collider buffer to remain stable. Increased collider buffer makes the player collider fatter
- Update includes what was listed in the last post + below
- Most of these deal with the aftereffects of messing with collider settings

Hill climbing works on physics guy again
Distance to wall calculation updated to deal with edge colliders
Distance to ceiling calculation updated to deal with edge colliders
Climbing works while upside down
De-childed the character if they are on the treadmill when the individual object recycles itself

Moving platform fixed
- It wasnt that much of the collider size, but the value used to determine when the player was above the collider
- Changed this to a public variable and increased the collider box. This way it can trigger earlier yet still calculate correctly

Reloading a scene with an animation of a dead unit cause a bug - Fixed (forgot to reset the IsDead tag)
Sliding down an edge collider - Am assuming some aftereffect of changing the collider buffer / penetration for penalty values (Fixed)

Found a bug that deals with some weird combination of pressing and releasing the jump button multiple times within one? frame. Happens very rarely.
Need to pinpoint what is actually the cause before attempting a logic fix.


Basic Tutorial
Simple tutorial to cover a few things
(click to show/hide)- So you have no clue what to do -
Download unity at https://unity3d.com/unity/download
Download the engine at https://www.mediafire.com/download/x1w70hkaq8b11y8/RegalPrime+-+UnityEngine+v1.1.zip

Watch the 10 beginner videos on how the editor works. Each is a few minutes long
https://unity3d.com/learn/tutorials/modules/beginner/editor
The other tutorials are useful as well

Unzip engine and open unity.
Open project -> Open other -> select the folder of the unzipped project and open

- Creating a new scene -
File -> New scene
File -> Save scene. Put it into the scenes folder or create a sub folder of it
In order to add / remove scenes from the game goto File -> Build Settings
You should see a list of all of the scenes in the game. Clicking and pressing delete removes them and you can add current scene via that button. You can also move them around by dragging them.
You can probably remove all except the title and load game screen (the first 2 in the list)

- Your new scene -
Your new scene will have a camera in it. Delete it. Now your scene is 100% blank.
Goto Prefab -> Map Objects and select either Entire Room setup or the alt version and pull it onto the scene.
Make sure its X/Y/Z coordiates are 0
Press Play. Congrats your scene should works. Sorry the character is dark. This is because he has a shadow material on him so light effects him (no light = dark). Will tell you how to change this later.

- Objects on your new scene -
GameController = This is how game data is saved and loaded. It also includes a reference to the character for easy access.
The information on the prefab will be populated when the game runs. This is more for reference and not for you to put your own values into (havent hidden the data yet).

PlayerSpawnController = This contains which character spawns and also the locations (or indexes) where he can spawn.
The indexes are represented by the little yellow diamonds beside the warps.
The prefab already has the GuyCharacterPrefab_Physics preloaded into it.
Feel free to drag the pixel version from Prefab -> GuyExtras, GuyCharacterPrefab_Pixel

If you are using the pixel version you have to change a setting.
Edit -> ProjectSettings -> Physics2D, Min Penetration for penalty = 0.0001
If you are using the Physics version change it to
Edit -> ProjectSettings -> Physics2D, Min Penetration for penalty = 0.005

So, remember that your character was dark. If you arent using lighting, look on the SpriteRender component on the guy prefab.
Under material it should show "SpriteShadow." Change it to "Sprites-Default." This can be done for any sprite based object. I used lightning in all of my scenes for effect so by default I made the material shadow.

MusicController = This is the song that plays on that scene. Drag another song from the audio folder to change it.
If a scene transitions and the song is different it will automatically fade and play the new song.
If the scene transitions and the song is the same, it will continue to play.
The music controller also deals with saving / loading / playing / fade / unfade of sound settings

RoomNavigators (purple boxes on each side of the scene)
These navigate between scenes and tells which index / room the character should spawn at (click on the object to see its values)

Save point = It is a save point  :p

So thats it, if you create and add multiple scenes to the build settings. You will be able to traverse through them.

- So you wanted things in your room?? -
Hold V = Snapping

Prefabs are your friends. Everything in that folder is drag and drop stuff for your scenes.
Need some blocks?? Prefab -> MapObjects -> Blocks32x32
Need some Spikes?  Prefab -> MapObjects -> Dangerous
Want some more fancy objects?? Prefab -> IngameObjects

Remember you can also browse my game scenes for examples of the prefabs.

If you dont know what to do, drag it onto the scene and hit the play button.
Mess with the settings and whatnot. As long as you dont overwrite the object in the prefab folder, you can always grab a new default one. Also, settings made while the game is in play automatically revert when the game is stopped.

- Certain things -
A few things about certain tags and layer settings (you need a collider on these objects)
tag = deadly - An object with this tag will kill the player when it touches him
tag = bullet - An object with this tag will damage an enemy
tag = climbable - Player can climb these objects
tag = ground - Destroys bullets

layer = ground - This is important. This layer tells the player he is actually grounded, so objects with that layermask will reflect that.

There are some wierd advanced settings you can screw around with but I figure at this point I dont want beginners digging around in code. This should cover the basics. Let me know if anything needs to be expanded upon.

RegalPrime:
After the initial release, I decided to take a week off of this project (ended up being almost 2 though).
I had a bit of trouble wanting to go back to it because I had no clue what to work on next.

Long story short, I figured I would try to make an avoidance boss.
I had a super script that did a whole bunch of stuff and was used in creating the cat boss in the game (and other things). This includes everything from movement to spawning of objects and shapes. I didn't want to fix what was there, because it will break the other stuff in the game and I really don't want to mess with the boss code anymore. I figured there was no better time than now to create a version 2.0 of that script.

So, I am slowly moving over each function and testing / expanding / and simplifying everything about them. Some of them were, /// uugh, such a stinking mess, Im surprised they worked, lol, those needed total rewrites. Luckily, I was able to condense a few functions together. I have a few more main functions to bring over and then I think I will try some basic avoidance timing and testing to see if  everything is working all right. I think it will go all right, but I am afraid that I may run across some unforeseen problem mostly dealing with manipulating multiple design options in an easy way. In the cat boss I was able to do it, but I wasn't happy with the way I had to code it, hopefully this will change with the new function design.

-Very minor engine code fixes

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version