Java-Gaming.org Hi !
Featured games (84)
games approved by the League of Dukes
Games in Showcase (604)
Games in Android Showcase (171)
games submitted by our members
Games in WIP (653)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
   Home   Help   Search   Login   Register   
  Show Posts
Pages: [1] 2 3 4
1  Games Center / WIP games, tools & toy projects / Re: Pezna Story Engine - A tool for creating non-linear, complex stories for games. on: 2015-07-04 12:44:01
Your event should not just have a name (variablename) but also parameters, that way you could (for example) notify the game of choices made inside the the questions, to hand out items or stuff. WDYT?

syntax could be as simple as:
1  
event varname param1 param2 param3


That's a good idea. I'll put it on my list of things to do.
2  Games Center / WIP games, tools & toy projects / Re: Pezna Story Engine - A tool for creating non-linear, complex stories for games. on: 2015-07-03 23:24:38
Update 2 - (Website blog post)

Events

This is something I've been putting on the back burner for a while, but today I decided I would finally implement this into PSE. You can use events to alert your game if an important action needs to occur. For example, if you want a transition after a line is displayed, you could do something like this:

1  
2  
3  
4  
5  
line: person "Hello, World!"
event "transition 1"
# or, if a variable (string, number, boolean) has been initialized
# you can send its value with the event
event variableName


While-loops

The problem  I had in the previous update with a stack overflow error has been fixed with the introduction of while-loops.

1  
2  
3  
4  
5  
line: person "I will count to 10!"
while (var <= 10):
    var += 1
    line: person var+"!"
end while



Using events and a while-loop in PSE.

What are your thoughts?

Be sure to follow me on twitter: @pezna_official
3  Games Center / WIP games, tools & toy projects / Re: Pezna Story Engine - A tool for creating non-linear, complex stories for games. on: 2015-07-03 04:40:48
Update 1 - (Website blog post)

Stack Overflow Error in Loops

Currently, in PSE, there are no while-loops. To imitate a while loop, you would need to use an if-statement with goto and label statements. For example:
1  
2  
3  
4  
5  
label start
if (num < 50):
    num += 1
    goto start
end if

I thought that something like this would be sufficient for everyone's needs, but while running some tests yesterday I discovered a problem with this code:



After creating and exporting a story, you load the story file into your game using a runtime library. It reads the exported file, and let's you navigate through the story. Because of the way I created the Java library, with recursive function calls, a stack overflow error was produced after about 2000 loops. This was because it never had a chance to "return". I then replaced the recursive function calls with a loop, but a stack overflow error now occurred after about 4000 loops. This happens because of the way "goto" statements are implemented. Explaining everything in text is going to be difficult, so I'll just leave it at that.

To solve this problem, I'm going to have to create while-loops in PSE, so that users do not have to use gotos to make loops. I'll still look for a way to solve the problem with if-statement loops, but if there is no practical solution, I'll simply discourage people from making loops with ifs, labels, and gotos (at least, loops with over 4000 iterations).

New GUI

I've worked on the GUI a lot in the last 2 days. When compiling and running a story within PSE, a new window would appear with the Run Console. Not anymore. Now, the Run Console is below the text editor.


The current look of PSE's GUI.

The panel on the left is the variable panel. It shows all the variables within the game, and their history (what values they previously held).

The panel to the right of the text editor will be the auto-generated flowchart that will help you visualize the flow of your story.
4  Games Center / WIP games, tools & toy projects / Re: Pezna Story Engine - A tool for creating non-linear, complex stories for games. on: 2015-07-02 04:43:23
This is kinda neat. Will the entire story be in one file?

The entire exported story will be in one file.
But during development of the story, you will be able to split it apart into stub files. This will also enabled more than one person to work on different parts of the story at the same time.

How exactly is this supposed to work? It sounds like a perfect fit for a visual novel engine, but how would I (theoretically) integrate it into one?

How would you integrate it into a visual novel engine? or a game?
Either way, it will be the exact same way: with events.

