V3 function request
Displaying 61-80 of 105 total.
prev 1 2 3 4 5 6 next
Please enter a numerical value for the importance of this sticky.
Enter 0 to unsticky.
Kildorf

if you blit an entity frame to a seperate image and modify it and then blit it over the entity on the map, it'd work.

I think there might be something clever that I could do with HookEntityRender(), too, that amounts to basically the same thing. I'll probably go this route anyway, as I think I've convinced myself to make entities that face eight directions, as well.

I think I hate myself.

Posted on 2004-04-22 01:18:21

vecna

Kildorf: The V3 CHR format actually has support for 8-directional walking animations, though the engine at this time doesnt use them, I had an experimental build of xerxes (root engine I've been developing on and off since V2 that both winv2 and v3 derive from, as well as CHASMS) that did use eight-way animations, so its something that can probably go in quite soon, maybe the next build (the one after tonight).

Regarding the diagonal movement rate, I just put in the fix, and the party following still works, however, it results in an extremely headache inducing effect of camera shaking because you're moving fractions of a pixel per tick and uh. Its just ugly right now. So I took it out, if I can coax the math so that my eyes don't bleed I'll put it back in.

Posted on 2004-04-22 01:23:11

Kildorf

The V3 CHR format actually has support for 8-directional walking animations...so its something that can probably go in quite soon.

That would be more than awesome. It would certainly make my life easier. :D

Posted on 2004-04-22 01:26:07

Miggle

Make the alpha color in PNG's work for TBLITS and so on...
Dealing with #ff00ff can be a bitch when working with Hi-Res, Hi-Color Bitmaps that are anti-aliased.

Posted on 2004-04-22 12:49:08

RageCage

entity image size...

entity.width
entity.height

would be handy

Posted on 2004-04-22 13:52:23

sabernet

it would definitely be handy to be able to scale chr sizes

Posted on 2004-04-22 15:26:32

sabernet

is it currently possible to create a large scale palette offset?(as in shitfting all colors towards [insert color here])

i know this was more practical in the 256 color gif/pcx days, but it would be handy

Posted on 2004-04-22 15:28:26

resident

Any chance of adding defines for TRUE and FALSE, while I'm thinking about it? Otherwise I have to add

#define FALSE 0
#define TRUE 1

At the top of all my VC files, and I'm too lazy to do that.

Posted on 2004-04-22 21:35:44

mcgrue

I usually have a vc file included at the very top of system.vc called defines.vc. Those two lines are usually the top two lines of said file.

Posted on 2004-04-22 21:55:17

sabernet

if you #define TRUE and FALSE

would that mean that if

int test == 5

then

(a == 5) == 1?

the reason I ask is I would want to control movements and the like like this(forgive the lack of vc3 programmign knowledge, reverting to TI BASIC)

pos x = (pos x + (RIGHT == 1)movspeed)

where movspeed is the variable controlling pixels per second

I used to do this on my ticalc and it worked pretty sweet in optimizing BASIC progs

And if it does work, would it equally optimize vc code?(as opposed to using IF )

Posted on 2004-04-22 22:07:25

mcgrue

0 is false.

anything non-zero is true.

I'm not sure about the specifics in verge. try: ex


int i;
i=5

if( ((i==5) == 1) ) {
Exit( "yes" );
}
Exit( "no" );


Does not compile in verge, so I cannot test this theory of yours.

Posted on 2004-04-22 22:12:56

resident

This maths stuff is beyond my comprehension. I just want to be able to do things like

int battle_over = FALSE;
while (!battle_over)
{
if (B1) { battle_over = TRUE; }
}

Posted on 2004-04-22 22:16:44

mcgrue

Then put those two defines at the top! :D

It's a common habit of c programs! :)

Posted on 2004-04-22 22:34:45

resident

Surely I can't be the only person who uses those though?

when there's already a list of defines for the various scancodes for the keyboard built in, it seems like an unnessecary amount of work to include those two defines at the top of every VC file for what I figure are fairly common defines.

VC is not C, despite the similarities :D

Posted on 2004-04-22 22:39:15

sabernet

essentially, the line
pos x = (pos x + (RIGHT == 1)movspeed)

would substitute a whole if and else statement because it would just move the character +1 x 1(movespeed)

because the (RIGHT == 1), being true, would equal one

if it were false, it would make the invalid multiplication of 0(movspeed) which would not move(or crash due to the devidebyzero error^~[which I suppose could be fixed with an additional + and - sign])

Posted on 2004-04-22 22:46:15

mcgrue

You mean

pos x = (pos x + ((RIGHT == 1)*movspeed));

And I'm still pretty sure that use of parens is beyond v3's parsing abilities.

Posted on 2004-04-22 22:48:58

Omni


essentially, the line
pos x = (pos x + (RIGHT == 1)movspeed)


Would not work. You mean that you wish to evaluate a conditional and assign it to a variable.

In real programming languages, the RIGHT == 1 above would return 1 or TRUE if RIGHT did equal 1 (the joystick is being moved). However, V3 VC is not a real programming language--it is an interpreted one. Conditionals are only interpreted in the scope of an If() or While(). It seems a little retarded, yes, but it has also caused problems for other people around the boards. VC is not a true programming language--but to the naked eye it does just as well.

However,

int battle_over;
battle_over = FALSE;
while (!battle_over)
{
if (B1) { battle_over = TRUE; }
}

Would work quite fine, since the actual evaluation of battle_over only occurs in the while() statement.

In regards to the above example, you could do:


int IsRightPressed()
{
if joy.right [or whatever the value is] == 1:
return 1
return 0
}

#Then, you could do

pos x = (pos x + (IsRightPressed())*movspeed)


This would work because a function can return a value, but a conditional outside of a While(), If(), or For() cannot.

Does this help?

Posted on 2004-04-22 22:54:43

sabernet

oh...dang

then, that shall be my *queue trumpet* Function Request*shoot trumpet player*

thanx grue, now I contributed:D

Posted on 2004-04-22 22:57:00

sabernet

actually, omni, that helped a lot:)

but you killed my function contribution:(

lol

Posted on 2004-04-22 22:58:39

sabernet

actually, I'm confused by the following:

if joy.right [or whatever the value is] == 1:
return 1
return 0

in vc3, what would "return" do and why state it twice in two dif numbers(never used a "return" command before)

or was the return 0 supposed to be in the else clause and give that value to the variable the if statement is using?

.
.
.
.
.

I confused myself^^;

Posted on 2004-04-22 23:14:09 (last edited on 2004-04-22 23:19:25)


Displaying 61-80 of 105 total.
prev 1 2 3 4 5 6 next
 
Newest messages

Ben McGraw's lovingly crafted this website from scratch for years.
It's a lot prettier this go around because of Jon Wofford.
Verge-rpg.com is a member of the lunarnet irc network, and would like to take this opportunity to remind you that regardless how babies taste, it is wrong to eat them.