Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Discussion / DarkNOOBS Project 3: Adventure Game

Author
Message
Stefan p
16
Years of Service
User Offline
Joined: 2nd Nov 2008
Location: Online
Posted: 21st Mar 2009 00:56
Good job guys!_!
@ That1smartguy For some reason your text for the elments and others stuff are distorted(i can not read them with out guessing at letters. My screen size 640,480.)

All fears must be overcome before feeling true happieness.
By Stefan aka me
That1Smart Guy
16
Years of Service
User Offline
Joined: 26th Feb 2009
Location: Somewhere...... yep
Posted: 21st Mar 2009 01:08 Edited at: 21st Mar 2009 01:10
hmmmmm... i had that problem a while back but putting a cls in the loop fixed it 4 me, ill look into it

wat all is distorted, is it just the elements?
Stefan p
16
Years of Service
User Offline
Joined: 2nd Nov 2008
Location: Online
Posted: 21st Mar 2009 02:43
Yea and the weapon text. I think its the font, try another (i recomend arial)

All fears must be overcome before feeling true happieness.
By Stefan aka me
That1Smart Guy
16
Years of Service
User Offline
Joined: 26th Feb 2009
Location: Somewhere...... yep
Posted: 21st Mar 2009 02:56
kk, also im having some trouble simplifying my code, i added a function to check if the mouse is over the selected area (to remove those unsightly "pyramids" of ifs in my loop) but ive never used functions b4 so i made a mistake somewhere. this code SHOULD run the same as the one above, but as u will see he clicking functionality no longer works.

That1Smart Guy
16
Years of Service
User Offline
Joined: 26th Feb 2009
Location: Somewhere...... yep
Posted: 21st Mar 2009 03:24
nvm, i got it to work, im just gona do some more cosmetic work on the code then ill post my final HUD
Quirkyjim
16
Years of Service
User Offline
Joined: 18th Oct 2008
Location: At my computer
Posted: 21st Mar 2009 16:16
Make sure you add an ENDFUNCTION at the end of your function, even if you use EXITFUNCTION no matter what. It's just for the compiler's benefit.

~QJ
That's what they WANT you to think...
That1Smart Guy
16
Years of Service
User Offline
Joined: 26th Feb 2009
Location: Somewhere...... yep
Posted: 21st Mar 2009 19:24
ya i realized this.

im almost done with the HUD, should have it all ready by the end of the day, but im not guna improve graphics on it, so if someone else wants to work on that, just get the dimmensions from the get image commands
That1Smart Guy
16
Years of Service
User Offline
Joined: 26th Feb 2009
Location: Somewhere...... yep
Posted: 22nd Mar 2009 01:17
alrigh here it is, no real changes from my last post, xcept the function actually works