1  
2  
3  
4  
5  
6  
7  
8  
# create an event variable
event show_image "default value"

#later on, trigger event
trigger show_image

# or
trigger show_image "new value"


Events are not yet available in PSE, but will be available when the demo is released.
PSE is simply designed as an engine to create the text and flow of a story. After it is exported to a JSON file, and imported into your game with the use of a runtime, you will use listeners to be alerted when an event occurs. You'll create code to navigate through the story.

A basic story implemented in a game could be as simple as:
1  
2  
3  
while (story.advance()) {
   showLine(story.getCurrentLine()); //showLine will display the line and any choices it has, it will send the selected choice back to the story.
}
5  Games Center / WIP games, tools & toy projects / Re: Pezna Story Engine - A tool for creating non-linear, complex stories for games. on: 2015-07-01 04:46:37
I guess h meant dynamic like "don't need to be previously defined for a scope", what you describe is type inference on assignment Smiley

Oh, right. The variables will be dynamic. Currently, all variables are global variables. I'm planning on creating local variables for act and scene blocks in the future.
6  Games Center / WIP games, tools & toy projects / Re: Pezna Story Engine - A tool for creating non-linear, complex stories for games. on: 2015-06-30 17:05:39
Are the variables you can set on a character dynamic? Or are you limited to a subset specified by you? Nice work, however.
No, the character variables are not dynamic. Their type is determined by the initial value set to it.
If you give a character the property name="James", you can't later set it to a number, like name=15.
Currently, there are only 4 variable types: integer, string, boolean, and character. I'm going to add a float type later on.

Very nice tool, I like the script language but how do you expect people to use it? Is there a runtime to integrate into your own game? Smiley

Yes, there will be runtimes to integrate the exported file into your game. I'm working on the Java and Python runtimes concurrently with PSE.
The thing is that I'll need volunteers to port the Java and Python runtimes to other languages. I'll get over that hurdle after I implement all the necessary features.
7  Discussions / General Discussions / Re: What projects are you guys working on? How's progress going? on: 2015-06-30 06:33:51
I'm working on Pezna Story Engine.
I'm making great progress on it. The hardest part is done. I'd say it's about 50% complete.
8  Games Center / WIP games, tools & toy projects / Pezna Story Engine - A tool for creating non-linear, complex stories for games. on: 2015-06-29 18:07:15

A PSE story called "The Concise Tragedy of Romeo and Juliet

When creating a game with a story, creating and implementing the dialogue into the game can be very tedious. This was a problem I faced when I wanted to make a game with branching dialogues that could alter the course of the story depending on the player's choices.

I searched for tools that could do what I needed, but they always fell into these categories:
  • Crappy - Did not have as many features as I needed.
  • Overkill- Was too expensive and had many features, but not the features I needed.
  • Tedious- Repetitive dragging and dropping and clicking, constantly moving the mouse to click buttons and menus, etc.

There was no program that fell into just one category; each met at least two categories. The only reasonable thing to do was to build my own. Thus, Pezna Story Engine was born.


A portion of a story file that was used to rigorously test PSE.

I needed a program that would let me create characters, variables, choices for the player, and dialogue branching. I needed the program to be like a text editor that I could simply start writing in, and not have to painstakingly drag, and drop, and click, and arrange. In some of the programs that I found, by the time you finish clicking, dragging, and arranging, you've forgotten important details about the story you want to write. If your mind is anything like mine, you can get a dozen different ideas a day, and when trying to flesh out an idea, a bad user experience is not ideal. For the amount of flexibility and customisability that I needed, I had to create my own scripting language.

That is essentially what Pezna Story Engine is, a tool that interprets a simple scripting language designed for creating non-linear, complex stories for games.

Created with non-programmers in mind, it is extremely straightforward and easy to learn.

For the list of current and planned features, please visit the features page. PSE is still under development, and has not been released yet because there are many features that still need to be added.

