Hack Forums
[C#] [Development] Game Framework / RPG Development - Printable Version

+- Hack Forums (https://hackforums.net)
+-- Forum: Tech (https://hackforums.net/forumdisplay.php?fid=444)
+--- Forum: Coding (https://hackforums.net/forumdisplay.php?fid=151)
+---- Forum: Software Development (https://hackforums.net/forumdisplay.php?fid=118)
+---- Thread: [C#] [Development] Game Framework / RPG Development (/showthread.php?tid=1773645)

Pages: Pages 1 2


[Development] Game Framework / RPG Development - Local Celeb - Sep 29, 2011

[img]http://i.minus.com/iHRApTSdW2bSO.png[/img]

^MsPaint

Lately I've had the urge to make a game. But a game needs a framework; so I'm working on a framework/Game at the same time. I'll have a video demonstrating the generation of enemies soon.

The game I'm making WILL be text based, but the framework will can be easily converted to graphical usage.

Framework Progress :
Enemy Class :
  • Elemental Classifications

  • Locational Generated Sub-titles

  • Generating Health

  • Generating Mana

  • Generating Names / Subtitles

  • Easily added / Edited Monster

  • Mini-Boss Generation (Bosses will have their own class)


Video of old class (I have made some updates) :




Player Class :
  • Checking if a Player Can level up

  • Exp to Level algorithm

  • Class bonuses

  • Damage



Game Progress :
  • Story-Line developed.

  • Classes

  • Sandbox and Story modes. Interchangable

  • Game settings (Difficulty)



Ideas / Need-to-be-Done :
  • Shops

  • Arena

  • Finish Framework

  • Boss classes

  • NPC's

  • Random dungeons

  • Quests

  • Anything else I think of.



Changelog :
September 29'th 2011 :
Started the project
Made a beta of the Enemy class
Started work on the player class
Leveling up

October 6'th 2011 :
Enemies done
Items done
Inventory done
Player done
Skill -> Strength Done
Shops done
Buffs done

Here's a few screenshots of the progress :
Spoiler (Click to View)

Download from here : http://code.google.com/p/yelnar-game-engine-rpg-framework/downloads/list
If you have any questions, comments, concerns or anything else; just post and I'll try my best ( tp X, X, or X)





* - scarfacekilla - Sep 29, 2011

so it will be a textbased game or are you going to use 2D/3D graphics? IF yes i would suggest the XNA framework.

For the A / An you can improve the logic and check the "enemies" name for e,a,i,o,u and if it is you write AN otherwiese A

for examle (pseudo)
PHP Code

<?php 
List<char> aeiou = new List<char>{ 'a','e','i','o','u'}
string s1 = "Skeleton";
string s2 = "Elephant";
if(
aeiou.Contains(s1[0].ToLower()))
Console.Write("AN");
else
Console.Write("A"); 




* - Local Celeb - Sep 29, 2011

It will be a text based game. For now.


* - scarfacekilla - Sep 29, 2011

My bad, I did not read the whole post and scrolled down =) i re-read it :-D

are you using any kind of database to store information like available monsters and their stats etc.?

Then i would recommend (if it's should be easy) SQLite + FluentHibernate

I'm interested in helping / working with you...will it be open source?
Then you could upload it on GIT or SourceForge and we/people could work and help you, it would be cool if we can create some kind of MU online clone :)


* - Local Celeb - Sep 30, 2011

I havn't worked on the stats generation yet, but when It's implemented I'm going to have a class for base-stats based on the level; than a few other things.


* - Nonmod - Sep 30, 2011

Separate the engine from GUI.
So you can use the same engine for web,text,opengl,d3d etc.

It is a good practice.


* - Local Celeb - Sep 30, 2011

(Sep 30, 2011 03:21 AM)Nonmod Wrote:  Separate the engine from GUI.
So you can use the same engine for web,text,opengl,d3d etc.

It is a good practice.

The engine is seperated from GUI. Once I get some more work done I'll be making a repository so people can use it :)

The code I used to print the enemies was creating a new enemy with specific levels; than generating it's health, and name.



More updates. Just finished working on the weapons class, working on multiplayer now.


* - Eternal Darkness - Oct 1, 2011

Code
Public Class Form1
    Dim a As String 'Characters name
    Dim b As Char

    Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
  a = "A wild walka"
  MsgBox(Decisions(a))
    End Sub

    Public Function Decisions(ByVal k As String) As String
  b = k
  If b = "A" Or b = "E" Or b = "I" Or b = "O" Or b = "U" Then
    Return "An"
  Else
    Return "A"
  End If
    End Function
End Class

Simple a/an code...
Hope your game takes off...
I'd like to help you build, and learn from, this sometime bro. :3


* - Local Celeb - Oct 1, 2011

Okay :)
I'm finishing up some shop classes and such.


* - scarfacekilla - Oct 2, 2011

(Oct 1, 2011 07:39 AM)Eternal Darkness Wrote:  
Code
Public Class Form1
    Dim a As String 'Characters name
    Dim b As Char

    Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
  a = "A wild walka"
  MsgBox(Decisions(a))
    End Sub

    Public Function Decisions(ByVal k As String) As String
  b = k
  If b = "A" Or b = "E" Or b = "I" Or b = "O" Or b = "U" Then
    Return "An"
  Else
    Return "A"
  End If
    End Function
End Class

Simple a/an code...
Hope your game takes off...
I'd like to help you build, and learn from, this sometime bro. :3

first off all that's VB.NET but we are in the C# section!
secondly i posted already an example on which he can/should build on
and i am like 99% sure that your code even doesnt work...



* - Local Celeb - Oct 3, 2011

I finished off a small battle example with the classes.
I added a strength skill and bonuses
I added enemy damage and crits
I started working on magic and heals


* - Local Celeb - Oct 6, 2011

Updated with a load of pictures; Creating repository right now.


* - Eternal Darkness - Oct 6, 2011

(Oct 2, 2011 08:46 PM)scarfacekilla Wrote:  first off all that's VB.NET but we are in the C# section!

http://www.developerfusion.com/tools/convert/vb-to-csharp/
We both know about this. I am 100% sure... Plus we both know VB.Net...

(Oct 2, 2011 08:46 PM)scarfacekilla Wrote:  secondly i posted already an example on which he can/should build on

Gratz. :3 Trying to add to my post bro so I am not just another leech. Excuse me for posting a snippet...

Also, I totally (don't) have time to read through your posts before posting.

(Oct 2, 2011 08:46 PM)scarfacekilla Wrote:  and i am like 99% sure that your code even doesnt work...

Code should work... I posted the code after I did a quick test... :l


* - scarfacekilla - Oct 6, 2011

(Oct 6, 2011 06:04 PM)Eternal Darkness Wrote:  http://www.developerfusion.com/tools/convert/vb-to-csharp/
We both know about this. I am 100% sure... Plus we both know VB.Net...

Gratz. :3 Trying to add to my post bro so I am not just another leech. Excuse me for posting a snippet...

Also, I totally (don't) have time to read through your posts before posting.

Code should work... I posted the code after I did a quick test... :l

Ok then i have some questions - maybe VB .NET is handling this different to what i would expect and how C# is doing:

here you assign a string to a
Code
a = "A wild walka"

here you call a method with parameter a and you use the return value of the method for the messagebox
Code
MsgBox(Decisions(a))

here you assign b with k, which is "A wild walka" (local copy of the parameter)
Code
Public Function Decisions(ByVal k As String) As String
  b = k //local copy of the full string ?!

i dont know if the compiler handles = in if statements as == (equals) operator and not as ASSIGN = ... lets pretend it does a comparison
you test for "A wild walka"="A" OR "A wild walka"="E" .. etc
which is wrong... you want to check the enemies name...and therefore the first character of its name... like b="ape" ... b[0]=="a" OR... etc..
or am i wrong and the VB.NET compiler is that smart and does it automatically?!
Code
If b = "A" Or b = "E" Or b = "I" Or b = "O" Or b = "U" Then




* - Local Celeb - Oct 6, 2011

Code
public String AOrAn(String Text)
  {
    String[] Aeiou = new String[] {"a","e","i","o","u" };
    foreach (String S in Aeiou)
    {
    if (Text.ToLower().StartsWith(S))
    {
    return "An " + Text;
    }
    }
    return "A " + Text;
  }