Menu

Show posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Show posts Menu

Messages - SSH

#3441
OK, CJ, we'll see if anyone else gets the problem coming up. I think it will occur when someone is writing a module outside the guidelines that Rick and Scorp put together, which i guess means everyone except those two and me ;)

Quote from: SSH on Fri 16/09/2005 20:53:26
And I just had an idea that will make life easier: If you could right-click on a variable declaration (or CTRL-SOMETHING) and it would automatically add an export command for that var to the end of the script, and an import to the relevant header file. Now THAT would rock.

No-one has commented on this idea, though. Was it THAT bad?
#3442
Good idea. Or even

my int i=0;

(tell the perl fan)
#3443
All generalisation will be  wrong to a greater or lesser extent.

Except this one  ;D



oh, and I think some of the Russians you mention were sacrificed by Stalin rather than themselves. Stalin was, after all, the world biggest ever genocidal maniac. The only thing was, his genocide was agianst his own people.
#3444
Well, if I manage to go

a) I'll bring my whole family
b) they wont be camping, so neither will I
c) we'll visit our friends in Malaga, too

If anyone else want to look at cheap flights WITHIN Spai, I believe Vueling are the low-cost operator for internal Spanish flights
#3445
but I think that the advent of the script module maybe will swing the balance the other way, in that more bug reports  will occur because of exported variables. Maybe it can be a switch like OO and left-to-right
#3446
Maybe I can reorganise the structure to use less channels
but I really do need 3 as a minimum, I think  :(

Oh well, worth a try maybe

#3447
I noticed while doing the module, btw, that there's was no point in using protected when writing the module: just hide any local function and variables in an struct that inherits the "public" struct. It also effectively allows protected static functions, etc.
#3448
Well, i didn't have any crashes when I just had 2 channels going (like the demo game), but now I am using 3, 4 or 5 channels I am getting them. Also, they are allegedly occuring at pretty random points in time, which makes me suspect some kind of buffer overflow in the plugin or somesuch.

Other than making sure I used string instead of String with the plugin, I dont think it is a compatibility issue.
#3449
See also http://www.adventuregamestudio.co.uk/yabb/index.php?topic=22652.msg277775#msg277775

When I declare a local variable, for example in a module function, it can clash with other modules loaded earlier if their script headers import a variable with the same name. In just about every other language I know, local variables mask out any globals of the same name, so it would be nice if AGS cold do this to. As it is there is no way to protect yourself from this, other than giving local variables inside any mdoule long prefixes, which is a pain.

And I just had an idea that will make life easier: If you could right-click on a variable declaration (or CTRL-SOMETHING) and it would automatically add an export command for that var to the end of the script, and an import to the relevant header file. Now THAT would rock.
#3450
No, the whole game dies without a message and sometime I even got one of those "Send error report to MS" dialogs!

Some errors did bring up an err message, but recently, it just dies.
#3451
Well, my immediate probelm is that it is crashing all over the place...
#3452
And of course, view names are all uppercase anyway  :P
#3453
Quote from: monkey_05_06 on Fri 16/09/2005 00:00:03
This next beta sounds good.  How long (abouts) until we get to see it? :=

betas automatically get delayed if anyone asks when the next one will be  >:(. But CJ usually releases them at a weekend.   :=
#3454
my guess would be:

object[0].SetView(6)
object[0].Animate(6, 0);

assuming that you object is object 0 and your animation is in view 6, loop 0

oh, and Worm III beat me to it  :=
#3455
A thing I think i did in Pixel Hunt is to call a global function on room enter, passing some object pointers:

so in before_fadein interaction:

global_func(oElevator, oFloorNum);

and...

function global_func (Object *a, Object*b) {
  oElevator=a; oFloorNum-b;
}
#3456
I've been trying to use a-v-o's TCP/IP plugin to write a game (see http://www.adventuregamestudio.co.uk/yabb/index.php?topic=22650.0) but it crashes out without any message a lot, and I'm having a nightmare debugging it. Can any plugin writers offer any advice or help or even do a remake of the plugin with some kind of diagnostic/logging capability?

Or any other ideas on how to debug!

Thanks!
#3457
Module name collisions issue

[edit by scorpiorus]

The following quotes were taken from the MODULE: Screenshots SAVELOAD GUI thread:
Quote from: ags_freak on Thu 15/09/2005 17:25:40
i imported the modules in the right order and also imported the guis. when i want to test my game i get this error:

'In: savegames with screenshots"

error (line 80): local variable cannot have the same name as an import
how can i fix this?
Quote from: SSH on Thu 15/09/2005 17:29:33
Do you have your own variable called li?

Change its name to something else
Quote from: ags_freak on Thu 15/09/2005 17:55:54
thanks. i really had a variable called "li". but now it works perfectly.
Quote from: Scorpiorus on Thu 15/09/2005 19:21:57Hmm, interesting. This sort of name collision could happen if you had your own module listed before "Savegames with screenshots" one and which exports a "li" variable which originally is a local variable in "Savegames with screenshots" module itself.

[/edit]

Indeed. I could change the module to have something a bit more obscure, but I'm used to programming languages let local variables MASK any globals, so I think CJ should maybe do something, long term. I guess if ags_freak had stuck all his exports in a struct or with a module prefx, it would be OK.
We should note it in the module writing thread, though.
#3458
Hmmm, I've disabled some stuff in the version in http://www.lumpcity.co.uk/~ssh/rogvrog2.rar but it still seems to crash sometimes. Its very hard to deug, as there's no readable error message comes up. It might be the plugin, I suppose, and even if it isn't I'd love to see some diagnostics in the plugin? a-v-o? ANy volunteers?

*sigh*
#3459
Well, welcome to another GiP thread. This one is for an incredible 2-player adventure game. Yes, thats right, through the wonder fo the interweb you can recreate the old Spectrum/C64/GB/etc game Spy vs Spy.

This is still very much a work in progress, but its quite hard to test a multiplayer game by myself, so I'd really appreciate anyone who wants to beta this DEMO and help me develop the final game.

To play, you need to know your IP, and that of the person you wish to play with. You can get it at: http://www.whatismyip.com/. Click on the RogvRog logo and enter the IP to connect.

Oh yeah, you prob need to enable a firewall exception for port 28166 too

Eventually, I hope to eliminate IPs by some nice front end and server, but that might be hard! Anyone with ideas on that is most welcome, especially if they have used a-v-o's TCP/IP plugin.

The game will eventually be to get the briefcase and fill it with secret papers, passport, money and key to get out of the "Embassy". However, just now you can just go around collecting things and setting traps. Final version will have a fight engine, too. Now THAT will be tricky to do.

If you left-click on things, it will search them for hidden objects. If you right click on doors, it will open/close them. If you click on your traps (bomb, bucket, spring, etc) then the cursor becomes X and you can click on a closed door or object to booby-trap them. Each trap has an antidote, so for example you can disarm a trapped door by using the umbrella then right-clicking on a trapped door. Only doors can be trapped with the bucket and only non-doors can be trapped with the bomb and spring. The time bomb is not implemented yet. The animations aren't all done yet, either, so you've just got the umbrella/water bucket ones.

If you get killed by a trap you are frozen for 10 seconds.

Um, and that's it, I think. Please report lots of bugs or suggestions for improvement, or volunteer to improve the anims, etc. Thanks so far to those on #ags who have tested it a bit already and Progz for a winning anim (not seen yet) and a-v-o for the TCP/IP plugin. And of course CJ for his awesome AGS.

Screenshots:

Use the umbrella to stop the water:

When both players in same room, split-screen disappears (and eventually fight engine comes into play)


DOWNLOAD the demo/beta here: http://www.lumpcity.co.uk/~ssh/RogvRog.zip

For those of you interested, here's my todo list:

// timebombs: room only, and implement timer on room enter/bomb set
// need to add code for sending these: use obj, but special case
// weapon pickup?
// simple rog anims
// set up map
// rog2 blue: do with tints
// Exit door and win sequence
// Game start sequence: set rog colours/tint?
// chat interface
// fight engine?
// trap doors: only go down, can open/close(RIGHTCLICK)
// ladder: can raise (RIGHTCLICK)when down or lower when up, up/down
// map screen: plan view, *color* sqaures/cirlces show
// essential items, colours of spies show their locations
// another colour shows traps (except time bombs)
// When 2 rogs in room, held item gets hidden somewhere in room
// Animations required:
// Whole room exploding (time bomb)
// Rog getting exploded (bomb)
// rog getting sprung (spring)
// rog using water on bomb
// rog using wirecutters on spring
// rog victory dance
// rog rummaging (3 directions)
// rog punching
// rog stabbing


#3460
Ah, I knew I'd seen it somewhere. But if you have 18 objects going, does taking 2 out save much? Also, I think its easier just to keep them as objects. Ah well, we'll see if people have problems in beta.
SMF spam blocked by CleanTalk