I will talk more on the syntax and structure of a story file in later blog posts. Hopefully, I'll be able to release a demo within a month. Please follow me on twitter @pezna_official

Click to Play

Typing out an example story.

Click to Play

Test running the example story within PSE.

Website: http://pezna.com
Twitter: http://twitter.com/pezna_official
9  Games Center / WIP games, tools & toy projects / Re: College Saga // BETA on: 2015-01-24 05:48:27
Downloaded the game on Android.

In the mini-games, I feel like there should be an option to retry, instead of going back to the university area and tapping the icon again.

I haven't gotten far, but I like it so far.
10  Games Center / Android Showcase / Re: RolleR on: 2014-12-30 19:32:51
Downloaded and played, but I honestly prefer your previous game: Blocus (which I still have and play regularly).
11  Games Center / Showcase / Re: Do Not Connect on: 2014-11-29 07:41:32
I've seen too much shit like this be non-sarcastic to get it Smiley, if its just sarcasm I would still recommend you remove it , and in that case the game looks nice, i just feel like there should be something other than clouds in the top part of the screen, maybe try putting that score bar at the top and sprinkle clouds around the screen.

Do you mean on the main menu screen, or in-game? Depending on the size of the size of the device's screen, the score and pause button are at the very top. But I see what you're saying. Most games have the score at the very top all the time.

Also, the tree in the background changes each time you play the game, and if you play for long enough, it starts to snow.
12  Games Center / Showcase / Re: Do Not Connect on: 2014-11-29 07:30:27
My advice to you, take off the 10k dollar thing.

It was meant to be a joke, but I guess sarcasm doesn't come across well through text.
13  Games Center / Showcase / Do Not Connect on: 2014-11-29 07:08:57
Do Not Connect is the opposite of the popular game by Hasbro, "Connect Four"
(also known as "Four in a Row/Line").

The longer the game goes without connecting four, the higher your score.

If you or the computer connects four, your score reduces.

Fill up the board to win points and unlock new chips to play the game with.

Android: https://play.google.com/store/apps/details?id=com.pezna.donotconnect

Twitter: @pezna_official
Website: http://pezna.com/donotconnect

14  Games Center / Showcase / Re: Kingdom of Heaven on: 2014-09-21 05:09:18
Downloaded it because I liked the images you posted, but it turned out that the game doesn't have assets for larger screen devices and everything is blurry.

There are no instructions, but figuring out what to do wasn't too hard, since all you do is press your finger on the screen.

