Gamedev blogs, Working on my VR game! Prototyping stage
Today's Document

oozey mess
we're not kids anymore.

#extradirty

Love Begins
Cosimo Galluzzi

JVL

if i look back, i am lost
tumblr dot com
h
occasionally subtle

izzy's playlists!

pixel skylines
Not today Justin
Three Goblin Art
Sweet Seals For You, Always

ojovivo

seen from United Kingdom
seen from Germany

seen from United States
seen from United States

seen from United Kingdom
seen from United States

seen from United States
seen from United States
seen from United States
seen from Portugal
seen from United States
seen from Sri Lanka

seen from Türkiye

seen from United States

seen from United States

seen from Malaysia

seen from Malaysia
seen from United States

seen from United States

seen from Singapore
@kamathaj
Gamedev blogs, Working on my VR game! Prototyping stage

Anya is live and ready to show you everything. Watch her strip, dance, and perform exclusive shows just for you. Interact in real-time and make your fantasies come true.
Free to watch • No registration required • HD streaming
When I found that Debug.Log() is an expensive operation. Learning the Unity Profiler. It's a important tool to optimize your Game functionality!
Character Controller
Using RayCasting
RayCastController.cs
using UnityEngine; using System.Collections; [RequireComponent (typeof (BoxCollider2D))] public class RayCastController : MonoBehaviour { public LayerMask collisionMask; public BoxCollider2D collider ; public RaycastOrigins raycastorigins; public int horizontalRaycount = 4; public int verticalRaycount = 4; //Setting the number of horizontal and vertical rays [HideInInspector] public float horizontalRayspacing ; [HideInInspector] public float verticalRayspacing; //Spacing between each horizonatal and vertical ray public const float skinWidth = .015f; //CameraController class has a start method, and this method will override it ...Awake method is called before Start() //Edit: Renaming this 'Start' method to 'Awake' method. public virtual void Awake(){ collider = GetComponent(); //Component required is the BoxCollider of the Player object } public virtual void Start(){ CalculateRaySpacing(); } public void UpdateRaycastOrigins(){ Bounds bounds = collider.bounds ; //Bounds class gives you the bounds of a particular object bounds.Expand(skinWidth * -2); //Replace new bounds of the RayCast origins raycastorigins.bottomleft = new Vector2(bounds.min.x,bounds.min.y); //Set the Origins raycastorigins.bottomright = new Vector2(bounds.max.x,bounds.min.y); raycastorigins.topleft = new Vector2(bounds.min.x,bounds.max.y); raycastorigins.topright = new Vector2(bounds.max.x,bounds.max.y); } public void CalculateRaySpacing(){ Bounds bounds = collider.bounds; bounds.Expand(skinWidth * -2); //Mathf.Clamp is used to fix a Range to the raycount horizontalRaycount = Mathf.Clamp(horizontalRaycount,2,int.MaxValue); verticalRaycount = Mathf.Clamp(verticalRaycount,2,int.MaxValue); horizontalRayspacing = bounds.size.y / (horizontalRaycount - 1 ); verticalRayspacing = bounds.size.x / (verticalRaycount - 1 ); } public struct RaycastOrigins{ //Structure that defines the corner points of the RaycastOrigins public Vector2 topleft, topright; public Vector2 bottomleft, bottomright; } }
Player.cs
using UnityEngine; using System.Collections; [RequireComponent (typeof(PlayerController))] public class Player : MonoBehaviour { PlayerController controller; public float maxjumpHeight = 4f; public float minjumpHeight = 1f; public float timeToApexHeight = .4f; float moveSpeed = 6f; float accelerationAirBorne = .2f; float accelerationGrounded = 0.1f; float velocityReference; //Bunch of Vector2's for different wall jumps public Vector2 wallJumpClimb; public Vector2 wallJumpOff; public Vector2 wallJumpLeap; public float wallStickTime = .25f; public float timeToUnstick; //used for Sliding along the walls public float wallSlideSpeedMax = 3f; Vector3 velocity; float gravity; float maxjumpVelocity; float minjumpVelocity; void Start(){ controller = GetComponent(); gravity = -(2 * maxjumpHeight)/Mathf.Pow(timeToApexHeight,2); maxjumpVelocity = Mathf.Abs (gravity) * timeToApexHeight; minjumpVelocity = Mathf.Sqrt(2 * Mathf.Abs(gravity) * minjumpHeight); print ("Gravity"+ gravity + "\t JumpVelocity"+ maxjumpVelocity +"\tMin Jump velocity" + minjumpVelocity); } void Update(){ Vector2 input = new Vector2(Input.GetAxisRaw("Horizontal"), Input.GetAxisRaw("Vertical")); // -1 if wall is to the left, 1 if the wall is to the right int wallDirX = (controller.collisions.left)? -1: 1; float targetVelocity = input.x * moveSpeed; //Smoothing the sideways movement of the player //velocity.x = targetVelocity * Time.deltaTime; //I think SmoothDamp will effectively give you the same result as multiplying by Time.DeltaTime velocity.x = Mathf.SmoothDamp(targetVelocity,velocity.x,ref velocityReference, (controller.collisions.below)? accelerationGrounded: accelerationAirBorne); bool wallSliding = false; //Used for sliding along the wall if((controller.collisions.left || controller.collisions.right) && !controller.collisions.below && velocity.y < 0 ){ wallSliding = true; if(velocity.y < -wallSlideSpeedMax){ velocity.y = -wallSlideSpeedMax; } if(input.x != wallDirX && input.x !=0){ velocityReference = 0; velocity.x = 0; if(timeToUnstick >= 0 ){ timeToUnstick -= Time.deltaTime; } else{ timeToUnstick = wallStickTime; } } else{ timeToUnstick = wallStickTime; } } if(Input.GetKeyDown(KeyCode.Space)){ //Wall sliding stuff and jump stuff along the walls if(wallSliding){ if(wallDirX == input.x){ //Case 1 where we want to jump on the same wall velocity.x = -wallDirX * wallJumpClimb.x; velocity.y = wallJumpClimb.y; } else if(input.x == 0){ //Case 2 where we want to jump off the walls to the ground velocity.x = -wallDirX * wallJumpOff.x; velocity.y = wallJumpOff.y; } else { //Case 3 where we want to jump to the adjacent wall velocity.x = -wallDirX * wallJumpLeap.x; velocity.y = wallJumpLeap.y; } } if(controller.collisions.below){ velocity.y = maxjumpVelocity; } } //Variable jump.. The y velocity is always greater than the minjumpVelocity if(Input.GetKeyUp(KeyCode.Space)){ if(velocity.y > minjumpVelocity){ velocity.y = minjumpVelocity; } } velocity.y += gravity * Time.deltaTime; controller.Move(velocity * Time.deltaTime, input); //Edit: The below lines were moved from Line 95 to here...The reason being the moving platform changes the collisions.above and below if(controller.collisions.above || controller.collisions.below){ velocity.y = 0; } } }
PlayerController.cs
using UnityEngine; using System.Collections; [RequireComponent (typeof(BoxCollider2D))] //Setting the bounding area for our script public class PlayerController : RayCastController { public float maxClimbAngle = 80f; public float maxDescendAngle = 75f; public CollisionInfo collisions; Vector2 playerInput; //Start method overriding the start method in the RayCastController class public override void Start () { base.Start (); collisions.faceDirection = 1; } //Overriding the method in the PlatformController class public void Move(Vector3 velocity, bool standingOnPlatform = false){ Move(velocity, Vector2.zero, standingOnPlatform); } //Edit: Move() takes in a third parameter Vector2 input... //Used for controlling the input since PlayerController class has no control over the input public void Move(Vector3 velocity,Vector2 input, bool standingOnPlatform = false){ UpdateRaycastOrigins(); collisions.Reset (); playerInput = input; if(velocity.x != 0){ collisions.faceDirection = (int)Mathf.Sign (velocity.x); } HorizontalCollisions(ref velocity); if(velocity.y < 0){ DescendSlope(ref velocity); } if(velocity.y != 0){ VerticalCollisions(ref velocity); } if(standingOnPlatform ){ collisions.below = true; } transform.Translate (velocity); } /// /// Checks for vertical collisions. /// /// Velocity. /// In other words, when the RayCast hits the box collider, this functions gives the code to handle all the player behaviour void VerticalCollisions(ref Vector3 velocity){ //Direction is -1 when going down, 1 when going up float directionY = Mathf.Sign(velocity.y); float rayLength = Mathf.Abs(velocity.y) + skinWidth; for (int i =0; i< verticalRaycount; i++) { Vector2 rayOrigin = (directionY == -1 )? raycastorigins.bottomleft: raycastorigins.topleft; rayOrigin += Vector2.right * (verticalRayspacing * i + velocity.x); RaycastHit2D hit = Physics2D.Raycast(rayOrigin,Vector2.up * directionY, rayLength, collisionMask ); //Just for debugging process..This statement can be omitted! Debug.DrawRay(rayOrigin , Vector2.up * directionY * rayLength, Color.red); if(hit) { //Script for allowing the players to jump through certain platforms if(hit.collider.tag == "ThroughPlatform"){ if(directionY == 1 || hit.distance == 0){ continue; } if(collisions.fallingThroughPlatform){ //The down Button pressed is not instantaneous if we want to fall through platform continue; } if(playerInput.y == -1){ //If the player wants to fall through the platform when downButtonPressed collisions.fallingThroughPlatform = true; Invoke("ResetFallingThroughPlatform",.5f); continue; } } velocity.y = (hit.distance - skinWidth) * directionY; rayLength = hit.distance; if(collisions.climbingSlope) velocity.x = velocity.y / (Mathf.Tan (Mathf.Deg2Rad * collisions.slopeNew) * Mathf.Sign (velocity.x)); collisions.above = directionY == 1; collisions.below = directionY == -1; } } if(collisions.climbingSlope){ float directionX = Mathf.Sign (velocity.x); rayLength = Mathf.Abs(velocity.x) + skinWidth; Vector2 rayOrigin = (directionX == -1)? raycastorigins.bottomleft: raycastorigins.bottomright + Vector2.up * velocity.y; RaycastHit2D hit = Physics2D.Raycast(rayOrigin, Vector2.right * directionX, rayLength, collisionMask); if(hit){ float angle = Vector2.Angle(hit.normal, Vector2.up); if(angle != collisions.slopeNew){ velocity.x = (hit.distance - skinWidth) * directionX; collisions.slopeNew = angle; } } } } /// /// Checks for the horizontal collisions /// /// Velocity. /// In other words, when the RayCast hits the box collider, this functions gives the code to handle all the player behaviour void HorizontalCollisions(ref Vector3 velocity){ float directionX = collisions.faceDirection; float rayLength = Mathf.Abs(velocity.x) + skinWidth; //For wall climbing cases where the player is touching the wall but unable to slide... if(Mathf.Abs(velocity.x) < skinWidth){ rayLength = 2 * skinWidth; } for (int i =0; i< horizontalRaycount; i++) { Vector2 rayOrigin = (directionX == -1 )? raycastorigins.bottomleft: raycastorigins.bottomright; rayOrigin += Vector2.up * (horizontalRayspacing * i); RaycastHit2D hit = Physics2D.Raycast(rayOrigin,Vector2.right * directionX, rayLength, collisionMask ); Debug.DrawRay(rayOrigin , Vector2.right * directionX * rayLength, Color.red); if(hit) { if(hit.distance == 0){ continue; } //Finding the angle of the slope float slopeAngle = Vector2.Angle(hit.normal,Vector2.up); if(i == 0 && slopeAngle <= maxClimbAngle){ ClimbSlope(ref velocity, slopeAngle); } if(!collisions.climbingSlope || slopeAngle > maxClimbAngle){ velocity.x = (hit.distance - skinWidth) * directionX; rayLength = hit.distance; if(collisions.climbingSlope) velocity.y = Mathf.Tan(collisions.slopeNew * Mathf.Deg2Rad) * Mathf.Abs (velocity.x); collisions.left = directionX == -1; collisions.right = directionX == 1; } } } } //Method to climb slopes void ClimbSlope(ref Vector3 velocity, float slopeAngle){ float moveDistance = Mathf.Abs (velocity.x); float climbVelocityY = Mathf.Sin (slopeAngle * Mathf.Deg2Rad) * moveDistance; if(velocity.y
PlatformController.cs
using UnityEngine; using System.Collections; using System.Collections.Generic; public class PlatformController : RayCastController { public LayerMask passengerMask; Vector3[] globalWayPointPos; public float speed; int fromWaypointIndex; float percentBetween; public bool cyclic; public float waitTime; float nextMoveTime; public Vector3[] localWayPoints; [Range(0,3)] public float easeAmount; List passengermovement; Dictionary passengerDictionary = new Dictionary(); public override void Start(){ base.Start(); globalWayPointPos = new Vector3[localWayPoints.Length]; for(int i = 0 ; i< localWayPoints.Length; i++ ){ globalWayPointPos[i] = localWayPoints[i] + transform.position; } } /// /// Smoothing the platform so that we provide some acceleration and deceleration during its travel /// This is done by the equation /// y = (x^a)/((x^a) + (1-x)^a)) /// For x = 1...There is no smoothing (The line is y = 1) /// Gives best results for x < 3 /// float PlatformSmoothing(float x){ float a = easeAmount + 1; return (Mathf.Pow (x,a)/(Mathf.Pow (x,a) + Mathf.Pow (1-x,a))); } public void Update(){ UpdateRaycastOrigins(); Vector3 velocity = CalculatePlatformMovement(); CalculatePassengerMovement(velocity); MovePassengers(true); transform.Translate(velocity); MovePassengers(false); } Vector3 CalculatePlatformMovement(){ if(Time.time <= nextMoveTime){ return Vector3.zero; } fromWaypointIndex %= globalWayPointPos.Length; int toWaypointIndex = (fromWaypointIndex + 1) % globalWayPointPos.Length ; //The next waypoint is simply the previous waypoint + 1 float distanceBetweenWaypoints = Vector3.Distance(globalWayPointPos[fromWaypointIndex],globalWayPointPos[toWaypointIndex]); percentBetween += Time.deltaTime * speed/ distanceBetweenWaypoints; float easeBetween = Mathf.Clamp01(percentBetween); Vector3 newPos = Vector3.Lerp(globalWayPointPos[fromWaypointIndex], globalWayPointPos[toWaypointIndex], PlatformSmoothing(easeBetween)); if(percentBetween >= 1){ percentBetween = 0; fromWaypointIndex ++; if(!cyclic){ if(fromWaypointIndex >= globalWayPointPos.Length- 1){ fromWaypointIndex = 0; System.Array.Reverse(globalWayPointPos); } } nextMoveTime = Time.time + waitTime; } return newPos - transform.position; } public void MovePassengers(bool beforeMovePlatform){ foreach(PassengerMovement passenger in passengermovement){ if(!passengerDictionary.ContainsKey(passenger.transform)){ passengerDictionary.Add(passenger.transform, passenger.transform.GetComponent()); } if(passenger.beforeMovePlatform == beforeMovePlatform){ //GetComponent calls is not good as far as optimization is concerned!!!! passenger.transform.GetComponent().Move(passenger.velocity, passenger.standingOnPlatform); } } } public void CalculatePassengerMovement(Vector3 velocity){ HashSet MovedPassengers = new HashSet(); passengermovement = new List(); float directionX = Mathf.Sign (velocity.x); float directionY = Mathf.Sign (velocity.y); ///Movement of the platform vertically if(velocity.y != 0){ float rayLength = Mathf.Abs(velocity.y) + skinWidth; for (int i =0; i< verticalRaycount; i++){ Vector2 rayOrigin = (directionY == -1 )? raycastorigins.bottomleft: raycastorigins.topleft; rayOrigin += Vector2.right * (verticalRayspacing * i); RaycastHit2D hit = Physics2D.Raycast(rayOrigin,Vector2.up * directionY, rayLength, passengerMask ); if(hit && hit.distance != 0) { if(!MovedPassengers.Contains(hit.transform)){ MovedPassengers.Add(hit.transform); float pushX = (directionY == 1)? velocity.x:0; float pushY = velocity.y - (hit.distance - skinWidth) * directionY; passengermovement.Add(new PassengerMovement(hit.transform, new Vector3(pushX,pushY), directionY == 1,true)); } } } } ///Movement of the platform horizontally if(velocity.x !=0){ float rayLength = Mathf.Abs(velocity.x) + skinWidth; for (int i =0; i< horizontalRaycount ; i++){ Vector2 rayOrigin = (directionX == -1 )? raycastorigins.bottomleft: raycastorigins.bottomright; rayOrigin += Vector2.up * (verticalRayspacing * i); RaycastHit2D hit = Physics2D.Raycast(rayOrigin,Vector2.up * directionX, rayLength, passengerMask ); if(hit && hit.distance != 0){ if(!MovedPassengers.Contains(hit.transform)){ MovedPassengers.Add(hit.transform); float pushX = velocity.x - (hit.distance - skinWidth) * directionX; float pushY = -skinWidth; //-skinWidth downward force so that the player is able to jump when squashed by the platform passengermovement.Add(new PassengerMovement(hit.transform, new Vector3(pushX,pushY), false,true)); } } } } //If a passenger is on top of horizontally or downward moving platform if(directionY == -1 || (velocity.y == 0 && velocity.x != 0) ){ float rayLength = skinWidth * 2f; for (int i =0; i< verticalRaycount; i++){ Vector2 rayOrigin = raycastorigins.topleft + Vector2.right * (verticalRayspacing * i); RaycastHit2D hit = Physics2D.Raycast(rayOrigin,Vector2.up, rayLength, passengerMask ); if(hit && hit.distance != 0){ if(!MovedPassengers.Contains(hit.transform)){ MovedPassengers.Add(hit.transform); float pushX = velocity.x; float pushY = velocity.y; passengermovement.Add(new PassengerMovement(hit.transform, new Vector3(pushX,pushY), true, false)); } } } } } public struct PassengerMovement{ public Transform transform; public Vector3 velocity; public bool standingOnPlatform; public bool beforeMovePlatform; public PassengerMovement(Transform _transform, Vector3 _velocity, bool _standingOnPlatform, bool _beforeMovePlatform){ transform = _transform; velocity = _velocity; standingOnPlatform = _standingOnPlatform; beforeMovePlatform = _beforeMovePlatform; } } //The local way points for the Platform Controller can be shown in the inspector.. For this, the OnDrawGizmos() function is used public void OnDrawGizmos(){ if(localWayPoints != null){ Gizmos.color = Color.red; float size = .3f; for (int i =0 ; i < localWayPoints.Length; i ++ ){ Vector3 globalWayPointPosition = (Application.isPlaying)? globalWayPointPos[i] : (localWayPoints[i] + transform.position); Gizmos.DrawLine(globalWayPointPosition - Vector3.up * size, globalWayPointPosition + Vector3.up * size); Gizmos.DrawLine(globalWayPointPosition - Vector3.left * size, globalWayPointPosition + Vector3.left * size); } } } }
CameraController.cs
using UnityEngine; using System.Collections; /// /// Camera Controller Class for controlling the movement of the MainCamera /// There will be a Rectangular Area focusing on the Player. The Player can move left, right by touching the boundaries of the focus Area. /// The camera will follow the focus Area depending upon the direction in which the Player moves /// This is a popular convention to make the Camera follow the player, and it is used because it requires less camera movement to track the player. /// public class CameraController : MonoBehaviour { public Vector2 focusAreaSize; //For an area around the player that focuses on the player public PlayerController controller; FocusArea focusArea; public float verticalOffset; void Start(){ focusArea= new FocusArea(controller.collider.bounds, focusAreaSize); } void LateUpdate(){ focusArea.UpdateBounds(controller.collider.bounds); Vector3 focusOffset = focusArea.center + Vector2.up * verticalOffset; transform.position = (Vector3)focusOffset + Vector3.forward * -10; } //Just used for Debugging purposes void OnDrawGizmos(){ Gizmos.color = new Color(1,0,0,.5f); Gizmos.DrawCube(focusArea.center, focusAreaSize); } struct FocusArea{ public Vector2 center; float left, right; float top, bottom; public Vector2 velocity; public FocusArea(Bounds targetBounds, Vector2 size){ left = targetBounds.center.x - size.x/2; right = targetBounds.center.x + size.x/2; bottom = targetBounds.min.y; top = targetBounds.min.y + size.y; center = new Vector2((left+ right)/2,(top + bottom)/2); velocity = Vector2.zero; } public void UpdateBounds(Bounds targetBounds){ //In the horizontal direction 'x' float shiftX = 0; if(targetBounds.min.x < left){ shiftX = targetBounds.min.x - left; } else if(targetBounds.max.x > right){ shiftX = targetBounds.max.x - right; } left += shiftX; right += shiftX; //In the vertical direction 'y' float shiftY = 0; if(targetBounds.min.y < bottom){ shiftY = targetBounds.min.y - bottom; } else if(targetBounds.max.y > top){ shiftY = targetBounds.max.y - top; } bottom += shiftY; top += shiftY; center = new Vector2((left+ right)/2,(top + bottom)/2); velocity = new Vector2(shiftX,shiftY); } } }
2D Platformer (Day 1)
Day 2: Will add additional functionality such as enemy AI, sounds, health bar etc.
2D Platformer Character Controller creation

Anya is live and ready to show you everything. Watch her strip, dance, and perform exclusive shows just for you. Interact in real-time and make your fantasies come true.
Free to watch • No registration required • HD streaming
Working with RayCasting
Collision Detection using RayCasting: (For a 2d style platformer)
WayPoint based Platform Controller (The red crosshairs show the WayPoints)
using UnityEngine; using System.Collections;[RequireComponent (typeof(BoxCollider2D))] //Setting the bounding area for our script public class PlayerController : MonoBehaviour { const float skinWidth = .015f; BoxCollider2D collider ; RaycastOrigins raycastorigins; public int horizontalRaycount = 4; public int verticalRaycount = 4; //Setting the number of horizontal and vertical rays float horizonatalRayspacing ; float verticalRayspacing; //Spacing between each horizonatal and vertical ray void Start(){ collider = GetComponent<BoxCollider2D>(); //Component required is the BoxCollider of the Player object } //Just testing void Update(){ UpdateRaycastOrigins(); CalculateRaySpacing(); Debug.DrawRay(raycastorigins.bottomright,Vector2.down); for (int i =0; i< verticalRaycount; i++) { Debug.DrawRay(raycastorigins.bottomleft + Vector2.right * verticalRayspacing * i , Vector2.up * -2, Color.red); } } void UpdateRaycastOrigins(){ Bounds bounds = collider.bounds ; //Bounds class gives you the bounds of a particular object bounds.Expand(skinWidth * -2); //Replace new bounds of the RayCast origins raycastorigins.bottomleft = new Vector2(bounds.min.x,bounds.min.y); //Set the Origins raycastorigins.bottomright = new Vector2(bounds.max.x,bounds.min.y); raycastorigins.topleft = new Vector2(bounds.min.x,bounds.max.y); raycastorigins.topright = new Vector2(bounds.max.x,bounds.max.y); } void CalculateRaySpacing(){ Bounds bounds = collider.bounds; bounds.Expand(skinWidth * -2); horizontalRaycount = Mathf.Clamp(horizontalRaycount,2,int.MaxValue); verticalRaycount = Mathf.Clamp(horizontalRaycount,2,int.MaxValue); horizonatalRayspacing = bounds.size.y / (horizontalRaycount - 1 ); verticalRayspacing = bounds.size.x / (verticalRaycount - 1 ); } struct RaycastOrigins{ //Structure that defines the corner points of the RaycastOrigins public Vector2 topleft, topright; public Vector2 bottomleft, bottomright; } }
Counter-Strike 1.6 Map Design
Hey folks!
This is my first attempt at Map making. Starting off creating maps/levels for counter-Strike 1.6 using Valve Hammer Editor (Ver 3.1) provided in the Source SDK. Valve Hammer Editor is a tool primarily used for developing the architectural background of the level, object placement, texture-mapping, lighting, and the object interaction with the player entity.
Screenshot 1:
I’ve created two versions of the same map.Â
de_deathmatch - This version has the classic deathmatch scenario between counter-terrorists and terrorists. Terrorists have to find the bomb site inside the building and plant the bomb. Counter-terrorists have to kill all the terrorists and/or defuse the bomb before it goes off.
cs_dept_hostage - Hostage rescue. Inside the building, there are 8 hostages that need to be rescued by the counter-terrorists.
You can download the maps here:
de_deathmatch.rar
cs_dept_hostage.rar
IMP!!!
This map can be played in both Counter-Strike 1.6 as well as in Counter-Strike:CZ. I tried to run it in CS:Source, but it needs to be converted completely. The textures have to be changed, the entities and models are different. And so, I scrapped it.Â
This map is tested on both 1.6 and CZ, and it runs fine. Lowest fps recorded is 26 fps which should be fine with all latest PCs.
To run the map:
1. Copy the .bsp, .nav and .txt files in the ‘maps’ folder of your counter-strike game folder. Ideally, it’s location is ...\Valve\Counter-Strike\cstrike\maps
(my location is C:\Program Files (x86)\Valve\Counter-Strike\cstrike\maps)
2. Open your CS Game and PLAY!
#FirstLook Counter Strike 1.6 Map using Hammer Valve Editor...
Testing my map for all possible errors...
Turns out I’ve a standard version of Photoshop CS6 that doesn’t support video keyframe animation. It is only present in the extended version.Â
Whenever I was trying to rotate a single keyframe (single lightsaber) the effect of rotation was propagated to the first keyframe as well, thereby having no animation at all.
With this animation, you can only change the position, opacity and the style for each frame (but not rotation), due to which I couldn’t create a complex lightsaber duel (Darth Vader vs Luke/ Anakin vs Obi-Wan).
Would like to try out how this works out in Flash.

Anya is live and ready to show you everything. Watch her strip, dance, and perform exclusive shows just for you. Interact in real-time and make your fantasies come true.
Free to watch • No registration required • HD streaming
My Goal: To develop a Game for the Steam Community before Jan 2017.
Tileable 2D Village Background
2D Art (Textures) created in Adobe Photoshop CS6
I’m kinda more inclined towards Game programming than game design.
Having said that, it is necessary to have some basic knowledge and understanding of game textures and common design elements used in games.
A simple level background for side scrolling games created using these textures (Light source: Top Right)
Level 1:
Level 2:
Level 3:
Level 4:
A Multipurpose Main Menu Screen
Created a multipurpose MainMenu Screen with interactive features and basic custom animation based on the Star Wars theme. The controls haven’t yet been added with the functionality but then the basic structure of the main menu is designed.
I have made available the main menu for download (You’ll require Unity Player to run the file)
click here
This is a reference Main Menu that I’m going use in my future projects.
Since CutScene functionality (Movie Texture class) was available only in the Unity Pro version, it was necessary to convert the video to a sequence of images and then import them via a third party asset (available in the asset store of Unity) called Universal Video Texture Lite ( click here ). The CutScene is nothing but a series of 1948 bitmap images run at 30 frames per second. An audio clip is attached to the mainCamera to give the effect of the scene.
I request Unity Developers to allow standard users of Unity to use the MovieTexture class to embed video textures in our game.
The CutScene is the lightsaber battle between Darth Vader and Luke Skywalker in Star Wars Episode V: The Empire Strikes Back.Â
An Epic scene....
Have fun!
An Incomplete Race Track..
This is today’s work!
I must confess Level Design is a bit tedious. It requires long hours of hard work, focus and patience to build something that is decently playable.
I used the Hermite Spline Controller (Uses Bezier curves: found here ) to control the camera movement creating a cutscene (To show the overall terrain of the incomplete track).
The 3D RACING GAME WILL COME OUT SOON!!
Keep you posted!

Anya is live and ready to show you everything. Watch her strip, dance, and perform exclusive shows just for you. Interact in real-time and make your fantasies come true.
Free to watch • No registration required • HD streaming
Code for my Boat Controllers:
Switching between FPS on the boat and the boat Controller (Third person)
void Update () { //Set to boat mode if (Input.GetKey ("1")) { boat.GetComponent<Rigidbody>().isKinematic = false; boat.GetComponent<BoatMovement>().enabled = true; boatCamera.SetActive(true); player.SetActive(false); } //Set to player mode if (Input.GetKey ("2")) { boat.GetComponent<Rigidbody>().isKinematic = false; boat.GetComponent<BoatMovement>().enabled = false; boatCamera.SetActive(false); player.SetActive(true); player.transform.position = playerStartPosition.transform.position; } }
Movement of the third person Controller for boat
private Rigidbody rbody; public float turnspeed = 1000f; public float acceleratespeed = 1000f; // Use this for initialization void Start () { rbody = GetComponent<Rigidbody> (); } // Update is called once per frame void Update () { float h = Input.GetAxis ("Horizontal"); float v = Input.GetAxis ("Vertical"); rbody.AddTorque (0f, h*turnspeed * Time.deltaTime, 0f); rbody.AddForce (transform.forward * v * acceleratespeed * Time.deltaTime); }
An FPS Controller fishing on a boat that can be controlled by a third-person controller. Water environment as the background.Â