WoW Style RPG Starter Kit
by Nicolai Dutka · 04/16/2008 (6:30 am) · 41 comments
The resource I offer you is an example folder utilizing the code provided by Ehab's resource together with some basic starter RPG functions written by myself. The entire example folder has been optimized for speed and disk space and contains no extra shape files, textures, or any of that sort.
Please make special note of the following:
bin/server/activator.cs - contains code to allow players to select world objects, NPC's, and more by pressing the Space Bar while not in combat mode. This is done using an invisible, short range projectile.
bin/server/scripts/commands.cs - contains code near the bottom of the file that is used for selecting objects by clicking on them. This is where you can trigger events to happen "on click".
bin/server/masterCommands.cs - contains some code for your master commands. There is some code in there from an old project of mine that you'll want to replace, but I left it in for example purposes. (You may also find the first bit of it useful.)
bin/client/scripts/default.bind.cs - contains altered key bindings to allow for WoW style controls. Note that holding BOTH left click and right click at the same time does not make you move as in WoW, but everything else is pretty much the same. Scroll to the end of the file to see some other "player control functions" I have added in for RPG purposes. It should be noted that I originally was going to make a game that had more of a Final Fantasy Tactics style battle system in which you could control multiple characters in utilizing a turn-based "counter" method. Some of the functions in there will limit player movements based on which mode you are in (battle mode and world mode). If you want a more dynamic, real-time battle system like WoW, do not use the "battleMode" function.
This resource was built using TGE 1.5.2 (3d Torque Game Engine). You must have a license for TGE to develop games using this resource and credit must be given to myself, Ehab, and anyone that contributed to Ehab's resource. (A "Special Thanks" would do just fine.) No source compilation is necessary, simply extract the zip file and start building your RPG!! As such, no engine source will be included either! If you need to make engine code changes in the future, you MUST visit Ehab's resource page and apply his changes first! You must apply ALL of his code and get a successful recompile before making any new engine code changes! (This is done easily by downloading his resource files and replacing yours on a 'clean install' of TGE 1.5.2. You only need to follow the instructions on his page if you are applying the changes manually.) I do this for a couple of reasons:
1. This file is for educational purposes and may be used as a means to jump-start your project.
2. This file is meant for those of you who don't feel like, care to, or know how to edit engine code and recompile.
3. I did not have a hand in the creation of Ehab's resource or any of the contributing resources. It originally started out as a favor for me (before he posted it as a resource) and now I am doing my part to give back to all of you.
Thank you for your interest and here is the file:
DOWNLOAD HERE: RPG Starter Kit
Please note: For a full credits listing of everyone who contributed to the making of this, please see Ehab's original resource. All of my credit goes to Ehab and myself, Ehab credits the people who made his work possible.
Please make special note of the following:
bin/server/activator.cs - contains code to allow players to select world objects, NPC's, and more by pressing the Space Bar while not in combat mode. This is done using an invisible, short range projectile.
bin/server/scripts/commands.cs - contains code near the bottom of the file that is used for selecting objects by clicking on them. This is where you can trigger events to happen "on click".
bin/server/masterCommands.cs - contains some code for your master commands. There is some code in there from an old project of mine that you'll want to replace, but I left it in for example purposes. (You may also find the first bit of it useful.)
bin/client/scripts/default.bind.cs - contains altered key bindings to allow for WoW style controls. Note that holding BOTH left click and right click at the same time does not make you move as in WoW, but everything else is pretty much the same. Scroll to the end of the file to see some other "player control functions" I have added in for RPG purposes. It should be noted that I originally was going to make a game that had more of a Final Fantasy Tactics style battle system in which you could control multiple characters in utilizing a turn-based "counter" method. Some of the functions in there will limit player movements based on which mode you are in (battle mode and world mode). If you want a more dynamic, real-time battle system like WoW, do not use the "battleMode" function.
This resource was built using TGE 1.5.2 (3d Torque Game Engine). You must have a license for TGE to develop games using this resource and credit must be given to myself, Ehab, and anyone that contributed to Ehab's resource. (A "Special Thanks" would do just fine.) No source compilation is necessary, simply extract the zip file and start building your RPG!! As such, no engine source will be included either! If you need to make engine code changes in the future, you MUST visit Ehab's resource page and apply his changes first! You must apply ALL of his code and get a successful recompile before making any new engine code changes! (This is done easily by downloading his resource files and replacing yours on a 'clean install' of TGE 1.5.2. You only need to follow the instructions on his page if you are applying the changes manually.) I do this for a couple of reasons:
1. This file is for educational purposes and may be used as a means to jump-start your project.
2. This file is meant for those of you who don't feel like, care to, or know how to edit engine code and recompile.
3. I did not have a hand in the creation of Ehab's resource or any of the contributing resources. It originally started out as a favor for me (before he posted it as a resource) and now I am doing my part to give back to all of you.
Thank you for your interest and here is the file:
DOWNLOAD HERE: RPG Starter Kit
Please note: For a full credits listing of everyone who contributed to the making of this, please see Ehab's original resource. All of my credit goes to Ehab and myself, Ehab credits the people who made his work possible.
#2
04/16/2008 (12:43 pm)
Technically, you don't need ANYTHING but this file but yes, it was created using (not for) TGE 1.5.2.
#3
04/20/2008 (5:09 am)
Big thanks for this powerful pack!!!
#4
04/25/2008 (11:18 am)
Does anyone know if this works for TGEA?
#5
If you want this for TGEA, you will need to visit Ehab's resource and apply the changes manually.
After I have completed my current project and if there is enough demand, I will make a TGEA version of this resource. Until then, you are on your own.
04/25/2008 (11:43 am)
This was premade using TGE 1.5.2. This is an example folder from TGE 1.5.2.If you want this for TGEA, you will need to visit Ehab's resource and apply the changes manually.
After I have completed my current project and if there is enough demand, I will make a TGEA version of this resource. Until then, you are on your own.
#6
In WoW:
hold left click, move mouse -> controls camera
At the same time, you can move your player with the keyboard seperately.
Also, you can pan around and see your character from the front, etc.
06/05/2008 (6:23 am)
This doesn't provide for panning camera mode:In WoW:
hold left click, move mouse -> controls camera
At the same time, you can move your player with the keyboard seperately.
Also, you can pan around and see your character from the front, etc.
#7
06/05/2008 (6:40 am)
That is correct. This is "WoW Style", so it isn't exact. I did not create the camera controls myself. If you want to attempt to more closely emulate the controls, please see Ehab's resource to see where the camera controls originated from as that is going to be the best place to get help with that.
#8
once of all
I Press Alt+c For Edit Game And Again Alt+C but camera near character's and ı can't move back camera :S
07/23/2008 (2:45 pm)
ı have problem pls help me ... some script codes have problem ...once of all
I Press Alt+c For Edit Game And Again Alt+C but camera near character's and ı can't move back camera :S
#9
07/26/2008 (1:45 pm)
Is there a way to lock the camera at a top-down view on the player, and not allow them to move it around?
#10
İn Game.. i press alt+c and use something then press alt+c camera top-down view on the player near character ... StandPoint scale down :S look like in fps mode press then tab :S if you want SS thats Here>
Normal:http://img371.imageshack.us/my.php?image=normaljg7.jpg
Then:http://img92.imageshack.us/my.php?image=thenaltcrk5.jpg
Understand? İn Second Picture I Use Character But I Dont Pull Back Camera.
07/26/2008 (2:12 pm)
yeah.. that's a little true :) İn Game.. i press alt+c and use something then press alt+c camera top-down view on the player near character ... StandPoint scale down :S look like in fps mode press then tab :S if you want SS thats Here>
Normal:http://img371.imageshack.us/my.php?image=normaljg7.jpg
Then:http://img92.imageshack.us/my.php?image=thenaltcrk5.jpg
Understand? İn Second Picture I Use Character But I Dont Pull Back Camera.
#11
07/29/2008 (11:38 am)
EhaB Can You Hear ME ? PlEase HELP :S
#12
Firstly, this is not Ehab's resource, this is mine (based on Ehab's resource but modified to be an RPG starter kit and NOT including any source code).
Secondly, if you are having troubles using Alt+C to switch cameras, then stop using it! Make your own camera in the game.cs file and write function to use it.
This is my code:
I am running this inside: function GameConnection::createPlayer(%this, %spawnPoint) which is in the game.cs.
From now on, to change cameras, I use: $client.setCameraObject($cam1); and to go back: $client.setCameraObject($player);.
If you want to be able to move the camera, you also need:
$client.setControlObject($cam1);
This will prevent weirdness when using Alt+C. Remember, Alt+C is bound to a function relating to camera controls BEFORE applying the advanced camera resource. Since this kit uses the advanced camera resource, the above method will work perfectly for you and can be bound to a key on the keyboard or joystick.
@Chris:
I think you are wanting something much different than what this resource has to offer. If you use Ehab's resource (link at the top of this page), you can combine it with the following resource, but I don't know how well they will work together: www.garagegames.com/index.php?sec=mg&mod=resource&page=view&qid=5474
That resource will give you "player movement with a separate camera" which seems like what you want.
07/29/2008 (2:54 pm)
@Oguzcan:Firstly, this is not Ehab's resource, this is mine (based on Ehab's resource but modified to be an RPG starter kit and NOT including any source code).
Secondly, if you are having troubles using Alt+C to switch cameras, then stop using it! Make your own camera in the game.cs file and write function to use it.
This is my code:
// Create a new camera object.
if(!isObject($cam1))
{
$cam1 = new Camera() {
dataBlock = Observer;
};
}
MissionCleanup.add( $cam1 );
%this.setCameraObject($cam1);
%this.setControlObject(%player);
$client = %this;
$player = %player;I am running this inside: function GameConnection::createPlayer(%this, %spawnPoint) which is in the game.cs.
From now on, to change cameras, I use: $client.setCameraObject($cam1); and to go back: $client.setCameraObject($player);.
If you want to be able to move the camera, you also need:
$client.setControlObject($cam1);
This will prevent weirdness when using Alt+C. Remember, Alt+C is bound to a function relating to camera controls BEFORE applying the advanced camera resource. Since this kit uses the advanced camera resource, the above method will work perfectly for you and can be bound to a key on the keyboard or joystick.
@Chris:
I think you are wanting something much different than what this resource has to offer. If you use Ehab's resource (link at the top of this page), you can combine it with the following resource, but I don't know how well they will work together: www.garagegames.com/index.php?sec=mg&mod=resource&page=view&qid=5474
That resource will give you "player movement with a separate camera" which seems like what you want.
#13
07/29/2008 (3:44 pm)
Yeah That's Right Ty Nicolai... I Want Ask Something I Make Rpg Style Game and I start use Your starter kit.and ı need something once of all Bot Move and Atack contraption... how can i use it in your starter pack i see botz.cs but i dont know how i work it because i start coding new... how can i do it? Please Help Me Ty.
#14
Hmm... I guess I am not understanding you correctly. I mean no offense, but it sounds like English is not your primary language. Is there any way you can either post in your primary language or use an online translator? This is the part that confuses me the most:
It sounds like you want to make a bot move and then attack maybe?
First of all, the bot must be an AIPlayer. Here is an example of one of mine:
After that, you can use the AI commands on it such as this:
And if 'turret1' is a valid AIPlayer, then it would run the think function. Again, here is an example:
07/29/2008 (6:33 pm)
@OguzcanHmm... I guess I am not understanding you correctly. I mean no offense, but it sounds like English is not your primary language. Is there any way you can either post in your primary language or use an online translator? This is the part that confuses me the most:
Quote:
...once of all Bot Move and Atack contraption...
It sounds like you want to make a bot move and then attack maybe?
First of all, the bot must be an AIPlayer. Here is an example of one of mine:
new AIPlayer(turret1) {
canSaveDynamicFields = "1";
Enabled = "1";
position = "61.0824 -47.4961 100.02";
rotation = "1 0 0 0";
scale = "1 1 1";
dataBlock = "turretObject";
mountVehicle = "1";
};After that, you can use the AI commands on it such as this:
turret1.think();
And if 'turret1' is a valid AIPlayer, then it would run the think function. Again, here is an example:
function AIPlayer::think( %bot )
{
//%bot.nextNode();
%dist = vectorDist( %bot.getTransform(), %bot.target.getTransform() );
echo("AI - Player is this far away from me: "@ %dist);
%range = 26;
%lookDist = 35;
if( %dist > %range && %dist < %lookDist)
{
%bot.moveToTarget();
}
if( %dist < %range )
{
%bot.shotCount++;
if(%bot.shotCount==2)
{
%bot.aim();
%bot.shot();
%bot.shotCount=0;
}
}
%bot.schedule( 500, think );
}
#15
>> http://www.garagegames.com/index.php?sec=mg&mod=resource&page=view&qid=3531
>> This information for RPG dialog but write for starter.fps am i use it in WoW Style RPG Starter Kit ?
07/30/2008 (7:04 am)
ty Nicolia i use and worked.i want ask something >> http://www.garagegames.com/index.php?sec=mg&mod=resource&page=view&qid=3531
>> This information for RPG dialog but write for starter.fps am i use it in WoW Style RPG Starter Kit ?
#16
07/30/2008 (2:19 pm)
I took a look at it briefly and I really don't know if that will have issues or not. I really don't see any reason for it not to work.
#17
07/30/2008 (2:21 pm)
nicolia ty for answer .. i try it yeah that's work but need some annex :) if it belong for users i make resources :)
#18
07/31/2008 (10:24 am)
Nicolai Again i :D i want ask question. how can i starter.fps damage system tranfser to Wow Style Rpg kit?
#19
$player.health = 500;
Then, whenever a projectile, enemy, spike trap, whatever, hits the player, simply:
%damagedObject.health-= %damage;
This way, with the projectile's onCollision, you can spawn pickups, destroy crates, etc. Here is some code from a prototype I am working on:
Sorry I can't help you get the 'real' Torque damage system working. You may want to start a new topic or find a different one related to health and damage.
07/31/2008 (12:42 pm)
To be completely honest, I have never used the Torque damage system. When I was introduced to the Torque engine, I only had TGE 1.4. We setup our own health system. Basically, everything you want to be able to die needs to have a health tag:$player.health = 500;
Then, whenever a projectile, enemy, spike trap, whatever, hits the player, simply:
%damagedObject.health-= %damage;
This way, with the projectile's onCollision, you can spawn pickups, destroy crates, etc. Here is some code from a prototype I am working on:
////////////////////////////////////// PROJECTILE ON COLLISION ////////////////////////////////
function GunProj::onCollision( %thisDB, %thisObj, %otherObj )
{
//%otherObj = object getting shot
if( %otherObj.health > 0)
{
%otherObj.health -= 10;
if(%otherObj.health <= 0 )
{
$itemSpawnPos = %otherObj.getPosition();
%otherObj.schedule( 50, delete ); //schedule this or else the game may crash
}
}
if( %otherObj.destructo && %thisObj.sourceObject==$player)
{
echo($player @" shot a destructo object");
//make explosion effect, sounds, and spawn pickups
if(%otherObj.money>0 && %otherObj.key==0)
{
spawnMoney(%otherObj.money, %otherObj.getTransform());
}
if(%otherObj.key)
{
makeKey(%otherObj.key,%otherObj.getTransform());
}
%otherObj.schedule( 50, delete );
}
}Sorry I can't help you get the 'real' Torque damage system working. You may want to start a new topic or find a different one related to health and damage.
#20
understand me?
Help Please.
08/02/2008 (2:29 am)
bro i need help you...because when i try new speciality for rpg starter kit it isn't working i dont know why :S but it's working starter.fps :S for this reason how can i starter.fps transform rpg starter kit only i want Camera & Selection...understand me?
Help Please.
Associate Britt Scott