Frankly, it's a bit too boring for me.
15  Games Center / Showcase / Re: Need for Speed Childhood Edition on: 2014-09-21 04:52:48
Downloaded it and played for a bit.
The difficulty was a bit too high for me (the space between cars wasn't large enough for me to adequately time taps).
16  Games Center / WIP games, tools & toy projects / Re: Art To Map - Create Game Maps from Artwork on: 2014-08-18 22:39:49
Looks interesting. I was researching level editors that were non-tile based but didn't find any I liked. This however... this looks nice.
How exactly does it export the map? Would it just be like a text or xml file I would read into my game? And if so, how would the collision boxes/shapes/changes made in the editor be represented in the exported file?

Thanks for having an interest in this.
The locations of all the data points are saved in a file.
17  Games Center / WIP games, tools & toy projects / Re: Art To Map - Create Game Maps from Artwork on: 2014-08-13 14:21:51
Looks nice but still very basic. Is the background just an image and you added the collision boxes, or is the background also composed out of multiple parts?  And is this java2d?
Also I work with tiled but I don't assign properties to tiles. You can have object layers in tiled and draw tile objects freely or add shapes like rectangles or ellipses. I build my graphics with the tiles, but for example  the collision box of my level is simply defined with shapes. Maybe it would help you to have an in depth look at what is possible with tiled and other editors, so you can see what concepts work for you and what don't.

Some things i'd find nice to have in such a level editor:
- mirror sprites
- rotate sprites (smooth rotation and snapped to 45° increments)
- scaling
- tinting of sprites (incl. Alpha value)
- grouping/ungrouping of objects. So you can move or transform a group by only changing one of the grouped objects...
- create shape with outline. Use an image outline to create a shape...

I'd be interested in trying your tool out, but it would require a runtime which works with libgdx, android and  gwt, otherwise I don't find much use for it (don't have the time or the nerves to build another renderer XD). Keep up the work.

It is Java2D.
The background is an image I added to the map editor, and I added collision boxes.

This tool is really for people who don't wish to make maps that have a "tile" feel. If you want to have complicated and intricate artwork in a game, you can paint the entire map in an image editor, and then export it as a PNG. Load it into this program, and use the various tools to outline collision boxes.

I'll include all those features, and I'm definitely going to create runtimes for LibGDX, and Java.
18  Games Center / WIP games, tools & toy projects / Art To Map - Create Game Maps from Artwork on: 2014-08-12 17:54:14
Art To Map is a tool that I am creating to give game developers a new way of creating maps for 2D games.

The typical way of making maps for 2D games is to divide the game world into tiles and assign a "property" to the different tile objects. Art To Map changes things by relying purely on geometry. You are free to use any image you want to create a map, and not have to divide it into tiles.


Image used is from http://opengameart.org/content/simple-nes-like-village-tiles

Using different tools, you can turn complex artwork into a game map.



Current Tools:
  • Select Tool
  • Line Tool
  • Ellipse Tool
  • Rectangle Tool
  • Polygon Tool
  • Bezier Tool

Using this program you could turn something like THIS into a map for your game.

Features:
  • Tools: Select, Line, Ellipse, Rectangle, Polygon, Bezier, Rotate and Scale
  • Organize shapes and images into layers (with each layer having a different color)
  • Multiple projects open in different tabs
  • Save and Load projects
  • Add images to project
  • Mirror and Rotate images
  • Tinting and Transparency of images
  • Grouping/Ungrouping of objects. So you can move or transform a group by only changing one of the grouped objects.
  • Create shape with outline. Use an image outline to create a shape
  • Zoom
  • Export projects into JSON (and/or XML)
  • Improve UI and graphics
  • Undo, Redo, Delete shapes
  • Create libraries in different languages, so that the exported file can be used in games.

More features to come. Make some requests and I'll see if I can implement them.

What do you think of this? Would you use it?
I'm thinking of making it opensource when I'm done, but I do need to make some money. Perhaps a kickstarter to make it open source?
19  Games Center / WIP games, tools & toy projects / Re: Jumproom on: 2014-08-02 15:47:04
This game is very cool. I had it on my Galaxy S2 and had no problem, but on my new S4 sometimes some problem occur.
If I'm playing the game, and I need to go to my home screen, I press the home button and my phone freezes. I have to restart my entire phone. That never happened on my S2.

Also, there are a few bugs in this game. One of them is as such: When the mushroom hits the laser and dies, a group of lasers pop up and fall off the screen repeatedly, and the game doesn't give me an option to restart.

Look by the timer
http://i.imgur.com/teHmIE3.png
http://i.imgur.com/XSaRG5u.png
20  Games Center / Showcase / Re: Astronaut - a light puzzle game with a powerful twist on: 2014-06-30 19:07:07
Very very very good game. I absolutely loved it. Kept me entranced from beginning to end.
21  Discussions / Miscellaneous Topics / Re: The Game That Time Forgot on: 2014-06-22 22:39:49
Yeah, I just saw that video from browsing #gamedev and #screenshotsaturday on twitter.
22  Games Center / WIP games, tools & toy projects / Re: [Android] [LibGDX] Pulse Orb on: 2014-06-22 03:35:12
I've been working on it nonstop since the thread was created.

//UPDATE
-Created duplicate assets at different sizes for different android screen sizes
-Implemented Advertisements

//TO DO
-Implement twitter sharing from the app
-Marketing
23  Games Center / WIP games, tools & toy projects / [Android] [LibGDX] Pulse Orb on: 2014-06-15 17:01:23
@pezna_official

Pulse Orb is a simple and fun Android game that requires logic.

Your goal is to use the red "Pulsorbs" to direct the green and white ball (called "Ball") to the finish.

Each unique level, with infinite ways to solve them, presents a different challenge that will keep players of all ages engaged.



Click to Play



General Idea
You are to direct "Ball" to the purple finish orb using pulsorbs, collecting all necessary keys along the way.

There is a "pro" score in the pictures, and that tells you how many pulsorbs that a professional (at playing the game) can beat the level using.

There are many obstacles that you must avoid or use to your advantage.



I've been developing this game for about 2 years, and I've restarted 3 times in pursuit of good design.

More details to come in the near future. Any questions are welcome.
Follow @pezna_official on twitter
24  Game Development / Newbie & Debugging Questions / Re: [Solved] [LibGDX] Shader problem is beginning to piss me off on: 2014-06-11 16:39:09
I believe this can be "fixed" (as in the issue is ignored like before) if you set
ShaderProgram.pedantic = false;
before creating a ShaderProgram.

If I could kiss you right now I would, you magnificent bastard.
That's why it was working in my previous project but not in the current one.
25  Game Development / Newbie & Debugging Questions / Re: [LibGDX] Shader problem is beginning to piss me off on: 2014-06-11 13:17:23
Okay, I've solved this issue.

Like I said, for some reason that exact shader code worked in a previous version of LibGDX, but wouldn't work the new one.

What I did:
I set the sampler2D to "u_texture"
1  
uniform sampler2D u_texture;


AND I also had to use the "color" variable so that it wouldn't get optimized out. So, my current fragment shader looks like this:

1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
12  
13  
14  
15  
16  
17  
18  
19  
20  
21  
#ifdef GL_ES
precision mediump float;
#endif

uniform sampler2D u_texture;
uniform vec2 u_resolution;

varying vec4 v_color;
varying vec2 v_texCoord0;

const vec4 glowColor = vec4(1, 1, 1, 1);

void main()
{
   vec4 color = texture2D(u_texture, v_texCoord0) * v_color;
   vec2 fragPos = gl_FragCoord.xy / u_resolution.xy; //will give range in [0-1, 0-1]
   float dist = distance(fragPos, vec2(0.5, 0.5)); //distance to the center of the screen
   
   color = mix(color, glowColor, dist);
   gl_FragColor = color;
}


It's very irritating how it works in previous LibGDX versions but not in the new one.
26  Game Development / Newbie & Debugging Questions / Re: [LibGDX] Shader problem is beginning to piss me off on: 2014-06-11 12:49:17
You're not actually using u_sampler2D even in the original shader, as you're not using "color", so the whole uniform is optimised away.

Cas Smiley

That's not the problem. I switched it to this and it still gave me that stupid error:
1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
12  
13  
14  
15  
16  
17  
18  
#ifdef GL_ES
precision mediump float;
#endif

uniform sampler2D u_sampler2D;
uniform vec2 u_resolution;

varying vec4 v_color;
varying vec2 v_texCoord0;

void main()
{
   vec4 color = texture2D(u_sampler2D, v_texCoord0) * v_color;
   vec2 fragPos = gl_FragCoord.xy / u_resolution.xy; //will give range in [0-1, 0-1]
   float dist = distance(fragPos, vec2(0.5, 0.5)); //distance to the center of the screen
   
   gl_FragColor = color * vec4(fragPos, 0, 1);
}


Also, like I said, I used the exact same shader code in another project and it worked. So, even in that one, the color wasn't being used, but it still worked without errors.
27  Game Development / Newbie & Debugging Questions / Re: [LibGDX] Shader problem is beginning to piss me off on: 2014-06-11 12:39:07
Um yeah you need to actually have that uniform in the shader, which you don't. Of course it will throw the error if the uniform doesn't exist. Try renaming the Sampler2D uniform again and then post whatever error you have.

I said that I did rename the sampler2D to u_texture and it gave me the exact same error with the exact same stack trace.

Could it be because I created this new project with libgdx 1.1 instead of the nightly 0.9.9 that was used on the previous projects? This is absolutely absurd.
28  Game Development / Newbie & Debugging Questions / [Solved] [LibGDX] Shader problem is beginning to piss me off on: 2014-06-11 12:33:42
I've written and used shaders for libgdx in the past, but never run into this stupid f**king problem.

"no uniform with name 'u_texture' in shader"

1  
2  
3  
4  
Exception in thread "LWJGL Application" java.lang.IllegalArgumentException: no uniform with name 'u_texture' in shader
   at com.badlogic.gdx.graphics.glutils.ShaderProgram.fetchUniformLocation(ShaderProgram.java:293)
   at com.badlogic.gdx.graphics.glutils.ShaderProgram.fetchUniformLocation(ShaderProgram.java:283)
   at com.badlogic.gdx.graphics.glutils.ShaderProgram.setUniformi(ShaderProgram.java:307)


Here's my shader fragment program
1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
12  
13  
14  
15  
16  
17  
18  
#ifdef GL_ES
precision mediump float;
#endif

uniform sampler2D u_sampler2D;
uniform vec2 u_resolution;

varying vec4 v_color;
varying vec2 v_texCoord0;

void main()
{
   vec4 color = texture2D(u_sampler2D, v_texCoord0) * v_color;
   vec2 fragPos = gl_FragCoord.xy / u_resolution.xy; //will give range in [0-1, 0-1]
   float dist = distance(fragPos, vec2(0.5, 0.5)); //distance to the center of the screen
   
   gl_FragColor = vec4(0, 0, dist, 1);
}


I've tried for so long to get this shit to work. None of my other shaders have this f**king problem.

And here's the real kicker. I put my exact same shader code in a different libgdx project and it worked, but in this new project it keeps giving me this stupid f**king error.

I even tried setting the sampler2D's name to u_texture and that didn't work.
29  Discussions / General Discussions / Re: Replicating a stock market in game on: 2014-02-13 16:40:19
Yes, I feel like things like equity, assets, and liabilities would be too much for a game. I certainly wouldn't play a game that complex.

I think if you simply followed the law of supply and demand, it would be good at that.
30  Games Center / WIP games, tools & toy projects / Re: Pezna Story Engine on: 2014-02-09 23:35:28
Added some new features:
  • New command: alter variable values
  • Refined story syntax: choices can now conditions attached to them, determining whether they are shown or not
  • Variable values can be used in text by enclosing the variable names in percent signs. Eg: %var1%
Pages: [1] 2 3 4
 
SHC (25 views)
2015-08-01 03:58:20

Jesse (19 views)
2015-07-29 04:35:27

Riven (40 views)
2015-07-27 16:38:00

Riven (21 views)
2015-07-27 15:35:20

Riven (24 views)
2015-07-27 12:26:13

Riven (14 views)
2015-07-27 12:23:39

BurntPizza (36 views)
2015-07-25 00:14:37

BurntPizza (46 views)
2015-07-24 22:06:39

BurntPizza (30 views)
2015-07-24 06:06:53

NoxInc (36 views)
2015-07-22 22:16:53
List of Learning Resources
by gouessej
2015-07-09 11:29:36

How Do I Expand My Game?
by bashfrog
2015-06-14 11:34:43

List of Learning Resources
by PocketCrafter7
2015-05-31 05:37:30

Intersection Methods
by Roquen
2015-05-29 08:19:33

List of Learning Resources
by SilverTiger
2015-05-05 10:20:32

How to: JGO Wiki
by Mac70
2015-02-17 20:56:16

2D Dynamic Lighting
by ThePixelPony
2015-01-01 20:25:42

How do I start Java Game Development?
by gouessej
2014-12-27 19:41:21
java-gaming.org is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑gaming.org
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!