Normal Topic move a printstring form (Read 370 times)
debmckee
Full Member
***
Offline



Posts: 123
Joined: Oct 5th, 2011
move a printstring form
Oct 19th, 2012 at 5:53pm
Print Post Print Post  
Is there a way to move up the entire form up a few lines instead of individually editing each printstring command?
  
Back to top
 
IP Logged
 
The Cow
YaBB Administrator
*****
Offline



Posts: 2530
Joined: Nov 22nd, 2002
Re: move a printstring form
Reply #1 - Oct 19th, 2012 at 7:25pm
Print Post Print Post  
If you have already hard-coded values into each PrintString command, then you should use this opportunity to replace those with variables. Once you have variables, changing them (without editing lots of lines), becomes trivially easy.

If you feel like putting that off for a while, you can also add an offset variable to the hardcoded number.


var aa as int

aa = 22

PrintString(..., 37, ...) // Not offset
PrintString(..., 48 + aa, ...) // Offset by 22
PrintString(..., 59 + aa, ...) // Also offset by 22

etc...
  

Mark Lasersohn&&Programmer&&Lantica Software, LLC
Back to top
IP Logged