CP - Alien Breed Remake - 8

Community Forums/Showcase/CP - Alien Breed Remake - 8

Rob Farley(Posted 2004) [#1]



Download site

On-Line Todo list

Previous Threads:
Initial Idea thread: http://www.blitzbasic.com/Community/posts.php?topic=37615
Thread 1: http://www.blitzbasic.com/Community/posts.php?topic=37773
Thread 2: http://www.blitzbasic.com/Community/posts.php?topic=38098
Thread 3: http://www.blitzbasic.com/Community/posts.php?topic=38223
Thread 4: http://www.blitzbasic.com/Community/posts.php?topic=38400
Thread 5: http://www.blitzbasic.com/Community/posts.php?topic=38864
Thread 6: http://www.blitzbasic.com/Community/posts.php?topic=39203
Thread 7: http://www.blitzbasic.com/Community/posts.php?topic=39435


Rob Farley(Posted 2004) [#2]
Zips Updated:

SFX, GFX and Code all need to be re-downloaded.

I've done a bit of housekeeping to clear out old unused stuff, check out the history for all the details.

I've still got to do a lot of work in Aliens.bb so if anyone is touching that let me know.

Bugs:
- I've extended the map to the full width of the available area and collision doesn't work right over on the right hand side... Not sure why.
- I successfully got myself trapped inside a wall, no idea how.
- I've noticed is that you sometimes appear to pick up 2 keys instead of 1. I've no idea how that can possibly happen but it does seem to happen.

I've created 2 new alien graphics, these aren't in this upload as I've not done a class.txt file for them yet. One is a baby beast though.

The beast now shoots, and he's really nasty!

We need to come up with a difinitive todo list, no-one appears to be using the online one... please do!

We now all the way to thread number 8... well done guys, we're nearly there!


Mark Tiffany(Posted 2004) [#3]
Didn't get as much time over the weekend as I hoped to get on top of the object editor. And don't have that much time over the next few days. This week, I shall be mostly hacking editor.bb again, although in a fairly self-contained fashion.

I'll have a go at sticking stuff in the todo list tonight - I'll go back over the past few threads and add stuff in. If I have time, I may check out that 2 keys for the price of 1 bug - sounds weird!


Mark Tiffany(Posted 2004) [#4]
Rob, could you stick links to the old threads in the top post? I'm about to trawl them for TODO's, and it would be kinda handy for reference... ;-)


Mark Tiffany(Posted 2004) [#5]
I've trawled through threads 5, 6, and 7 looking for TODO's. There are a fair few! I've just dumped them in a text list for now (see codebox below if you're looking for something to help out with!). They need to be prioritised yet (and describe better!), but it's a start. I won't get a chance to put this in the proper todo until tomorrow at least.




Rob Farley(Posted 2004) [#6]
Priority 1-5, 5 being high:

(5) Animated tiles / Sound Emiiting Tiles: Funnily enough I was thinking about this earlier, if we added a layer to the map that deals with level sounds and animated graphics, this way we can do a simple distance check and trigger the sounds or start to draw the graphics (if visible) and likewise stop the sounds and stop drawing the graphics, maybe even load and unload them, although I'm not sure how much slowdown that would incur. This layer could be something you could look into as you're the map guru now!

(1) Mini-Game for intex. We've really got to work out what the intex system is for, I'm disliking the idea of picking up money and buying weapons/keys/health etc. It seems wrong to me. Regarding a mini game this is LOW priority!

(3) Spawn animation could be simply done with a particle, this may mean an addition to the particle system that after a particle life is spent it triggers a script. This can be done very easily by adding a script to the createparticle function, if it has a script it triggers it on death of particle, if it doesn't have one, it acts as it already does.

(1) Gun-specific gfx on player: Quite frankly I think it's more effort that it's worth, again, low priority. It's candy nothing more.

(2) Motion Detector: Again, I'm not sure if it's worth it, we'll have to decide if it works as a radar or just if there is motion infront of you? Is it a visible thing or just audio? etc etc. Discuss.

(1) Rooms to be 5x5: Over to you Mark, I think this is another nice to have on the editor along with the 'shapes'

(1) Player Glow on intex map: It does! I think!

(1) Game Modules: Low priority, I think once we've got the map data sorted - Objectives etc then we can look into this.

(1) Gun Recoil: Um... Throwing the player back? The screen shaking gives you the impression of this really well if we need more than this let me know and I'll look into it.

(1) Diagonal Corridors: Right... I like the idea of this, however, it would mean some serious thought, probably new types of collision block for the various angles, doable, how important is this to everyone? It would be nice I agree. I've put this at a (1) if we want this we can ramp up the priority.

(1) Load / Save game: This is in to a certain extent, I thought we were just going to have load / save at beginnings / ends of levels. If this is the case then again, it's wait until we've actually got the map data complete before we can even start knowing what to save or load.

(1) Game Stucture: See Load/Save game.

(1) Level Intros: See load/save game.

(1) Level self-destruct: Again this is just triggers, and objectives. Should be able to achieve this with level design.

(3) Puzzles / Scripting: Triggers! Yeah yeah!

(1) Optional 360 rotation: Quite frankly I think we're a bit beyond implementing this now without a major reshuffle, if people think it's a definate yes then I'll look into it.

(4) Aiming: Yeah, should probably put this in.

(2) half-height flag for barrels: Already worked around this apart from the grenades going through closed doors!

(1) Online Scoreboard : Low priority, lets get the rest in first!

(5) slowdown jitters & craziness: Um...

(5) improve drawmap(): How?

(1) flamethrower: Done!

(5) weapons with dual actions: Doing it!

(2) dropping stuff from inventory: Again, we'll have to see how we use the inventory, personally I don't think we should have so many items that this would be necessary. After all, this is a shootem up rather than an RPG.


Just to update you on what I've been doing, I've implemented turn speed to the alien class file, this means that you can set how fast they turn around, ie, big aliens don't turn as quickly, this also cuts down the big aliens break dancing somewhat!

Oh, items that should be able to be picked up, the bombs! I don't think these should be a weapon as such, just items that can be picked up and used, this way you don't end up with 100s of bombs going off... although that does look cool!


Mark Tiffany(Posted 2004) [#7]
I did warn you it was just a dump of ideas - most I agree are way down the priority list! A few comments:


(5) Animated tiles / Sound Emiiting Tiles: Funnily enough I was thinking about this earlier, if we added a layer to the map that deals with level sounds and animated graphics, this way we can do a simple distance check and trigger the sounds or start to draw the graphics (if visible) and likewise stop the sounds and stop drawing the graphics, maybe even load and unload them, although I'm not sure how much slowdown that would incur. This layer could be something you could look into as you're the map guru now!


Will do, after the objects and level objectives. I seem to keep saying that... ;-) Originally I thought this could be dealt with using scripts, for example an ondraw() trigger might have a script of playsoundcont(fan) or playsoundrand(5,scratch). Not quite so sure now, but will think about it.

(1) Mini-Game for intex. We've really got to work out what the intex system is for, I'm disliking the idea of picking up money and buying weapons/keys/health etc. It seems wrong to me. Regarding a mini game this is LOW priority!


Agree from our POV. But, it's something that anyone else out there who's paying any interest in the thread might want to contribute to. There are several things like this that *we* don't want to focus on, but would be easy for others to pick up and have a play with (just trying to encourage some more people to join the fray!)

(1) Player Glow on intex map: It does! I think!


Again, just did a dump - I thought it might already do this, but thought I'd double check once I'd got the lot!

(5) slowdown jitters & craziness: Um...
(5) improve drawmap(): How?


Whilst fiddling with drawmap I thought I could see a (non-trivial) means of speeding it up. Both of these are really a reminder for me. Tied to this, I also want to amend the level save to do some double checking that there aren't any redundant tiles that will never be shown (base tiles under block overlay tiles for example).

Will trawl threads 1-4 tonight for more. While we don't want (m)any more new suggestions, if anyone reading does have some comments to make, bugs to report, etc, now might be the time to speak up and get them logged & prioritised. Once we've done this exercise, that really should be it for feature requests...


Rob Farley(Posted 2004) [#8]
Agree from our POV. But, it's something that anyone else out there who's paying any interest in the thread might want to contribute to. There are several things like this that *we* don't want to focus on, but would be easy for others to pick up and have a play with (just trying to encourage some more people to join the fray!)
I agree which is why I said "We've really got to work out what the intex system is for" it's an open discussion. However, this CP appears to have lost the interest of the community!

Originally I thought this could be dealt with using scripts, for example an ondraw() trigger might have a script of playsoundcont(fan) or playsoundrand(5,scratch). Not quite so sure now, but will think about it.
I think it'll be difficult to do this with a script the continuous sounds have to be constantly monitered to make sure the volume and pan is correct, also it would mean scanning the surrounding area including off screen for these scripts. Likewise with animated graphics, you'd scan for scripts and the draw whilst on screen not when off screen. I think it'll be damn tricky to do as scripts.


Rob Farley(Posted 2004) [#9]
Actually thinking about it... Each sound and graphic would need a unique ID to keep track of it... maybe a script would be better... Need more thought!


Mark Tiffany(Posted 2004) [#10]
I'm thinking that the playsoundcont and playsoundrand script triggers are scanned for over the visible map area "plus a bit". Any new ones not seen before are added to a "playlist" (a type), and any on the playlist that are no longer in the scanned area get removed (although it may be neatest to remove them after a short period of them not being visible to avoid funny clipping when walking diagonally, etc). Once that's done, you work through the playlist and determine whether it's a continuous sound; if it is and isn't playing, make it play. If it's not, decide whether to play it again, either after a fixed period or after a random period between N and M seconds.

I suspect that your sound engine can handle a fair bit of that, but I haven't thought beyond the above at all (and even then, the above is largely off the top of my head!), or delved in the appropriate bits of code to know whether I'm talking crap or sense!

However, this CP appears to have lost the interest of the community!

Hopefully once we have something like a real game structure in place we can garner some more interest and pimp it some more - more standalone activities can be taken on by people new to it, e.g. designing levels; designing puzzles / scenarios within levels; creating art / tiles; creating mini games; all those neat bits that we'd love to do but need to get the core sorted first!


AndyBoy_UK(Posted 2004) [#11]
I havent lost interest, I think its a sterling piece of team work and its a great game to play, keep it going.

Oi the rest of you, give our boys some support would ya ! :)


Perturbatio(Posted 2004) [#12]
I have to admit, my recent silence in these threads is because I have no idea what I can contribute anymore, I'm a bit lost in the code (I'm by no means an expert programmer).


Rob Farley(Posted 2004) [#13]
It's got to be said Pert the code is a disaster area!

But assistance doesn't have to come in the form of code, there's graphics, sounds, ideas, etc all of these have equal value as far as I'm concerned. I try to add the word Discuss to anything that needs discussing, however, it only seems a couple of people join in said discussions.

This to anyone watching, this is not just about coding this is about sharing thoughts and ideas and making this a better game. Even if you think your idea is stupid, or way out there, express it. Ideas are never wrong, ideas can be shaped by others to be a solution. Never be afraid to express them.... I'm ranting aren't I... sorry.

But you get my point... If you think we're doing something wrong then say it... without input we're nothing.


Perturbatio(Posted 2004) [#14]
I just ran the latest code and found a couple of bugs:

1) the doors do not open if you move into them diagonally

2) whilst shooting at an alien and a face hugger (with my facing locked in position as diagonally left), I was no longer able to move left or up (it would play the animations but acted as though there was a collision zone there, this happened no matter how far down and right I moved to try and offset it.


Rob Farley(Posted 2004) [#15]
1) I know! I'll look into it

2) If the aliens are infront of you they will stop you moving in that direction... was that it?


Mark Tiffany(Posted 2004) [#16]
Also player / alien / grenade collisions when you're all up close look plain wrong. You get stuck, the alien gets stuck, the grenade goes vertically up and down (I know I mentioned this elsewhere already) - it just looks freaky! Don't know if it's related / the same problem?

As for the code - hopefully the editor tidy has helped clarify some areas of that, and makes it slightly easier to get your head around. However, I think we need to be a bit more conscientious about commenting - I know I'm not great at it - but if we don't then there's no chance of someone else understanding our code.

Right, I'm off to trawl threads 1-4 for any interesting TODO's...


Snader(Posted 2004) [#17]
Just back from my holiday Down Under. A lot has happened.. the game turns out great!


Matthew Smith(Posted 2004) [#18]
Sorry I haven't been contributing lately, been really busy with no real time to do anything.

At stated, the Intex system does not appear to have much use at this stage. I guess we can either take the road of keeping similar usage to AB (purchasing weapons, items, maps etc) or do something totally different and new?? Rob and Mark may have a better idea as to the direction of the game currently and what using may be gained from this area.

I'll check out the TODO list once I have some spare time...


Mark Tiffany(Posted 2004) [#19]
Rob and Mark may have a better idea as to the direction of the game currently and what using may be gained from this area.

I like the way the map is only available at intex points, and I think we could expand on this. For example you could have a security item that always exists somewhere in the level, that if you have it, you can see all aliens & spawn points on the map. This would be useful if we add bonuses for completely clearing a given level.

Another thing that I'd quite like to see is a basic 'email' type thing, I guess similar to that in Deus Ex. This could be used for developing story, and very occassionally for puzzles (I'm not too keen on having to check every last intex machine without knowing you have to check them).

I also wondered about a simulated hacking tool / os. e.g. a simulated directory structure and you can root around in there to find stuff. Again, not too keen on this from a gameplay point of view for similar reasons - this is a shooter, not an RPG - but could be a bit of fun - a mini-game in itself perhaps? Or how you gain access to mini-games?

The intex systems should also provide access to online info if we ever get that far: game updates can be called intex operating system updates, new game modules could be "advertised" as trips to exotic planets?

However, all of those really are nice to have features, so let's log 'em and get on!

Anyway, apologies, but I didn't get a chance to do much in the end tonight. Must . Try . Harder . ;-)


Rob Farley(Posted 2004) [#20]
The whole buying weapons and stuff from Intex systems I think is a little against what we're doing here. The game is now more realistic (if there's such a thing) as the original, moving in the direction of inventory etc. I like the idea of finding weapons stores and ammo rather than buying stuff as you need it.

Why would marines be sent in? To find money and spend it on more weapons... seems kinda silly to me. Maybe if they're bounty hunters instead, but again, they'd come armed to the teeth and not be assisted by intex terminals to that extent.

We need a list of ideas for intex terminals:
Intex terminals should have the radar service for sure.
Player stats
Level stats/objectives
Maybe have communications through the intex terminals to advance the plot? (email was suggested)
Yeah, hacking around it for the odd game of pong or something!?
I like the idea of adverts appearing on them, even if they do nothing, I think it would be in-keeping with the future... adverts everywhere!

But we need to concentrate on what this game is... it's a blast-a-thon... and this we need to keep in focus.

I'm working on a messenger service at the moment, this will be handy for ingame messages as well as debug info.


Perturbatio(Posted 2004) [#21]

2) If the aliens are infront of you they will stop you moving in that direction... was that it?


I killed them, and I still couldn't move up or left, perhaps it is something in the code that handles that but I couldn't tell you for sure. (I doubt it's easy to replicate).


Perturbatio(Posted 2004) [#22]
also, from a gameplay point of view, the weapons keys are not clear, it would probably be easier to move the controls onto the qwerty section of the keyboard, use wasd for movement and the number keys for the weapons (that way you can simply have the number for the weapon displayed in the corner of it's icon).


Snader(Posted 2004) [#23]
I think the mapfunction in the intexsystem would be nice, maybe even a radar function so you can plan (possibly) the best route in a level.

A self destruct mode with self ajustable timer.. to blast everything up just before you exit the level/ship.


Rob Farley(Posted 2004) [#24]
Pert, Player 2 uses WASD, I think there should just be 2 weapons keys anyway, weapon up and weapon down. That said, keyboard will be definable anyway so it's not really worth worrying about.

Snader, The intex systems do already have a radar service.


Mark Tiffany(Posted 2004) [#25]
keyboard will be definable anyway

Speaking of which, *that* is a needed TODO that should be self-contained enough for someone else to pick up?

As for intex systems, I did consider suggesting that objectives go in there, but I didn't think that made much sense. Objectives are something that you should be able to call up as a reminder at any time - they represent your long term memory. I'm also a little wary of having anything too player specific in the intex systems. If you are invading a base that's not yours, would you really be able to access your home email and personal stats?

As for credits and shop, maybe that should exist outside of the levels? If the game is to be presented as a world map with locations to visit (each location representing a start level), then you could conceivably put the shop function here. i.e. you get back to base and can then top up on ammo, kit, whatever before heading to the next location?


Rob Farley(Posted 2004) [#26]
The question is are the intex system base specific or is intex like an internet terminal where you can log on to your email, get news, download porn etc.

Yep Redefine keyboard should be on todo as well as gun up/down rather than individual keys for each gun.

Just a thought for the objectives maybe have an inventory item that you always have that is your pocket computer or something? Click on that in the inventory and you're away with any additional info we care to throw at the game? Of course having a pocket PC with you kinda does away with the intex terminals.


Caff(Posted 2004) [#27]
Looking really great, I bet the code is becoming fun :)

If you need assistance with specific music / sound fx / graphics I'd be happy to have a crack.


Rob Farley(Posted 2004) [#28]
I've just finished off the messenger service for displaying stuff on screen, looks very nice, sine smoothness as it rolls on and off... I'll probably do an update this evening... depends what's on tele really!


Mark Tiffany(Posted 2004) [#29]
I kind of like the PocketPC idea, this could record player stats too. You could also use this as a special device with other objects. For example to hack into a (non-intex) PC to download data?

I think intex should be, in effect, the intranet for a given location, providing access to internal email, radar, maps, etc. i.e. level specific stuff. The PocketPC is then your personal portal to the outside world, and stuff gets downloaded to it from intex (e.g. mini-games, email messages, files).

Telly tonight - Titchmarsh being annoying I think.


Perturbatio(Posted 2004) [#30]
some way to override the gun turrets would be a good thing.


Mark Tiffany(Posted 2004) [#31]
ooh, neat! And cameras. Or is that just pinching from Deus Ex?


Perturbatio(Posted 2004) [#32]
how exactly would cameras be implemented?


Mark Tiffany(Posted 2004) [#33]
When you're at an intex console, you can select a camera. This then lets you view a certain location.

In terms of how it would work, I suggest the camera points to a single tile on the map. If that tile is not already visible (i.e. you've not been there), vis it. Then show on screen that map location as per the game map draw routines. Just don't draw the player or HUD, and any key exits. So you'll see the room, anything in it, plus anything you know about the surrounding area. And, once you've viewed the area, that stays visible for you, helping you out when attacking a horde of aliens.


Rob Farley(Posted 2004) [#34]
Updatette:

Delta changes (650k)

Basically added turn speed to the alien class, updated the tile set a bit and therefore the map too. Also added the messenger system that I think is very cool, but hey, I would! Anyway, this shows up the picking up 2 things instead of one as I've messaged every time you pick something up. It's a bit weird the picking up 2 things instead of one bug...


Mark Tiffany(Posted 2004) [#35]
Just so you know, I've now trawled all the threads and have a list of ideas. How do you think we should hold this? Do we like the online todo list, or not? I'm not convinced the 3 priority levels it provides is enough (I like 4 : DO IT NOW!, Needed to make this a game, Want to have, Nice to have). Back to a simple text list? Anyone have a preference? I'll post them wherever tomorrow, although they're still largely a braindump and need some tidying up / explaining!


Rob Farley(Posted 2004) [#36]
I think a text list is by far the simplist way of dealing with it quite frankly!


Mark Tiffany(Posted 2004) [#37]
Yeah, I was coming to the same conclusion! I'll try to post a tarted up version tonight - I may copy the format used in the project plasma thread.


Mark Tiffany(Posted 2004) [#38]
.

todolist in progress!


Rob Farley(Posted 2004) [#39]
Not going to be able to spend a a lot of time on this over the next couple of days as my mum is visiting! I'll keep an eye on it though!


Mark Tiffany(Posted 2004) [#40]
Items with a * against them have further details in the engine documentation *here*.

ENGINE
2 keys for the price of 1
Doors do not open if you move into them diagonally
Killing an alien when up against them can be screwy?
Grenade anim needs to drop to the ground quickly if it hits something
Slowdown jitters & craziness
Animated tiles
Sound emitting tiles*
Improved Aiming*
gun selection to be up / down list, not specific to each
weapons with dual actions
Spawn animations*
Tile graphics*
Tile decals*
Game load / save game*
Destructible / Fixed number respawn points*
End Game tidy up*
Flamethrower - done?
configurable keys, etc (Space_guy offered some code in thread 1)
Motion detector - maybe in intex? Only accessed with a key / security code for the level?
Level self-destruct (and sfx from Rob's gf)
Improved HUD
Laser Tripwire
Health packs as inventory items*
PocketPC*
Intex - turret override*
Intex - cameras*
Animated opening / closing of doors
Elevators
Set piece on game start for 1UP / 2UP*
Gun recoil
Diagonal corridors
Mini-game(s) for Intex / PocketPC
Gun-specific graphic on player
Optional 360 degree rotational controls
Online score board / level timings? Update notifications?
Inventory - Drop*
Intex - email system*
Intex - adverts?
Joystick control
Device independent renderer (2D/3D)
NPC alien types? Conversations?
Moveable objects*
slopes and sticky areas that player falls, gets stuck in etc. (no instant death though!)
Alien acid blood*
Antony's map code from threads 0 & 1 never went anywhere...
player glow on intex map

EDITOR (& ENGINE)
Level definition file*
Level objectives*
Object / script editor*
Game structure*
Convert Rooms to Shapes* (see Rob's copy & Paste)
Half-height Flag*
Game modules (skin menus, etc.)
Level Compiler*
Tile Editor*

GAME IDEAS
Puzzles*
Levels to fit Mark's(?) story (thread 4/5?)
Fancy level intros (slideshow, music, text, movie?)
Faithful remake*

SCRIPTING
destroy(nearby|<Radius>)
opendoor(x,y) - switches to open doors
onplace() trigger*
givefullmap() - full level map as a pickup object.
re-closing doors (using switches)
setvar(varname,value)
checkvar(varname,value)
if(varname,value,truescript,falsscript)
showdocument(text)
showconv(text)
remove(nearby)

OTHER
Screenies in gallery
License statement (GNU GPL?)

ALREADY DONE? (haven't double checked!)
respawners to be count limited (total and on-screen)
Push scroll... Instead of the player being fixed in the middle of the screen the player walks around in the centre section of the screen and when he reaches a boundry will push the scrolling.
"createalien(x,y,hugger)" - creates a hugger at the objects x,y location
"createalien(px,py,hugger)" - creates a hugger at the players location (may be different to object)
"createalien(x-1,y+1)" - creates a hugger SW of the object (useful for creating a generic trap that creates 4 aliens around the trap)
"createalien(123,456,hugger) - creates a hugger at a very specific location on the map (useful for very specific scripted events)


Mark Tiffany(Posted 2004) [#41]
Just a bit to do then! Note that the order within the four categories is not intentional, just the way they fell!

Please shout up if there's anything missing, or you think is rated incorrectly. Basically Red stuff we should do be focusing on, yellow stuff we need to do before we can truly call it a game. Blue stuff we likely won't do, but they're cool ideas to keep. Green stuff would be neat...


Rob Farley(Posted 2004) [#42]
Mark, can you change the create alien hugger bit to have "hugger" as a string? This would make life much easier for the spawn alien as it then just looks in the "hugger" folder. As it stands it picks up the hugger constant (0 I think) then in the create alien bit converts the 0 to "hugger", seems a bit pointless! Also it means in the future more aliens can be added and it'll just work with no additional code.


Rob Farley(Posted 2004) [#43]
I've just drawn a space ship!




Rob Farley(Posted 2004) [#44]
I've been thinking about saving "shapes"

How about you just drag an area on the map (like when you create a room) and it saves that as a shape (all the layers) this way you can create prefabs in the editor as per usual, when you add a shape it just adds all of the layers on but doesn't affect anything that isn't set.

For example, with the space ships you could draw it on a 'nothing' background drag a window around it, save it as ship.shape then when you want to add ship it adds it to whereever the cursor is.

Make sense? Should be pretty easy too.


Rob Farley(Posted 2004) [#45]
Updated the editor to do what I was saying... very hacked in, but it works! Mark, you might want to tidy this up and put it in functions and includes and stuff!

[edit]Updated zips[/edit]

Just so you know, I've added in a couple of variables at the top and a bit after everything is drawn.

Hit tab to start the copy and tab again to stop the copy, hit Q to paste what you've copied, no save yet.

If you want to find the bits I've added search the code for the following:

; pick up variables (could be better!)

and

;******************** Pick up temp bit needs gui-ing up!

It's only a couple of lines of code, but it certainly makes life easier!


Rob Farley(Posted 2004) [#46]
And just finished a buggy:




Rob Farley(Posted 2004) [#47]
Zips updated

07-11-04 :
Rob:
- Adjusted map and script so the door open sound open on script rather than door, this way you only get the sound once rather than many layered.
- Updated editor to allow for basic copy / paste functions (use Tab to start/end copy and Q to paste)
- Added Scenary GFX and updated map
- Updated spawn alien to spawn by name rather than number



Mark Tiffany(Posted 2004) [#48]
Cool ship / buggy! Like the idea for shapes, haven't had a chance to do much, not even download the above (daughter has a chest infection, so have been in and out of doctor's etc the past couple of days. nothing serious though, just difficult!). Hope to get onto some of this later, although the wife is insistent on dragging me to fireworks (yawn).


Mark Tiffany(Posted 2004) [#49]
Okay, simple updates tonight, so I'm posting delta changes here. If you don't want to pull them in now, I can do this later in the week when I get to finalise some of the other editor stuff. However, these are useful tweaks, and fairly standalone, so should be easy enough to copy and paste!

I've made my improvement to drawmap() - by pre-determining the min / max tiles, I've removed almost 8,000 expression evaluations per draw-cycle.

Whilst doing this, I think I've also spotted and fixed the "bottom right of the map is screwy" problem.

In map.bb, replace gettile and puttile with the following:

And also in map.bb, replace drawmp with this:

In players.bb, in Player_updateall, remove the bit of the if blocks relating to x/y being <7552. This is not only wrong (map tiles 236, not 255) but also unecessary.

Right, now I'm going to update the todo list and go to bed. Hopefully I'll get some sleep tonight!


Rob Farley(Posted 2004) [#50]
Nice one Mark, I'll take a look at slipping this in tonight.


Rob Farley(Posted 2004) [#51]
Code.zip updated with Marks changes... and a couple of fixes myself.


Grisu(Posted 2004) [#52]
Nice changes!

Btw:
1. Will it be possible to play AB at higher resolutions as well or are you going to stick to 640*480?

2. For the editor.
a) I think up+down arrows for the tile selection should be on both sides
b) you could add: mousewheel for changing title view (arrow uo/down)

3. Why is the TODO List non-public?


Rob Farley(Posted 2004) [#53]
Grisu,
1) We're sticking to 640x480, I did have a go at putting it in a higher res so you see more on screen, but quite frankly it didn't feel right, the graphics looked too small, and you didn't get a feeling of "what's round the next corner" so much.

2a) Personally I just use PGup/down to change the tile, I rarely bother with the gui.
2b) Not sure what you mean by the title view. However, the mousewheel 'did' change the palette, that's been broken somewhere along the line though.

3) The online to-do list isn't used anymore hence the big todo Mark post up there ^^^


Grisu(Posted 2004) [#54]
Thanks for the infos Rob.

Mousewheel: After checking your code, the only thing u need to add is a "Global MouseOverTileset" to the var section and mousewheel works again.

Resolution: Well i tested 800,600 on my 17' monitor and nothing looked too small. Furthermore by the time the game comes out every pc should be able to handle at least that resolution!

It would be a really nice option to have! If you don't want to code that, I'll do it.... ;)

P.S.: How about using a free BMP fonts suite? Gives the extra speed for higher resoultions! ;))))))))))))


Mark Tiffany(Posted 2004) [#55]
On 1), I think the time to think about this is if we ever wanted to fully separate the game and rendering engine. The original thought there was to enable 2D / 3D modes, but there's no reason why it shouldn't be capable of higher res - although it's likely to be tricky to achieve as Rob obviously found out. Another one of those for "When we're done!"

When we start the next thread, I'll try to post the todo list as the second post. Just give me some warning Rob when it happens!

Caff, if you're still reading, thanks for offering graphics help. I think we could do with more tiles, and transparent stuff to go over them. Big stuff like Rob's vehicles are cool. See the todolist above and the link to "docs" for inspiration.


Rob Farley(Posted 2004) [#56]
Also further to what Mark has said about creating tiles. There is the splitter app that is being shipped with the code.zip now, this allows you to throw a graphic through it an it'll split it into 2 files, whole blocks or transparant blocks so these can be copy and pasted into the details and base tile sets.
I used this to put the space ship and buggy through so you can use block overlays instead of transparant overlays where necessary, this improves performance of the game so we're not doing a drawimage where a drawblock will work as well.

P.S.: How about using a free BMP fonts suite? Gives the extra speed for higher resoultions! ;))))))))))))
It already uses bitmap fonts.


Mark Tiffany(Posted 2004) [#57]
Actually, what may be useful, is higher res in the editor. I found myself wishing that I could see more of the map at any one time yesterday.

So, Grisu, if you really fancy pulling apart the internals of the graphics, how about trying to up the editor only, but keeping the code shared? I'd prefer some help on the other todo's though...

As for the mousewheel thing, the best way to fix this (I hate globals for the sake of globals) is to amend the following two lines:
	;I know it looks like there is nothing in the quotes in the line below, but trust me, there is
	If (Button (0,490,32,"­",False,True,KEY_PAGE_UP,"Scroll up the tileset",False)=True Or (mz = 1 And mouseover)) And tileoffset > 0 And scrolldelay<0 Then tup=-1
	If (Button (768,490,32,"¯",False,True,KEY_PAGE_DOWN,"Scroll down the tileset",False)=True Or (mz = -1 And mouseover)) And scrolldelay<0 Then tup=1

Simply replace MouseOverTileset with mouseover (don't copy & paste, remember the dodgy characters!)


Rob Farley(Posted 2004) [#58]
I have to agree with the editor thing, it's getting a bit crowded isn't it!


Grisu(Posted 2004) [#59]
Editors are pain. I normally use a Blitz Gui for creating buttons and windows. So you dont need to code a file requester etc.

I can't promise to get sth done very fast as i have a full time job in real life. But if you are busy doing other stuff. I can try in the meantime.

Is there a map format list somewhere, so I know what infos must be stored where?

And the editor now uses the plain text commands. And it seems the main engine uses images. BUT these are no BMP fonts precisely spoken.

A nice idea might be to enlage the title placing area to 800x600 (as the engine should be :)). The editor win itself would be 1024x768 then....

Comments?


Grisu(Posted 2004) [#60]
*coding*
Will post screen here later at night...


Grisu(Posted 2004) [#61]
Phew done & Ready for Stress testing... :)

Changes:
% Editor: uses larger Palette & Tile Window (at 1024x768)
% Msgbar: black background


Editor.bb


Map.bb


Gui.bb



Rob Farley(Posted 2004) [#62]
Nice stuff Grisu, I'll upload this when we've got some more changes. The editor looks a touch empty now.

I hope you don't mind but I got rid of your Grisu advert off the screen (don't worry you'll be in the credits!), sorry but it was annoying me! And I moved the XY co-ords so they didn't overlap the edit area.


Grisu(Posted 2004) [#63]
As, you like: the text msg was for debug reasons only... :)

Where did u move the x,y coords... I'm thinking of rearranging the menu.. in order to maximise usability.

What do u think of this:
[Codebox]http://legion.gibbering.net/grisu/edt.jpg[/Codebox]

Still needs some work as I need to replace some menus...

This way we have less empty space, but cant add more main menu buttons!


Rob Farley(Posted 2004) [#64]
Cool, Works for me!


Grisu(Posted 2004) [#65]
ok, will code on that then.

Don't include stuff till I'm done...

P.S: I'm the master of optimising stuff to death. :D


Rob Farley(Posted 2004) [#66]
If you want to optimise, then do it in the main game engine not the editor, the game engine is what will require more focus.


Grisu(Posted 2004) [#67]
Code Update:
http://legion.gibbering.net/grisu/grisu.zip

+ added: Tile Palette button to switch between "Room Editor" and back
% Reaffanged all menus
% enlarged map view
% fixed gui msg bg

Still adding stuff...

! Only problem "When selecting Object layer the tiles are messed up and i can't find out why... Perhaps u can... :( !


Grisu(Posted 2004) [#68]
1. Ahm, I have a question for the Room Tool (editor).
Are rooms always 3x3 tiles as in the tool win?
Could you write me a plain function, that just loads a given filename and outputs it on screen at given x,y pos. No array saving and types needed. Simply drawing...

2. With your font system:
Is it possible to draw colorised texts on the "fly"

Changes I'd like to do:
- Menu item currently selected is highlighted light blue
- Credits topic are highlighted blue < >
- Credits fade in at bottom and fade out at top before reaching the logo... white -> light grey -> dark grey -> black


Rob Farley(Posted 2004) [#69]
Even heros have to take a break sometimes...




Rob Farley(Posted 2004) [#70]
1. The room creator just lets you select the walls and the floor tile, hence the 3x3.

2. No, there's no reason why the bitmap font couldn't be extended as it's only a 50x50 2 colour image. Just paste on new versions of it in different colours, then just offset the frame it draws based on the colour choice. ie Colour 0 (black) colour 1 (blue) would + 100 to the frames, color 2 (green) + 200 etc. Job done and very easy.

3. Go for it. The problem you're going to have is that because it scrolls you'll have to read the pixels, and darkend them, not hard to do but might be a little slow on lower spec machines.


Rob Farley(Posted 2004) [#71]

If you add this bit of code in the credits function in frontend.bb it'll fade the top to black.


Perturbatio(Posted 2004) [#72]
I get an integer divide by zero error in aliens.bb at this line:
al\turncounter = (al\turncounter + 1) Mod al\turnspeed
in the Update_Aliens function
This occurs as soon as I open the first door.

*edit*
al\speed is set to 0 as is al\turncounter, I don't know exactly where this is being set.


Rob Farley(Posted 2004) [#73]
Have you downloaded the gfx? If not you won't be getting the updated class.txt files on the aliens... and you'll get divide by zero. They're both being set in then spawnalien() function. The class files now contain..
<turnspeed>5</turnspeed> ;  how fast the alien turns around



Grisu(Posted 2004) [#74]
1. Rob, have u checked my prob with the object layer selection in the editor yet?

2. Could you add a filedate to the downloadable files, so we know when new source is up?!?


Rob Farley(Posted 2004) [#75]
1. No, your last one worked fine... Not had time. Mark's probably the person to look at it though as he's currently the editor king! He's been doing clever stuff with the object layer (disconnecting objects with graphics) so he'll probably be able to sort whatever problem there is.
2. I let you know when the source is up by saying zips updated in the thread! It's a pain in the arse dating it each time... I'll see what I can do though.


Rob Farley(Posted 2004) [#76]
I've updated the bitmap font routine so there's white, blue and red font colours. It's called in the same way but you just add the colour number on the end (0,1 or 2). Also updated the credits so you get your different colours. Taken the fadey bit out as it really slows them down so they don't look smooth.

Drawn a toilet (see above!) Trying to think of more 'real life' things that you'd find in on a base. Kitchen, Bathroom, lounge, Canteen etc and drawing some tiles for them.


Grisu(Posted 2004) [#77]
Writepixel is really slow in debug and window mode.
On my PC AMD XP 2100 with debug = off it was smooth!
We can reduce the yy value to "For yy=1 To 20", still will look better.
For the smootnness: Instead reading the lines from the file. Pre-chache them at startup in a Dim or type field. That's how I'm doing it in CW!

Sadly. i'm no good artist. - A bar room with snooker table would be nice... :)
Will mess around, perhaps I can contribute some tiles as well...
Don't know if this is already planed, how about elctric fields (animated) that block players path until a switch is hit? Thie could be ground tiles or sidways (door like).
Then you could paint a nice power core, nearly like an Alien II scenario. :)

Will there be some kind of mini map in the later pocket pc?


Perturbatio(Posted 2004) [#78]
Have you downloaded the gfx?

Oops! I did download it, but I fogot to extract it to the correct directory.


Rob Farley(Posted 2004) [#79]
I've avoided dimming the whole credits into an array as I think it's a crap way of doing it. Could actually use the messenger command to do the credits now... that would look really cool. (fire up the mes_test.bb).

Animated graphics are on their way in... just got to work out how we're going to do it! All that sort of puzzle will arrive. This is why Mark is playing with the editor and objects so much.

I like the idea of a bar room with a snooker table. I also though about having spinny chairs that spin when you shoot them!? I also thought a boiler room would be cool too with lots of pipes and stuff (probably a bit like the power core idea).

There's already a mini map if you log onto the intex systems, press fire 2 (right shift for player 1) next to a console, there's a console in the room you start in. Choose the radar service and you get a mini map. It's kept simple so it doesn't give anything away.

Anyway... Time for bed!


Perturbatio(Posted 2004) [#80]
I also though about having spinny chairs that spin when you shoot them!?

How about an OnDamage event and an AnimateObject command?


Grisu(Posted 2004) [#81]
Animated graphics:

Set different global timers for each animated object that are checked each loop and compared with current time.

"Chair_Spin_Timer=500 (ms)
If current_time=Chair_init_time+Chair_Spin_Timer then
Spinframe=(Spinframe+1)mod spinmaxframe
Chair_init_time=millisecs()
endif

Then just draw the currently selected frame of an object on screen.


Rob Farley(Posted 2004) [#82]
The theory of how to do it isn't the issue Grisu, it's the implementation within the current stucture and making it all work, and also being effeciant so it's not handling stuff that's way off screen or not visible. On top of this it has to be implemented into the editor some how and obviously having many graphic sets isn't reasonable for an editor, this is why Mark is dislocating graphics from the objects.

I really don't want global timers as this syncronises everything so nothing looks natural. It'll probably be more like the aliens where you set the animate speed and each item will be handled individually, this way you get a more natural look and not everything animating like marching soliders. Also global timers for each animated object means we would have to know before we compile the code what objects will be animating, this is totally against the grain of the code as we are trying to soft code everything, or at least as much as possible.


Mark Tiffany(Posted 2004) [#83]
Back from the nether-regions of the UK (Glasgow). Just scanned the posts above, sounds you've been doing some good stuff Grisu. I'll download tonight, andhopefully get some good coding time in. Whilst changing the editor, could you steer clear of anything to do with objects : as Rob says, I'm working on that area.

Current thinking is along these lines:
Animated tiles are also objects, not normal tiles. They'll be in the default object list (not the level specific list, although that'll be possible too). The object will have a trigger of something like "ondraw()", and then the script for that trigger will be something like "drawtile(10,5)|drawtile(11,5)|drawtile(12,100)". This will show tile 10 of the detail layer for 5 frames, tile 11 for 5 frames, then tile 12 for 100 frames. (example here being an occassional spark).

In terms of how this works, whenever a tile is drawn, the ondraw trigger will be fired, and this will create a type containing that info, plus it's own frame timer (set to a random time initially). On each drawing loop, check for any such types, click the timer on by one, and if that means the detail tile gets changed, change it. Also, if the tile is no longer visible, delete the type - although we'll want to hang on to instances for a couple of seconds after going off screen in case you come back and find e.g. a fan spinning differently to how it was!

Sounds would work along a similar line, possibly even using the same trigger, but that'll be a bit harder for continuous sounds - one off sounds will be fine like this (e.g. occassional scratching noises are okay, fans aren't)

Obviously without having started coding that yet, I haven't thought it all the way through, but I think that'll work. Feel free to try hacking that idea into the engine and object definition file if you want though, I'm still focusing on objects in the editor for now.

Actually, what I may do tonight is write some documentation. We need at least something, and I can put all of this in there too (and think about it in more detail!). This'll help Grisu and others understand the map, etc, and possibly b able to help out easier.


Grisu(Posted 2004) [#84]
Good ideas there Mark!

I have stopped work on the editor, so you can change the objects issues as needed. It's nearly impossible to work at the same file at the same time, cause one can't "track" all changes made... :/

Just please post new files with rough named changes here, so we all have the same "state" of code.


Mark Tiffany(Posted 2004) [#85]
Actually, I have some object changes pending (minor ones thus far I'm afraid), but they're generally quite standalone. So long as we don't both hit the same areas of code (i.e. you avoid objects, I only touch objects) we should be okay.

I've found it a lot easier to integrate and spot changes since I discovered a merge tool (*filesComparer*) it's been a lot easier to merge changes in. You might want to take a look. The trick is to keep a replica of the code that you started working from in one directory, your modified code in another, and then when you come to merge changes in, download the latest code. Then you compare yours to the latest and merge your new stuff in. If you get confused as to what you have added / has been added by others, the base from which you worked is then useful to clarify.

I'll definitely post up my changes tonight, plus make a start on some docs.


Rob Farley(Posted 2004) [#86]
I'm working on gfx at the moment more than anything, I need a break from the coding for a bit so this is light relief! The good thing about doing gfx is that I keep expanding the map to use the new graphics, although we're going to dump the test level it'll be good to have a single level with pretty much every object in!

On the editor front we really need the special item in as it makes doing interesting stuff (and basic stuff like spawning aliens) tricky.


Grisu(Posted 2004) [#87]
Mark, when is tonight? ;)


Mark Tiffany(Posted 2004) [#88]
Tonight. :P

Sorry about that. I have made a start on documentation but there's just soooo much! I will post up what I've got by about 1800 GMT. As my parents are visiting this weekend I won't have much of a chance to do anything else until Sunday night, but I'll try to do this!

As for editor changes, forge ahead yourself, I'll patch my stuff in after. So long as you steer clear of stuff relating to objects we should be fine.


Mark Tiffany(Posted 2004) [#89]
Here you go, a start at some documentation. Rob, if you get a chance and fancy it feel free to add to this, tidy up some of my attempting documentation. I'm not going to have a chance to do any more on docs over the next four to five days - what little I do have I want to focus on objects stuff.

*Brief Docs*


Mark Tiffany(Posted 2004) [#90]
And yes, I know I'm one hour late. ;-P


Grisu(Posted 2004) [#91]
Rob, could you upload your code changes done to editor and engine?


Rob Farley(Posted 2004) [#92]
Code and GFX zips updated.

Grisu, I've not put your latest map editor up as I don't like uploading stuff that isn't working 100%


Grisu(Posted 2004) [#93]
Rob: http://legion.gibbering.net/grisu/rob.zip

I fixed the bug I had earlier. Only had a number typo error.... XD

All should be 100% safe now! So you can include it! :)

P.S.: As always: Take out the Grisu txt debug line... missed to delete that.


Grisu(Posted 2004) [#94]
Rob: http://legion.gibbering.net/grisu/menu.zip

I changed the main logo, fonts and some other bits.
Think this version looks better than before?


Rob Farley(Posted 2004) [#95]
GFX and CODE zips updated.

Grisu, I like your changes with the exception of the new title graphic. I've included both the old and new for people to make up their minds. When I grabbed the inital image I actually toned down the colour to make it look less colour pallete like. Anyway, that aside, all the other changes are in.


Rob Farley(Posted 2004) [#96]
I see dead people...



Just drawn a couple of bodies.


Grisu(Posted 2004) [#97]
They look quite... dead... :D
Sadly Art always has been my worst subject at school days.

Do you think we can make use of this one?


It would still need some border tiles around it...

For the gfxs: I have a huge idea, but its quite some work.
It would be really nice if one could see the current weapon a player is using. Means a flame thrower looks like a flamethrower from above even without firing it!

Is this possilble or too much work?!?


Rob Farley(Posted 2004) [#98]
This has been discussed before, quite frankly I think the work involved would outweigh the benefit. It could be done in a quick and dirty way, this would be pretty easy, but would look rubbish, so a lot of time and effort would have to be put into it to make it look better that it currently does. Maybe something to put on the "nice to have" list, but hardly a priority.

Something else... I've had a go at death animations and they look good, done 8 frames that look convincing. The problem... there's still 16 rotations so it's a massive file again, what I propose is that when you die it snaps to one of 4 directions to do the death sequence, this way it'll be close enough, if we don't we're going to be loading another 512k of graphics per character just so they can die... seems a little excessive to me.


Grisu(Posted 2004) [#99]
Well, personally I don't care for Vmem usage, as we should program AB for modern hardware. But you decide on that. :)

Currently I'm thinking of the best way for adding a preview window to the load room file list...


Rob Farley(Posted 2004) [#100]
Well there was another reason for the only 4 directions of death... it only fits in a 64x64 on the 45 deg angles... Here's a quick preview, still not done blood splat decals yet so it looks a bit clean... but fear not... gore will be added!



And I see more dead people...




Grisu(Posted 2004) [#101]
Looks awesome Rob!

For the editor there should be an object tool as well.
Means you don't have to select tile by tile for construction. Some what like "Select bed" -> "Determine Dir" -> place on map within a mouseclick...
This would speed up level construction, my guess.


Rob Farley(Posted 2004) [#102]
Again, we've talked about a 'shapes tool' I added a little copy and paste option just before you joined in. Press tab to start a copy block and tab again to finish the block, then q to paste... the only thing is you can't save prefabs yet.

I've added an extra little bit to it that only copied visible layers too so you can draw a bed, hide the background layers, unhide the collision and copy, then when you paste it will paste all the layers you had visible when you did the copy.

It could be with being tarted up a bit so you can drag areas (like the rooms) but I just did a quick and dirty solution.


Mark Tiffany(Posted 2004) [#103]
On the death animation, how about have the player stagger backwards a bit to face the appropriate direction(s) before kicking in with the death animation?

Player/Weapon gfx are on the todo list above, but as Rob says not really what we need to focus, and probably too fiddly to be worthwhile.

As for objects, when you are editing the object layer, you can place any of the default objects on the map as per tile placement. For level specific, customised objects, a further icon will (once I've posted it up) allow you to place new objects, which you will then customise by right clicking. Hopefully will get a chance to do something this evening (parents have just left, and daughter is asleep).


Rob Farley(Posted 2004) [#104]
I look forward to getting the special object working so I can set up spawn points for all the aliens, I've got 2 more waiting in the wings too.

As for the dying I thought just make them spin on the spot to get to the correct direction, I don't think anyone will really notice, especailly in one player mode.

I think we need to add an extra flag to the player type too as a disable controls flag, this way we can get the player to do set pieces (like dying or level start stuff) without worrying about user input and still having all the other stuff like collision working.

I think we're about ready for a new thread, I just want to wait until we've got something significant to start the new thread with. Everything so far has been pretty cosmetic.


Rob Farley(Posted 2004) [#105]
Just so you know I've added in the extra flags I was talking about, you can now disable drawing and disable controls for any given player, this is kinda handy if you want to flash the graphic or whatever...

Anyway... I've updated the death aninmation so it looks fine, it's 16 frames and only pointing in one direction. When you die the player spins to the correct orientation... looks fine, so that'll do.

Just got to update the particles system to deal with particles staying forever on the last frame.

Once I've got this lot in I'll update the zips and start a new thread.


Mark Tiffany(Posted 2004) [#106]
Rob, in the code.zip, there are two copies of the editor. editor.bb and editor4.bb.

Which one should we be using? editor4 seems to work best...

I was merging my code in last night and couldn't work out which one to go with.


Rob Farley(Posted 2004) [#107]
Editor4 is the newest one... sorry... I was meaning to rename it and delete the old editor... bad housekeeping :(

Now I've killed Bunker, I'm killing Binky now... shame, she's such a nice girl!


Clyde(Posted 2004) [#108]
I've been playing this for quite a length and while.
And all I can say is, Well Done on A truely terrific and wonderful remake and game!

Cheers!
Great Stuff :)


Mark Tiffany(Posted 2004) [#109]
Editor4 is the newest one

Thought so!

One thing that I'd really like fixed to make the object stuff work well is enabling double click and a graphical means of exiting the ListDlg function. Maybe an Ok and Cancel button at the bottom of it, and writing some double click code. I'd do it myself, but would rather focus on just getting the object stuff working rather than niceties like this...

Great Stuff :)

Thanks!


Rob Farley(Posted 2004) [#110]
Time for a new thead this one is way too long now!!

http://www.blitzbasic.com/Community/posts.php?topic=40469