Hey guys! I am very excited to let you know that the beta release of QoobTris is finally available for download! I have been working on this game off and on for about 1 year now. I have put a lot of blood, sweat, and tears into the game and it is always a great joy when you see your pet project blossom. While the game isn’t incredibly complex, it was written from the ground up with a very modular architecture. I really wanted to be able to use many of the components I wrote for this game in the future. Another tidbit of good news is that I will be releasing the full source code absolutely free to anyone who wishes to use it very soon.
Anyways, enough about that. As far as the game is concerned, there is a new “Gravity” mode that can be enabled in the game menu. This mode makes the game a little easier to play if you find the default “No Gravity” mode to be too difficult. If you have an Xbox 360 controller, feel free to plug it into your laptop because QoobTris is compatible! =) I am sure there may be a few bugs that I missed so if you catch any, please note them here.
The game requires DirectX 9.0c and .NET 2.0 runtimes. Many people have these runtimes already installed but for those of you who might be missing one or both, I have created 2 versions of the installer for your convenience. If you have both of the runtimes, download the “Lite” version. Otherwise just download the Full version… other pc games will thank you for it! ;)
Are you ready to play? Well download away! Just follow the url below and download the version of the installer you need.
Recently I have been employeed at a new company where I work with the CryEngine2 quite frequently. CryTek has released a MOD sdk for their popular Crysis Wars game. In my personal time, I enjoy developing mods for this amazing game. Crysis Wars is a first person shooter game thus the camera by default is set in a first person perspective.
First person perspective
One of the very first mods I wrote for the CryEngine is a Third Person Camera. The CryEngine already supports a third person camera however a developer using Flow Graph is limited as to what they can do with it. For example, the third person camera is at a fixed distance away from the player. A developer can’t really control this at all. That is why I decided to write my own custom flow node for the CryMOD sdk that would give developers the ability to use a flexible third person camera system. Below, you can see a demo of my third person camera as well as the source code.
Third person perspective
And here is the source code.
////////////////////////////////////////////////////// FlowThirdPersonCameraNode.cpp//// Purpose: This flow node gives the developer// more flexibility of controlling// the third person perspective // camera by allowing them to offset// the camera's distance from the player.//// File History:// - 6/05/09 : File created - Brandon Fogerty////////////////////////////////////////////////////#include "StdAfx.h"#include "Nodes/G2FlowBaseNode.h"#include "Cry_Camera.h"#include "Actor.h"
class CFlowThirdPersonCameraNode : public CFlowBaseNode
{
private:enum EInputPorts
{
EIP_SYNC =0,
EIP_DISTANCE,
EIP_HEIGHT,};
public:
CFlowThirdPersonCameraNode(SActivationInfo * pActInfo){}
virtual void GetConfiguration(SFlowNodeConfig &config){staticconst SInputPortConfig inputs[]={
InputPortConfig_Void("sync",_HELP("sync")),
InputPortConfig<float>("distance",-7.0,_HELP("Distance from player")),
InputPortConfig<float>("height",2.0,_HELP("Height relative to the player")),{0},};
config.pInputPorts= inputs;
config.pOutputPorts=NULL;
config.sDescription="Control the third person perspective camera.";
config.SetCategory(EFLN_APPROVED);
}
virtual void ProcessEvent(EFlowEvent evt, SActivationInfo *pActInfo){switch(evt){case eFE_Activate:if(IsPortActive(pActInfo, EIP_SYNC)){
pActInfo->pGraph->SetRegularlyUpdated(pActInfo->myID,true);
}break;
case eFE_Update:// Grab the game's camera view.
CCamera cam = gEnv->pSystem->GetViewCamera();
// Get the local player
IActor * pActor = g_pGame->GetIGameFramework()->GetClientActor();
// If we are in a vehicle, use the default camera system.if(pActor->GetLinkedVehicle()==NULL){// We need to toggle the regular third person camera// so that crysis renders the whole player model and// not just the limbs.if(pActor->IsThirdPerson()==false){
pActor->ToggleThirdPerson();
}// Get our camera's position
Vec3 vecCamPos = pActor->GetEntity()->GetPos();
// Offset the camera on the z axis (Up/Down)
vecCamPos.z= pActor->GetEntity()->GetPos().z+ GetPortFloat(pActInfo, EIP_HEIGHT);
float fDistance = GetPortFloat(pActInfo, EIP_DISTANCE);
// This is a little math to which ensures that our camera is always facing the direction// that our player is looking.
vecCamPos.y= pActor->GetEntity()->GetPos().y+(pActor->GetViewRotation().GetFwdY()* fDistance);
vecCamPos.x= pActor->GetEntity()->GetPos().x+(pActor->GetViewRotation().GetFwdX()* fDistance);
// Override the crysis camera with our newly calculated camera view and we are done!
cam.SetPosition(vecCamPos);
gEnv->pSystem->SetViewCamera(cam);
}break;
}}
virtual void GetMemoryStatistics(ICrySizer *s){
s->Add(*this);
}
virtual ~CFlowThirdPersonCameraNode(){}};
REGISTER_FLOW_NODE("Camera:SetThirdPersonView",CFlowThirdPersonCameraNode);