Jump to content


tomudzjeris

Member Since 02 Aug 2011
Offline Last Active Feb 21 2013 01:12 PM

Topics I've Started

Numberi

30 October 2011 - 06:15 PM

Numberi

Game Name: Numberi
Category: Puzzle game
File Size: 6,4 MB
Vista Compatible: yes
Screen Resolution: at least 800 x 600
Changes Screen Resolution: no
Multiplayer: no
Download Link: Yoyo games link
Alternate download link: Numberi.exe
Screenshots:
Posted Image

Posted Image

Description: The goal of this game is to cross out every number. Although it sounds easy, you need to follow some rules to successfully finish the game:
*Numbers which are equal or give 10 in sum can be crossed out;
*Numbers need to be next to each other vertically or horizontally to cross them out;
*You can cross out numbers which have scratch in between them;
*You can use "hint" button to reveal available moves;
*You need to press on "copy" button to copy and arrange all remaining numbers to play further;
*It is possible to save your progress when you exit the game;

Try this game out and find the fastest way to finish it. My record is 45 seconds with 78 created numbers. Once you have figured out how to beat it in the fastest way, try to find the longest way. :)

Change sprite when mouse is on [SOLVED]

22 October 2011 - 10:15 AM

Hello,

In all rooms there are some buttons. If I move my mouse on one of them, it changes to a larger button. When I press on that larger button, it goes to a different room. If in that room a button is created under my mouse, this button doesn't change to the larger button. How can I prevent this and tell the button, if the mouse is already on it, then change to the larger button?

Thanks :)

Convert real number to time

16 October 2011 - 08:49 AM

Hello,

My game uses timer function which converts real number to local time format. It is not windows time, but the time from the start of the game. This feature works very nice if you have 23:59:59 time format. But if you are you using 11:59 AM/PM format, it shows AM or PM at the end of time. Is there a way that it always uses 23:59:59 time format and doesn't show AM or PM?

//Alarm[0] event:
global.timer += 1/(3600*24);     // Seconds increases by 1 
alarm[0] = 30;         // Reloads alarm event

//Draw event:
draw_text(560, view_yview[0]+176, string(date_time_string(global.timer)));

Resizing game window

03 October 2011 - 08:14 PM

Hello,

In my game it would be nice if player could resize game window without affecting sprites (sprites don't scale or move...). I found out that it isn't that easy to do. Although there are some dlls like MaxWinApi, which might do what I need but I don't really know how to make it working...

That's why I made view changing based on one user's script (don't remember his nick). It seems to work, but there is strange error or bug or something...(after code)
Code I use:
// obj_controller Create event:
window_resize = true;
border = 200;

//obj_controller room_start event:
if window_resize = true
{
    view_enabled = true ;
    view_visible[1] = true ;
    view_xport[1] = 0 ;
    view_yport[1] = 0 ;
    view_wport[1] = room_width ;
    view_hport[1] = display_get_height() - border ;
    view_xview[1] = 0 ;
    view_yview[1] = 0 ;
    view_wview[1] = room_width ;
    view_hview[1] = display_get_height() - border ;
    room_restart(); //restart is needed for room to display changes
    window_resize = false;
}
else
{
    view_enabled = true ;
    view_visible[1] = true ;
    view_xport[1] = 0 ;
    view_yport[1] = 0 ;
    view_wport[1] = room_width ;
    view_hport[1] = display_get_height() - border ;
    view_xview[1] = 0 ;
    view_yview[1] = 0 ;
    view_wview[1] = room_width ;
    view_hview[1] = display_get_height() - border ;
}

//obj_controller key up event:
border += 10; //shrinks view by 10 pixels
room_restart();

//obj_controller key down event:
border -= 10; //extends view by 10 pixels
room_restart();

Problem is with key up event... First when I press it, it makes black line at the bottom of window like in the picture below:
Posted Image
Then when I keep pressing up key, it shrinks the view but the black line still persists. If I press down key, the line disappears and view extends normally.

Can someone tell me where is the mistake?

Thanks

Block movement [SOLVED]

23 September 2011 - 04:18 PM

Hello,

My game consists of rows of blocks which are tight together, something like bejeweled. When a row is full of obj_cross instances, it is automatically destroyed. I perform the destruction with this code:
if instance_position(x-22, y, obj_edge)
{
    if (instance_position(x+44, y, obj_cross) and instance_position(x+88, y, obj_cross) and 
         instance_position(x+132, y, obj_cross,) and instance_position(x+176, y, obj_cross) and
         instance_position(x+220, y, obj_cross) and instance_position(x+264, y, obj_cross) and
         instance_position(x+308, y, obj_cross) and instance_position(x+352, y, obj_cross))
    {
        with instance_position(x+44,y, obj_cross) instance_destroy();
        with instance_position(x+88, y, obj_cross) instance_destroy();
        with instance_position(x+132, y, obj_cross) instance_destroy();
        with instance_position(x+176, y, obj_cross) instance_destroy();
        with instance_position(x+220, y, obj_cross) instance_destroy();
        with instance_position(x+264, y, obj_cross) instance_destroy();
        with instance_position(x+308, y, obj_cross) instance_destroy();
        with instance_position(x+352, y, obj_cross) instance_destroy();
        global.rows += 1;
        global.n += 9;
        instance_destroy();
    }
}
When the row is destroyed, there remains an empty place, so I use code for all instances to move up (my game uses upward gravity not downward):
if (place_free(x,y-1)) vspeed = -2;
else speed = 0;
All my codes are not in a step event but in alarm[0], which repeats every 4th step (I have a lot of scripts which cause slowdown if used in step event, so I use alarm instead). But this caused a lot of problems... All instances which needed to move up, started moving chaotic(not all at the same time), it resulted in some strange defect. And usually the last instance in the whole game moved 1 pixel too deep into other instance.

To correct the last issue that I wrote, I used different code for moving:
if (place_free(x,y-44)) y = y-44;
else y = y;
This doesn't give any intersection errors, but the instances still move up chaotically.

My question is: how to make it so the instances would move up all as one, like in bejeweled, or at least the instances in a row would move at the same time and not chaotic. I would prefer the vspeed method as it looks a bit nicer.

Thanks