BN2 Productions
21
Years of Service
User Offline
Joined: 22nd Jan 2004
Location:
Posted: 22nd Mar 2009 06:59
Nice, SmartGuy. Can you put it all into a function that we can place in the final code (or an #included dba file) that will make it on a bitmap and then get the image for pasting in the game?

About the map maker guys, I will be finishing it tonight and just output everything I possibly can into a pak file and then I will write the appropriate code for it. Sorry for the absence, will try not to let it happen too much more.

Great Quote:
"Time...LINE??? Time isn't made out of lines...it is made out of circles. That is why clocks are round!" -Caboose
BN2 Productions
21
Years of Service
User Offline
Joined: 22nd Jan 2004
Location:
Posted: 22nd Mar 2009 11:58
Alright, got it all ready to go. There is still some serious work to be done (been having some trouble tracking a bug with the resize code that doesn't let you place tiles past a certain point, regardless of map size). Other than that, I am not exactly sure how I will be doing the scrolling for the map itself, and with the bug, for now, just zoom out to edit beyond the standard screen.

Great Quote:
"Time...LINE??? Time isn't made out of lines...it is made out of circles. That is why clocks are round!" -Caboose
That1Smart Guy
16
Years of Service
User Offline
Joined: 26th Feb 2009
Location: Somewhere...... yep
Posted: 22nd Mar 2009 14:07
i know ive been talking about this alot but do we have anyone, noob or otherwise, that is willing to do HUD graphics?
BN2 Productions
21
Years of Service
User Offline
Joined: 22nd Jan 2004
Location:
Posted: 23rd Mar 2009 07:48
Ashingda. You are on media dev. Do you have someone else helping you out? Take it or delegate. What is your workload like right now? I may be able to help you. I am not the greatest, but I can help. Just post a list of the pics you are working on and I will see what I can help with.

Great Quote:
"Time...LINE??? Time isn't made out of lines...it is made out of circles. That is why clocks are round!" -Caboose
Ashingda 27
17
Years of Service
User Offline
Joined: 15th Feb 2008
Location:
Posted: 23rd Mar 2009 17:44 Edited at: 23rd Mar 2009 18:20
Well someone was helping with the terrain tiles but no post from them.

I'm trying to work your editor, it's a bit more confusing than your earlier version.

I think it will help if you put all your system media into a separate folder.

[Edit]
I dont know how to load up the Layer2 Image, when I try it just loads up the Layer1 Image instead.


Collision and priority: Judging from the BN2's map editor the collision detection will be able to do example 1 but not able to do what's shown in example 2. That was my first intention but now I'm thinking if we are even ready for that kind of workload.

What do you guys think, should we attempt example 2 or leave it for furture projects?




[Edit]
Ohh btw BN2 we need more layers! At least 4 layers just for terrains [Ground] [Grass] [Water] [Object]
That1Smart Guy
16
Years of Service
User Offline
Joined: 26th Feb 2009
Location: Somewhere...... yep
Posted: 23rd Mar 2009 22:02
go for it!!!!!!
BN2 Productions
21
Years of Service
User Offline
Joined: 22nd Jan 2004
Location:
Posted: 23rd Mar 2009 22:36
Collision output not finished yet. It will NOT be tile based. I know what I am doing. The only thing that WILL be tile based is the first layer.

As far as using it goes, as previously posted, it requires 1 image, not two, that gets cut up into 2 layers. Just mix the two.

I stand by the fact that we DON'T NEED 4 layers. That will just make it cluttered and difficult to work with.

What is the difference between grass ground and water?. Nothing. They are all terrain. The problem you are most probably running into is trying to put fences on a waters edge. Yes it is a problem, but I don't think that adding more layers is the correct response.

The way it can be fixed is through a little ai in the editor. It would take a set of multiple tiles and use them to create the bodies in the map, so it would put appropriate edge tiles on the edges etc. I didn't want to do it at first, but I think it would be the best way to go. As I said, multiple layers won't only get a little confusing for us, but it could make the code a little more accident prone.

Here is an example that I made for the tile image that I made from putting two of yours together.

Great Quote:
"Time...LINE??? Time isn't made out of lines...it is made out of circles. That is why clocks are round!" -Caboose
Irojo
17
Years of Service
User Offline
Joined: 21st May 2008
Location: Eating toast.
Posted: 24th Mar 2009 04:44 Edited at: 24th Mar 2009 04:44
Those are superbly crystal clean graphics Ashingda.


Time is money. I just ripped you off.
BN2 Productions
21
Years of Service
User Offline
Joined: 22nd Jan 2004
Location:
Posted: 24th Mar 2009 05:36
As for collision. I had an idea, but now that I think of it, I need to know HOW our collision will be working. Tell me what you need generated and exported and I will code it into the compile button (the the papers slightly offset)

Great Quote:
"Time...LINE??? Time isn't made out of lines...it is made out of circles. That is why clocks are round!" -Caboose
Ashingda 27
17
Years of Service
User Offline
Joined: 15th Feb 2008
Location:
Posted: 24th Mar 2009 06:16 Edited at: 24th Mar 2009 06:17
I've already started working on a collision routine, we'll need an extra layer that works exatly like the first 2 layers to place the collision tiles onto. During the game the collision layer is not drawn at all but will be checked using memblock. There are 2 key colors with the collision, it's [Black] = Passable and [Red] Non-Passable.


I really cannot see 2 layers to be enough to make decent graphics. Example below:

Ex1. Already uses 2 Layers
Ex2. Has 3 Layers
Ex3. Needs 4 Layers
BN2 Productions
21
Years of Service
User Offline
Joined: 22nd Jan 2004
Location:
Posted: 24th Mar 2009 07:02 Edited at: 24th Mar 2009 07:03
I think 4 layers is excessive. We really won't NEED to put barrels behind fences. We could just as easily put them next to them.

What are the two layers in ex1 though? I only see grass.

For red, you mean rgb(255,0,0) right? or is it a shade of red?

Great Quote:
"Time...LINE??? Time isn't made out of lines...it is made out of circles. That is why clocks are round!" -Caboose
Ashingda 27
17
Years of Service
User Offline
Joined: 15th Feb 2008
Location:
Posted: 24th Mar 2009 11:52 Edited at: 24th Mar 2009 11:59
Well..



Yes it will be rgb(255,0,0). I picked red because it's just easier to see in the editor.

There's another problem that I completely forgot about, there's no wall Tiles, or should I say there's not enough space for those tiles on the 2nd layer tileset.
BN2 Productions
21
Years of Service
User Offline
Joined: 22nd Jan 2004
Location:
Posted: 25th Mar 2009 00:40
The space problem can be corrected with the auto-edge generation.

For that tile, what is the point of a ground and then grass on top of it? For creating graphics in programs like photoshop, then I can see the use. However, in a game like this, there is no real difference between ground and grass, and putting them on their separate layers is a bit overkill.

Remember also for the tilesets, we don't need everything to be in a single tileset. Just everything for a single map. Or would you rather us use a larger template?

Great Quote:
"Time...LINE??? Time isn't made out of lines...it is made out of circles. That is why clocks are round!" -Caboose
Ashingda 27
17
Years of Service
User Offline
Joined: 15th Feb 2008
Location:
Posted: 26th Mar 2009 02:07 Edited at: 26th Mar 2009 02:07
Well, I dont want to spend too much time to argue about this one subject, if I cant convince you with this last one then 2 Layers are fine with me.

Img1. Ground and Grass on different layers can be reused on different ground tiles.
Img2. With only 1 layer for Ground and Grass.
Img3. Example of 2 Layer effect with Ground and Grass.
Img4. You dont get this effect with 1 Layer.
Img5. Create new look with different Ground Tiles.




I know you can do Img3 effect with 1 layer but that would cause an excesive use of media. The point of using Tiles are to use and reuse the same images to create multiple outcomes.
That1Smart Guy
16
Years of Service
User Offline
Joined: 26th Feb 2009
Location: Somewhere...... yep
Posted: 26th Mar 2009 03:15 Edited at: 26th Mar 2009 03:17
i dont think i can implement the ENTIRE thing into a function, cuz those arrays for all the weapon info will need to be editted in-game, so i can do an function for it, but those arrays will have to be dimmed and re-dimmed in-game

also quick question, can u have a function be used inside another function, bcuz if i turn the program into a function itll have the mouseover function being used inside the new function
Caleb1994
16
Years of Service
User Offline
Joined: 10th Oct 2008
Location: The Internet you idiot!
Posted: 26th Mar 2009 04:51
arrays are global. you can use em anywhere once there dimmed

New Site! Check it out \/
BN2 Productions
21
Years of Service
User Offline
Joined: 22nd Jan 2004
Location:
Posted: 26th Mar 2009 07:23
Yes you can call a function call within a function. Don't put a function in a function though, it will just error.

@Ashingda
Ok, I see what you mean now, but adding another layer would result in a larger tileset. So lets get this down right now. How about this for the Layers:

1. Basic level terrain-contains ground or grass or whatever
2. Terrain "Decals" including angled pieces of grass (terrain, but it utilizes a black color for transparency). This would also include the waters edge decals.
3. Static objects (where walls, trees, and anything static there is that isn't ground)
4. Entities-self explanatory.

How does that sound?

Great Quote:
"Time...LINE??? Time isn't made out of lines...it is made out of circles. That is why clocks are round!" -Caboose
Ashingda 27
17
Years of Service
User Offline
Joined: 15th Feb 2008
Location:
Posted: 26th Mar 2009 07:42 Edited at: 26th Mar 2009 08:34
Sounds great, exept we need to add a:

5. Collision, contains the Red/Black key colors to prevent the player from passing walls/objects/water/etc.

As I've said befor, collision will not be drawn it's only for checking. I'll start working on a new Tileset for example first.

[EDIT]
Wait scratch the whole Collision Layer idea, I think I can create a Collision Key Image during MapLoading!

When the Map data is first loaded into the array I'll run through a routine where it will scan the Map for Objects/Walls/Water tiles and automaticly create a Collision Layer with the proper collision tiles.

This way the person creating the Map with the Editor dont have to get confused working with the Collision Tiles. (I made those tiles and I'm still confused with it at times )
BN2 Productions
21
Years of Service
User Offline
Joined: 22nd Jan 2004
Location:
Posted: 26th Mar 2009 08:03 Edited at: 26th Mar 2009 08:05
Collision won't be a layer, it will be generated afterwards.

Actually, the way I was thinking, though it may be iffy, is to use a memblock flood-fill style system, so that everything black in the second and third layers will be considered able to be collided with (unless the tile is set to non-collision).

For collision, lets say this: rgb(255,0,0) means collision on (can't walk on) and rgb(0,0,255) means can walk under. Of course, black means you can walk on it.

Great Quote:
"Time...LINE??? Time isn't made out of lines...it is made out of circles. That is why clocks are round!" -Caboose
Ashingda 27
17
Years of Service
User Offline
Joined: 15th Feb 2008
Location:
Posted: 26th Mar 2009 08:33 Edited at: 26th Mar 2009 09:12
I'm going to try to explain how I'm trying to work collision.

When checking for collision It will only check 1 pixel near the foot of the player. While checking the Collision Layer if the area the player will be moving into is RED then the player is stoped else if it's black then nothing happens.

Image shows which pixel it will be checking.



This example shows the Collision Layer overlaping the Object Layer. Only some of the Collision Tiles are pressent for this example. Alot of the Object Tiles re-uses the same Collision Tiles.




This example shows the Player's limitation moving Downwards.
1. The first one shows how it appears if you compare the Player to the Terrain Tile and Collisoin Tile. The Red Pointer on the Player can never move into the Red Collision Area.
2. The second shows how it would apear in-game.




This last one shows the Collision check and the outcome resaults.


@BN2
At first I had the same idea as you but there was a problem with tall and short objects for example a tree and a small table (example above) had different height but the player was supose to be able to walk behind them at the same Y coordinate.


As for Priority we can use my Paste Priority routine with QuickSort.
BN2 Productions
21
Years of Service
User Offline
Joined: 22nd Jan 2004
Location:
Posted: 26th Mar 2009 09:45 Edited at: 26th Mar 2009 09:47
Would the priority system work with what we need to have the character go behind some tiles? Remember, there could be some tiles we want to be exclusively overhead (such as some archways or something)

Great Quote:
"Time...LINE??? Time isn't made out of lines...it is made out of circles. That is why clocks are round!" -Caboose
Ashingda 27
17
Years of Service
User Offline
Joined: 15th Feb 2008
Location:
Posted: 26th Mar 2009 17:58
Yes it will work with those too, those TileTypes should be marked as last priority.
Libervurto
19
Years of Service
User Offline
Joined: 30th Jun 2006
Location: On Toast
Posted: 26th Mar 2009 19:03 Edited at: 26th Mar 2009 19:08
@Ashingda
have you considered having a depth value for all objects instead of a collision layer, that way you would just look at the object the player was colliding with (sprites) and check if it is deep enough to collide at that point or if the player is just behind the object. some simple maths would add the depth to the ypos of the object. You could also have a height for objects that are off the ground.

with regards to the tile graphics layers you dont need multiple layers to get a non-squared effect. All we need is some edging textures and a routine to check what terrain surrounds the tile and apply the appropriate edging to it.
i.e. if we had a grass tile next to a sea tile we could evaluate the grass and give it a beachy edge, and the sea tile a beachy or sea edge depending on what looks best.

@BN2
downloaded your map editor, looks good but is there any documentation i couldnt work out how to use it.

The Universe has been erased by a mod because it was larger
than 240x80 pixels.
Ashingda 27
17
Years of Service
User Offline
Joined: 15th Feb 2008
Location:
Posted: 26th Mar 2009 20:06 Edited at: 26th Mar 2009 20:08
@Obese
That's actually more complex than a collision layer. There are also more control when I can edit the collision visualy. I know this way works because I've already have a working example of this.

As for Sprites I think we can do without because Collision and Priority will be done with routines.


Zip contains the test.exe and preset map. Move around with the Arrow and Space to attack.
Ashingda 27
17
Years of Service
User Offline
Joined: 15th Feb 2008
Location:
Posted: 26th Mar 2009 22:05 Edited at: 26th Mar 2009 22:05
Here's the updated Tileset. I modified it to fit into BN2's Map Editor.
BN2 Productions
21
Years of Service
User Offline
Joined: 22nd Jan 2004
Location:
Posted: 26th Mar 2009 23:31
Here is how to use the map editor:

When you first start it, it will ask you to open a file. It means to select a tileset to use.

Once chosen your map will be displayed on the right, tiles on the left, and controls on the top bar.

Buttons from right to left:

Open (the file)-Currently means open a new tileset, though in the future it will probably be switched to opening an existing map

Save (the disk)-Currently does nothing, though in the future it will save the map in a format that is more convenient to work with than if it is compiled (included if that turns out to be the case, otherwise I will turn it into something else)

Compile (Papers overlapping each other)-Saves the Map as Map0# where # is the number of the lowest non-existing map in the directory.

Resize Map (the blue arrows)- Allows the map size to change. Currently there is a bug restricting tile placement, but I am working on that.

Terrain Layer (Green)-Sets the current drawing layer to terrain. This is where the grass, water, ground, etc will be stored and where the basic map is drawn (without trees or buildings or other scenic items)

Static Layer (Blue)-Sets the current drawing layer to Statics. This contains all static objects, such as trees, tables, and rocks, that will be placed. Also on this layer will be buildings and other man-made items.

Entity Layer (Yellow)-Sets the mode to Entity mode, where you can create "entities" (Moving, or otherwise acting, parts of the map). These contain anything from characters to teleports (causes the map to switch) to message systems (the dialogue box will be explained shortly).

Collision Set (Half black half white box)- Allows you to specify which tiles can be collided with and which can't. Recent changes to how we will be doing things will make this most probably a terrain layer only control, as statics may be controlled with other means.

Zoom Buttons (1/1 1/2 and 1/4): Controls the zoom of the map so that you can edit beyond the edge of the screen at full size (scroll bars to come)



Using the Map Editor:

Simply choose the layer you want to work in, then click on the tile you want from the left and click on the right to place it.

Entity Editor:
Use the SET button to choose a character set for the entity. Simply select the image and it will handle the rest.

The "On Key Press" Checkbox will allow you to specify if you want the entity to do its thing immediately or when you walk up and press enter by it.

Type will allow you to select from a drop down menu one of the following actions:

-Stand still: The entity will never move
-Move Towards: Will cause the entity to move towards the hero
-Move Away: Will cause the entity to move away from the hero
-Item: Gives an item to the player
-Teleport: Makes the entity a teleport, that is, it will trigger the hero to switch maps. If the "On Key Press" is not checked, it will switch when the hero steps on it.

The Value field contains health information (unless it is a teleport or item, which will be explained below)

The Amount field contains information about intesity. So an enemy would have their damage value put here. Healers would have how much health is healed.

Message is a field that holds the message that is displayed when the entity activates. (Unless it is a teleport in which case there is a special case)

NOTE ON TELEPORT AND ITEM TYPES:
Teleport
The Value field will contain the X value of the tile to be teleported to.
The Amount field will contain the Y value of the tile to be teleported to.
The Message field will contain the Map Number for the map to be teleported to.

Item
The Value field will contain the item number to be given to the hero
The Amount field will contain the amount of the item to give to the hero (self explaining). Use a negative number to remove it from the player.


Pretty sure that is all the info needed, let me know if I left something out.

Great Quote:
"Time...LINE??? Time isn't made out of lines...it is made out of circles. That is why clocks are round!" -Caboose
BN2 Productions
21
Years of Service
User Offline
Joined: 22nd Jan 2004
Location:
Posted: 26th Mar 2009 23:34
@Ashingda
I agree with obese, in that we don't really need a decals layer. I was trying to explain it earlier but I didn't do the greatest job. The edges could be AUTOMATICALLY added for us, rather than manually.

As for the collision system, Obese's system seems easier, and since the goal of these projects is to learn, using pre-made code would be counter-productive.

Great Quote:
"Time...LINE??? Time isn't made out of lines...it is made out of circles. That is why clocks are round!" -Caboose
Quirkyjim
16
Years of Service
User Offline
Joined: 18th Oct 2008
Location: At my computer
Posted: 26th Mar 2009 23:38
Could you re-post the most updated map editor?

~QJ
That's what they WANT you to think...
BN2 Productions
21
Years of Service
User Offline
Joined: 22nd Jan 2004
Location:
Posted: 26th Mar 2009 23:43
Here it is, along with source code and such. Sorry for the messy code (if you choose to use it, though the exe should be all you need). For anyone who REALLY wants to, if you could hep me track down this REALLY elusive bug in the resize system. For some reason, you can only place tiles up to 17 on the Y axis and 20 on the X axis. It doesn't matter how much you resize it, it still won't work. If you guys don't want to, I am sure I will find some stupid math problem somewhere where I forgot a negative or something.

Great Quote:
"Time...LINE??? Time isn't made out of lines...it is made out of circles. That is why clocks are round!" -Caboose
Ashingda 27
17
Years of Service
User Offline
Joined: 15th Feb 2008
Location:
Posted: 27th Mar 2009 00:18 Edited at: 27th Mar 2009 00:23
Quote: "using pre-made code would be counter-productive."

Well... those pre-made codes where made from scratch by me for these kind of projects, wouldn't that still count as being productive?

We can do an automatic edge check but have 2 questions:

1. When will the Edge Check be performed? MapLoad, while the Grass Tile being drawn, after the original Layer 1 is drawn, or some other time I haven't thought of?

2. Wouldn't an Edge Check be slower than just ploting a tile that was manualy done?


Hmm.. I dont think Obese actually mention a collision method. He was talking more about priority I believe. Correct me if I'm wrong.
BN2 Productions
21
Years of Service
User Offline
Joined: 22nd Jan 2004
Location:
Posted: 27th Mar 2009 00:45
Sorry ashingda, but while you still have some to learn, I don't know if you still qualify as a full fledged noob. There are others that I think could benefit from getting to work out a system on their own.

Edge check would be done in the editor and saved there with the actual tile data of the map (so it is a virtual layer at best), so there would be no extra work on the engine (whenever it is actually started)

If obese was talking priority, then I misread, I think it could be applied to collision as well. Used in conjunction with the floodfill idea from before:

Everything black is walkable (figured out with floodfill). Once the non-black area was found, collision would be determined in a footprint area (from bottom of collision area to 20 pixels up or whatever the footprint depth should be).

With some work this could be generated by the map editor program and saved, so that we don't have to do everything by hand.

Great Quote:
"Time...LINE??? Time isn't made out of lines...it is made out of circles. That is why clocks are round!" -Caboose
Ashingda 27
17
Years of Service
User Offline
Joined: 15th Feb 2008
Location:
Posted: 27th Mar 2009 01:17 Edited at: 27th Mar 2009 01:20
Quote: "Edge check would be done in the editor and saved there with the actual tile data of the map (so it is a virtual layer at best), so there would be no extra work on the engine (whenever it is actually started)"

Isn't that just the same as having it's own layer with it's edge data?

Quote: "I don't know if you still qualify as a full fledged noob"

I dont think that's a fair statement, I've never finnished any project until I joined this team, I'm learning everything as I go, everything I've done up til now are mostly a first time attempt.


Anyways I did some playtesting with the Editor, here it is if anyone cares.


There's no doors and window cause it's on Layer3 and the editor still only has 2 Layers for Terrain.
That1Smart Guy
16
Years of Service
User Offline
Joined: 26th Feb 2009
Location: Somewhere...... yep
Posted: 27th Mar 2009 01:28
we are working on a working edge effect right, cuz the waterline looks like.... well u get my point
BN2 Productions
21
Years of Service
User Offline
Joined: 22nd Jan 2004
Location:
Posted: 27th Mar 2009 01:30
Hmm that doesn't look bad.

The difference between the virtual layer and an ACTUAL layer is that the user doesn't do anything for the virtual layer (even then, though, it might be more than needed, it could just put it on layer 1).

For doors, how bout we use entities? That way the user could walk up and press a button to make it work. Then they only exist on the entity layer and we use a character set instead of a tile set for them.

Great Quote:
"Time...LINE??? Time isn't made out of lines...it is made out of circles. That is why clocks are round!" -Caboose
Ashingda 27
17
Years of Service
User Offline
Joined: 15th Feb 2008
Location:
Posted: 27th Mar 2009 01:56 Edited at: 27th Mar 2009 01:56
@That1Smart Guy
I think I have an idea of how to work the water edges out but it would require some Tile space.


@BN2
There is no way an Automatic Edge routine can work this kind of effect. Ohh well I'll give up, 2 Layers should work still.
That1Smart Guy
16
Years of Service
User Offline
Joined: 26th Feb 2009
Location: Somewhere...... yep
Posted: 27th Mar 2009 03:36 Edited at: 27th Mar 2009 03:39
alright heres the code for the HUD, assuming were going with the cheap graphics

note this isnt made to be run by itself, its been organized to be put into the final game and wont work in this form



with this system wenver u get a new weapon (or lose some for that matter) just re-dim the arrays, inc the numberofweapons variable and fill the arrays up with the new weapon info
Ashingda 27
17
Years of Service
User Offline
Joined: 15th Feb 2008
Location:
Posted: 27th Mar 2009 03:39 Edited at: 27th Mar 2009 03:42
LOL I love the title! Hey can you post a screenshot or make a working example just for viewing?
Libervurto
19
Years of Service
User Offline
Joined: 30th Jun 2006
Location: On Toast
Posted: 27th Mar 2009 04:09
When I was talking about depth for objects I was talking about collision, the objects' position on screen is enough for drawing priority. I dont want to force a new system on you but i can see the colour check method getting very slow in-game. I'll write a basic example of what I propose so you can make a better judgement.
How are you displaying objects on the map, If you are using sprites offsetting them so that they're positioned at their base is a good idea for priority coding.
My idea for edging was that each tile would have 5 images (centre and 4 sides), the sides would automatically be assigned depending on surrounding tiles. To save time in-game we could save this group of 5 as a single image for use in the game, then we could even have customising options in the editor to create those effects Ashingda likes, then save the images as one when the map is exported. Yes that is probably the best option, so I suppose writing the auto-edging routine is optional but convenient for the map editor.

The Universe has been erased by a mod because it was larger
than 240x80 pixels.
Urist McCoder
19
Years of Service
User Offline
Joined: 27th Sep 2005
Location: At the computer.
Posted: 27th Mar 2009 05:02
This is kinda off-topic for what everyone is talking about, but how did you make the character?
That1Smart Guy
16
Years of Service
User Offline
Joined: 26th Feb 2009
Location: Somewhere...... yep
Posted: 27th Mar 2009 05:11
its just a series of frames of the same character in different poses that get played similarly to a video for the effect of movement
BN2 Productions
21
Years of Service
User Offline
Joined: 22nd Jan 2004
Location:
Posted: 27th Mar 2009 06:31
Pretty sure ashingda made a 3d model and animated it, then took screen shots. Then you just alternate the frames (much like your avatar) to simulate motion.

For auto edge, it can get the right effects. Think about this:

Lets look at a 3x3 grid (no pics sorry, just text)

ooo
ooo
ooo

And lets say that we use this pattern for the tiles:

OXO
XXX
OXO

The auto edge would detect this and change it to:

/X\
XXX
\X/

More of bridging, rather than changing.

So for a bigger example:

XXOOOOOOXXOOOO
OXXOOOOXXOOOOO
OOXXOOXXOOOOOO
OOOXXXXOOOOOOO
OOOOXXOOOOOOOO

It would change to:

XX\OOOO/XX/OO
\XX\OO/XX/OOO
O\XX\/XX/OOOO
OO\XXXX/OOOOO
OOO\XX/OOOOOO


Make sense?

Great Quote:
"Time...LINE??? Time isn't made out of lines...it is made out of circles. That is why clocks are round!" -Caboose
Ashingda 27
17
Years of Service
User Offline
Joined: 15th Feb 2008
Location:
Posted: 27th Mar 2009 07:44 Edited at: 27th Mar 2009 08:01
Quote: "but how did you make the character? "

Yup just like BN2 said, just simply took snaps of my 3d character I made for this project. I used 3d Canvas that I got from TGC if you'd care to know.



I understand the Auto Edge very well and also see alot of it's limitations.

Image below, lets say you're able to create the example A but what if you wanted example B instead? How would the Auto Edge know which one you want? This is the same for C,D,E, and F as well, The grass tiles are all placed in the exact same area!



Quote: " but i can see the colour check method getting very slow in-game"

The Color Check only checks 1 pixel, It cannot slow down the game by that much. It's using memblock for checking and it's only checking 1 Collision Tile at a time. I though we were going to do Pixel Collision here, did this suddently change?

Login to post a reply

Server time is: 2025-08-08 20:37:45
Your offset time is: 2025-08-08 20:37:45