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.

Newcomers DBPro Corner / Changing +/-

Author
Message
FiShFuN4eVeR
21
Years of Service
User Offline
Joined: 2nd Feb 2003
Location: Netherlands
Posted: 5th Apr 2003 14:13
Is there a way to make a positif number into a negatif number and visa versa in darkbasic classic with one function??? I wan't to change the speed from positif into negatif and from negatif into positif at a coördinate...
If good programmer()=1 then print "Finaly I get to the top "
Dave J
Retired Moderator
21
Years of Service
User Offline
Joined: 11th Feb 2003
Location: Secret Military Pub, Down Under
Posted: 5th Apr 2003 14:25 Edited at: 5th Apr 2003 14:27
Yep




Edit: Now that I think of it, if Num was negative then "Num = 0 - Num" would make it positive anyway. hehe.

"Computers are useless they can only give you answers."
MrTAToad
22
Years of Service
User Offline
Joined: 26th Aug 2002
Location: United Kingdom
Posted: 5th Apr 2003 14:31
or even



Good news everyone! I really am THAT good...
http://www.nickk.nildram.co.uk/ for great plug-ins - oh my, yes!
Kentaree
21
Years of Service
User Offline
Joined: 5th Oct 2002
Location: Clonmel, Ireland
Posted: 5th Apr 2003 14:59
And yet another one



Whatever I did I didn't do it!
FiShFuN4eVeR
21
Years of Service
User Offline
Joined: 2nd Feb 2003
Location: Netherlands
Posted: 5th Apr 2003 15:11
Thank you all

If good programmer()=1 then print "Finaly I get to the top "
Dave J
Retired Moderator
21
Years of Service
User Offline
Joined: 11th Feb 2003
Location: Secret Military Pub, Down Under
Posted: 5th Apr 2003 15:13 Edited at: 5th Apr 2003 15:14
And Maybe



"Computers are useless they can only give you answers."
Chiwawa
21
Years of Service
User Offline
Joined: 13th Oct 2002
Location: Canada
Posted: 5th Apr 2003 19:21
and:



or

Kentaree
21
Years of Service
User Offline
Joined: 5th Oct 2002
Location: Clonmel, Ireland
Posted: 5th Apr 2003 19:39
lmao, this thread is probably gonna end up with around 50 posts, each saying how best to change the sign of a value

Whatever I did I didn't do it!
MrTAToad
22
Years of Service
User Offline
Joined: 26th Aug 2002
Location: United Kingdom
Posted: 5th Apr 2003 19:52
Plus, you could write a plug-in to do it too...

Good news everyone! I really am THAT good...
http://www.nickk.nildram.co.uk/ for great plug-ins - oh my, yes!
Danmatsuma
21
Years of Service
User Offline
Joined: 2nd Mar 2003
Location: Australia
Posted: 5th Apr 2003 20:08
*lol*

ZX Spectrum 48k Issue 3, Radio shack Tape drive, Rank arena 12" T.V. set.
John H
Retired Moderator
21
Years of Service
User Offline
Joined: 14th Oct 2002
Location: Burlington, VT
Posted: 5th Apr 2003 20:12
You and your plugins Tat

Id just multiply it by -1

RPGamer

Current - RPG: Eternal Destiny
Dave J
Retired Moderator
21
Years of Service
User Offline
Joined: 11th Feb 2003
Location: Secret Military Pub, Down Under
Posted: 6th Apr 2003 01:12
And my snippet takes home the gold =D

"Computers are useless they can only give you answers."

Login to post a reply

Server time is: 2024-09-20 03:44:31
Your offset time is: 2024-09-20 03:44:31